matusf / openapi-fuzzer

Black-box fuzzer that fuzzes APIs based on OpenAPI specification. Find bugs for free!
GNU Affero General Public License v3.0
526 stars 22 forks source link

Setting cookies ? #29

Closed shafr closed 12 months ago

shafr commented 12 months ago

Is there a way how to set up cookies for the session, so they would be authenticated ?

matusf commented 12 months ago

Yes, since cookies are just headers, you can use the -H flag to add an extra header. For example: -H "Cookie: key=val"

shafr commented 11 months ago

@matusf Please add to readme the setting cookies part, so people would not be confused:

It works with a single -H line like this (basically you copy cookie line from your browser developer tab & prepend -H and wrap in quotes):

-H "Cookie: A=1; B=2; C=3;"
matusf commented 11 months ago

fixed by https://github.com/matusf/openapi-fuzzer/commit/2c65d9e76a49d6b6d5347912a7f5ccd72a78666e