Open Elexy opened 11 years ago
I would love to see @jfaissolle 's change merged in! :)
I don't think you can make the domain name part of returnURL
option of an OpenID RP dynamic because returnURL is a fixed URL on the RP side and this value will be set once only.
There's one commit on my fork of node-openid, it added query string to returnURL
which means only the query string can change. for example:
http://localhost:8080/authcallback?url=http://localhost:8080/foo
http://localhost:8080/authcallback?url=http://localhost:8080/bar
After checking the code, my solution would be give returnURL
the path for returning (example: "/auth/google/return"
) and have authenticate()
get the hostname on each request from req.headers.host
.
@jfaissolle I didn't saw yours that's a nice solution :+1: we need that PR
Any news on this? Is there any problem with @jfaissolle's solution?
+1
Would love to be able to pass a custom callbackURL via openid.
:+1:
I am using the OpenID (google) implementation and would like to have dynamic return urls based on the request.
I'm talking about this returnUrl:
I can take the one from env, but I want the hostname+port from the request, because we have multiple hostnames pointing to the IP.
Can it be done with the current passport version?