Allow $absolute to be passed to ValidateSignature Middleware #36030
Unanswered
craftyshaun
asked this question in
Ideas
Replies: 1 comment
-
This is already done for 8.x: #33137 It could be backported to 6.x if they allow it, but the PR was originally rejected due to BC, which is why I resubmitted it. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
When developing with Signed URL's today I tried to add the
signed
middleware to my routes which is an instance ofIlluminate\Routing\Middleware\ValidSignature
. Initially, I kept getting '401 - Invalid Signature' errors.It wasn't until I dd()'d various internals I was able to see that Laravel was matching the whole URL when I was creating a signed URL with the
$absolute
option set tofalse
as we use different subdomains in our app.What I'd like to propose is the ability to pass the
$absolute
argument into the$request->hasValidSignature()
call inside the middleware using a middleware parameter.I'm happy to have a go at a PR for this feature assuming it passes a sense check from someone from the Laravel core team.
If this feature is not accepted them I'd like to suggest at the minimum a note be added to the docs that the
ValidSignature
middleware does not support non-absolute URL's out of the box.Beta Was this translation helpful? Give feedback.
All reactions