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

Compojure incorrectly returns a body for an HEAD method on a 401 response. #203

Closed
brown131 opened this issue Nov 10, 2021 · 2 comments
Closed

Comments

@brown131
Copy link

According to RFC-2616: "The HEAD method is identical to GET except that the server MUST NOT return a message-body in the response. " (https://w3.org/Protocols/rfc2616/rfc2616-sec9.html#sec9.4). However, when a HEAD method returns an HTTP 401 Unauthorized response it returns a body "access denied". This breaks, in particular, the Cyberduck client app, which expects the server to be well-behaved.

@weavejester
Copy link
Owner

Compojure doesn't handle authorisation. It sounds like the problem exists in some other middleware you're using.

@brown131
Copy link
Author

Yes. The issue appears to be in remvee/ring-basic-authorization. Sorry about that.

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

No branches or pull requests

2 participants