Code Monkey home page Code Monkey logo

poc-zap-automation's Introduction

poc-go-zap

Playing around with OWASP ZAP automation using zaproxy/zap-api-go.

Usage

docker-compose up -d
go run *.go

The ZAP proxy is available at:

ZAP Baseline Scan

This will run the baseline scan as configured in docker-compose-run.yml:

./run-zapbaseline.sh http://example.com/

The results are written out to ./reports/. You can use jq to extract various information from the json output:

jq '.site.alerts[] | "\(.name) \t[\(.riskdesc)]"' ./reports/zap-baseline-example.com.json

Web UI

If you want to use the ZAP WebSwing UI, you will have to:

  • Change the zaproxy service in the ``docker-compose.ymlfile to use theowasp/zap2docker-stable` image
  • Change the zaproxy command to call zap-webswing.sh

Once everything is started up, you can then access the UI at:

Note: It seems that enabling this will break any 'normal' port/proxy capability, including the API. It also seems as though the run script for this doesn't allow command line arguments to be passed to the proxy itself.

Hackables

Potential Issues

  • You can scan the hackables using their 'docker-compose service name' and 'internal port' (as this is from the perspective of the ZAP container), eg.
    • http://bodgeit:8080/bodgeit/
    • http://juiceshop:3000
  • zaproxy container logs show error 'URL Not Found in the Scan Tree'
    • You need to access/spider a URL before you can scan it.
    • You may have tried to scan a 127.0.0.1 URL, which is going to reference the ZAP container.. not the local machine.
  • main.go produces an error such as spider error: invalid character '<' looking for beginning of value
    • You're probably running the WebUI version, which seems incompatible with the API..

poc-zap-automation's People

Contributors

0xdevalias avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.