-
Notifications
You must be signed in to change notification settings - Fork 20
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
Callback URL is invalid when getting temporary credentials. #5
Comments
I would have expected $server = new OAuthClient(array(
'identifier' => $_SESSION['client_key'],
'secret' => $_SESSION['client_secret'],
'api_root' => $_SESSION['site_base'],
'auth_urls' => $_SESSION['site_auth_urls'],
'callback_uri' => get_requested_url() . '?step=authorize',
)); but for me, using that URL gets the same error |
Spoke with @tollmanz, who had previously gotten this working, and he asserted that he used |
Try setting it without the URL parameters ( |
I just tested this again myself. I had the callback URL set as |
Adding the trailing slash did the trick for me. |
Is the requirement for the trailing slash a weakness of the oauth plugin, or the client app? I believe that it should be called out in one UI or another, since this tripped a bunch of us up. |
It's an issue in the OAuth callback validation: the URLs aren't being normalised. |
Hello, i've the same issue (Callback URL is invalid" when getting temporary credentials.). I've tried any combination of the callback I could also verify, that the passed credentials were correct. Any idea in which direction i could search for a solution? Many thanks in advance. |
Has someone resolved this issue yet? I have got stuck at this. Don't know what could be a valid callback url :( |
I set my callback url to include the /index.php and it finally went past this error. |
yeah,I run this at |
I just tested with the latest version of everything and it works fine. Just need the trailing slash |
I cannot get this to work. Tried with/without trailing slash. |
Tried with/without trailing slash, after authentication, tries to redirect and fails with: |
Callback URL you defined on WP Admin Panel must be same with your backend application and you must use |
I'm very confused about this whole process. I created an application in the WP admin, with a callback URL of In the example client I put in the site URL and it comes back as I provide the key and secret generated from the WP admin application. I am getting "Callback URL is invalid" when getting temporary credentials." through this.
What am I doing wrong? I can't figure out how to successfully make a request to get credentials either through this example client or otherwise. |
@pinksharpii Your callback URL needs to be exactly wherever the example client is hosted (must match scheme, host, port, and path). Are you hosting the example client at |
@rmccue No I substituted website.com for the actual client site for confidentiality. Does there need to be any query string parameters in the URL for it to work? |
@pinksharpii Yeah, I meant more "are you hosting the example client at [where you set the callback URL to]?", since usually the example client is hosted on a port on localhost. Specifically, the callback URL that the example client sends with the request needs to match the URL registered, and the example client gets this URL from You don't need any query string parameters. |
It is 2022 and this issue STILL has not been properly patched. Very shameful of Vercel. |
I'm not sure if this is an issue with the example-client or the oAuth server, but on step 2 I get the following error message no matter what callback URL is set as the callback in the oAuth server application.
Received HTTP status code [500] with message "Callback URL is invalid" when getting temporary credentials.
The text was updated successfully, but these errors were encountered: