diff --git a/sources/install/package_web.sh b/sources/install/package_web.sh index b805b8f3c..6d43bbb85 100644 --- a/sources/install/package_web.sh +++ b/sources/install/package_web.sh @@ -897,12 +897,12 @@ function install_postman() { function install_zap() { colorecho "Installing ZAP" - mkdir /opt/tools/ZAP - # using $(which curl) to avoid having additional logs put in curl output being executed because of catch_and_retry zap_version=$(curl -s "https://www.zaproxy.org/download/" | grep -E -o "ZAP [0-9]+(\.[0-9]+)+" | head -1 | cut -d' ' -f2) wget "https://github.com/zaproxy/zaproxy/releases/download/v${zap_version}/ZAP_${zap_version}_Linux.tar.gz" -O /tmp/zap.tar.gz - tar -xf /tmp/zap.tar.gz -C /opt/tools/ - mv /opt/tools/ZAP_${zap_version} /opt/tools/ZAP/ + tar -xf /tmp/zap.tar.gz -C /tmp/ + mv /tmp/ZAP_${zap_version} /opt/tools/ZAP/ + rm -rf /tmp/ZAP_${zap_version} + rm /tmp/zap.tar.gz add-aliases zap add-history zap add-test-command "which zap"