Skip to content
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

Feature: OPTIONSBLEED #703

Open
drwetter opened this issue Oct 12, 2020 · 3 comments
Open

Feature: OPTIONSBLEED #703

drwetter opened this issue Oct 12, 2020 · 3 comments

Comments

@drwetter
Copy link
Contributor

Description

... would be great to get added. Check doesn't seem to be rocket science, to me.

Links/Info

https://blog.fuzzing-project.org/60-Optionsbleed-HTTP-OPTIONS-method-can-leak-Apaches-server-memory.html
https://nvd.nist.gov/vuln/detail/CVE-2017-9798

@sullo
Copy link
Owner

sullo commented May 8, 2021

Interesting bug. The only idea I can think of to check for this would be to assume that all actual HTTP methods would match /^[A-Z]+$/. Anything in the Allow header that doesn't match that pattern would have to alert.

The other alternative would be to have a list of possible methods and call out anything not in that list. It would be reasonable with normal HTTP methods and WebDAV methods, but I'm not sure what others exist. Perhaps alerting on "weird" methods is desirable anyway? In any case, this would be more false-positive prone IMO.

Thoughts?

@drwetter
Copy link
Contributor Author

drwetter commented May 10, 2021

Interesting bug. The only idea I can think of to check for this would be to assume that all actual HTTP methods would match /^[A-Z]+$/. Anything in the Allow header that doesn't match that pattern would have to alert.

Sounds good. I believe one comma should be added and the pattern seems to require extra care: Allow: POST,OPTIONS,GET,HEAD should be ok (including maybe some spaces). However others are not ok: (taken from https://blog.fuzzing-project.org/60-Optionsbleed-HTTP-OPTIONS-method-can-leak-Apaches-server-memory.html): Allow: ,GET,,,POST,OPTIONS,HEAD,, or Allow: GET,HEAD,OPTIONS,,HEAD,,HEAD,,HEAD,,

Maybe I am missing something but the alternative you suggested doesn't sound so difficult:

Standard methods: GET, POST, HEAD, PUT, PATCH, DELETE, TRACE, OPTIONS, CONNECT (~from old HTTP.1.1 standard)
WebDAV: PROPFIND, PROPPATCH, MKCOL, COPY, MOVE, LOCK, UNLOCK
In addition: https://datatracker.ietf.org/doc/html/rfc7237#section-3

@iasdeoupxe
Copy link
Contributor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants