Commit f1c4d0f4 authored by FulcrandG's avatar FulcrandG
Browse files

zaproxy job with zap-cli without report

parent 37267754
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -40,4 +40,3 @@ use it as a service (we reccomend using our [Docker](https://hub.go2scale.io/job
| `ZAP_OPTIONS` <img width=100/> | ZAP command line options e.g. `-z "-config aaa=bbb -config ccc=ddd"` <img width=175/>| ` ` <img width=100/>|
| `ZAP_CONTEXT` | Path for the context file for authenticated scans | ` ` |
| `ZAP_TARGET` | Target for zaproxy to scan, default using alias of the docker image used as a service | `http://app` |
| `ZAP_PORT` | Custom port if you have one for your project (zap will try 80/443 by default) | `80` |
+4 −5
Original line number Diff line number Diff line
@@ -8,19 +8,18 @@ zaproxy:
    ZAP_SCANNERS: ""
    ZAP_CONTEXT: ""
    ZAP_TARGET: "http://app"
    ZAP_PORT: "80"
  script:
    - if [ ! -z ${ZAP_CONTEXT} ]; then
    -   zap-cli context import ${ZAP_CONTEXT}
    -   if [ ! -z ${ZAP_SCANNERS}]; then
    -     zap-cli -p ${ZAP_PORT} quick-scan -s ${ZAP_SCANNERS} --context-name ${ZAP_CONTEXT} --start-options '-config api.disablekey=true' ${ZAP_TARGET}
    -     zap-cli quick-scan -sc -s ${ZAP_SCANNERS} --context-name ${ZAP_CONTEXT} --start-options '-config api.disablekey=true' ${ZAP_TARGET}
    -   else
    -     zap-cli -p ${ZAP_PORT} quick-scan --context-name ${ZAP_CONTEXT} --start-options '-config api.disablekey=true' ${ZAP_TARGET}
    -     zap-cli quick-scan -sc --context-name ${ZAP_CONTEXT} --start-options '-config api.disablekey=true' ${ZAP_TARGET}
    -   fi
    - else
    -   if [ ! -z ${ZAP_SCANNERS}]; then
    -     zap-cli -p ${ZAP_PORT} quick-scan -s $ {ZAP_SCANNERS} --start-options '-config api.disablekey=true' ${ZAP_TARGET} 
    -     zap-cli quick-scan -sc -s $ {ZAP_SCANNERS} --start-options '-config api.disablekey=true' ${ZAP_TARGET} 
    -   else
    -     zap-cli -p ${ZAP_PORT} quick-scan --start-options '-config api.disablekey=true' ${ZAP_TARGET}
    -     zap-cli quick-scan -sc --start-options '-config api.disablekey=true' ${ZAP_TARGET}
    -   fi
    - fi
 No newline at end of file