-
Notifications
You must be signed in to change notification settings - Fork 112
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Glue Does Not Send Api Key to Zap In Header #154
Comments
Is this something that changed on zap side? I think this is something that worked in the past. @psiinon maybe you know? Anyway, I will recommend using the dynamic task instead. An alternative will be to contribute a PR... |
Cool, I was just thinking about a PR! I will see how I get on with a dynamic task and let you know. Also, do you know if the Zap API supports scanning APIs using a Swagger file? I know the docker image itself does when running the python scripts but I haven't seen anything in the API to support it so far.. |
So for example with the Zap Docker image I can do something like:
Where -t is the target defined as a swagger spec and -f is the format defined as openapi. And Zap will use the swagger spec to traverse and test my API. I can't find an equivlant in the Zap API but maybe there is one... |
I'm not sure - but that the power of the dynamic task: Run zap however you like, export the report and parse it with Glue... |
Ok will give it a go then and report back - thanks 👍 |
@omerlh related to what and since when? :) |
Sorry :) Regarding:
Since when Zap expects the API key in query param? Or does it never worked with Glue? |
You should be able to use either a "apikey" query param or the X-ZAP-API-Key header. |
Hey @omerlh - so the dynamic task worked as suggested thanks but I have hit another issue. The JIRA reporter assumes that issues should be raised as a bug issue type. The project I am working on does not have this issue type (instead having defect and story) so it fails to report the issues. I can't see any way to pass in an override to the issue type to set to something else. Should I create a PR to add support for this? |
Yes please, can you file a different issue for that? I would recommend adding an option for the the issue type. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Hey,
Summary
Trying to use the Glue task for ZAP as the next stage in my security testing pipeline however I am coming across an issue which seems to kill it.
Issue Found
Glue sends the API key to Zap as an HTTP query parameter instead of in the header which it expects. This causes Zap to throw an error like this:
Reproduction Steps
Assuming you have Zap version 2.6.0 running in api mode you can recreate this issue using:
Which will cause a log output of:
At this stage, the process dies due to the request sent to Zap including the Zap API Key in HTTP query param instead of the header.
Docker Image Versions Used
Zap: owasp/zap2docker-bare:2.6.0
Glue: owasp/glue:raw-latest
If there is any more info I can provide to help figure the issue out let me know.
The text was updated successfully, but these errors were encountered: