We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Here is the background, I set up a GoToSocial instance and put it behind caddy with this cache module enabled.
I can't follow my account on this instance from the others like https://mastodon.social/
Then I noticed that there are lots of 401 Unauthorized logs in the instance.
I figured out when other instance fetching my resource, they signed their HTTP requests, request_uri+Date+Host are signed.
And somehow, this cache plugin, overwritten the Date header, made the signature invalid.
For example, it changed the Date header from Date: Tue, 10 Dec 2024 06:24:24 GMT to Date: Tue, 10 Dec 2024 06:24:24 UTC
Date: Tue, 10 Dec 2024 06:24:24 GMT
Date: Tue, 10 Dec 2024 06:24:24 UTC
The text was updated successfully, but these errors were encountered:
I manually comment out this line to solve this issue.
https://github.com/darkweak/souin/blob/7fb48f52de3dc2778538ef65fd6329d998f76151/context/now.go#L23
Sorry, something went wrong.
Hi @imlonghao I will write a patch for that to set the date only if the date is not already set in the request.
fix(now context): caddyserver/cache-handler#116
ed12ace
Successfully merging a pull request may close this issue.
Here is the background, I set up a GoToSocial instance and put it behind caddy with this cache module enabled.
I can't follow my account on this instance from the others like https://mastodon.social/
Then I noticed that there are lots of 401 Unauthorized logs in the instance.
I figured out when other instance fetching my resource, they signed their HTTP requests, request_uri+Date+Host are signed.
And somehow, this cache plugin, overwritten the Date header, made the signature invalid.
For example, it changed the Date header from
Date: Tue, 10 Dec 2024 06:24:24 GMT
toDate: Tue, 10 Dec 2024 06:24:24 UTC
The text was updated successfully, but these errors were encountered: