OAuth2 do not get the access token - paw-app

I configured an Authorization Dynamic value. All is correct but when I clicked the "Get the access token" button.
The access token is not copied in the token input
enter image description here
And all requests with the authentication are failed.
But if I copied manually the access token, all requests works.
What is the problem ?
I reinstalled the application without success

We are aware of some issues with the OAuth2 integration in Paw 3.2 which we aim to fix in the following weeks. Try to install the previous release http://paw.cloud/download/3.1.10 which should help here.
Please accept our apologies for any inconvenience caused!
The Paw Team

Related

Unable to add Authorized redirect URI for OAuth 2.0 client

I'm setting up an OAuth client for a Firebase application on Firebase Hosting, and I'm trying to add an authorized redirect URI to the "Web client (auto created by Google Service)" here:
https://console.cloud.google.com/apis/credentials/oauthclient
I'd like to add https://my-project.web.app/serviceworker/redirect but the update operation silently fails - loader just keeps spinning - and reports the following in the console:
Uncaught Proxy {Symbol(Symbol.toStringTag): "ErrorResponse"}
and
Uncaught Error: Ch
I'd rather not post the specific domain here, but the strange thing is, I've been able to add it in another project, as a test, and I've also been able to add the https://www.my-project.firebaseapp.com/serviceworker/redirect address with no issues. And for what it's worth, the subdomain https://www.my-project.web.app/serviceworker/redirect was also fine. (Although it doesn't actually fix my issue)
So it seems to be a specific issue with this particular domain and in this particular project.
Posting here in the hopes that someone on Google's side has any more ideas, as I'm at a loss.
Thanks in advance.
I have no idea why this would make a difference for this specific domain, but the issue resolved itself once I went through the "OAuth consent screen" setup.
So if you encounter this issue, I'd make sure everything's set up there first.

Querying Bookings API using Microsoft Graph isnt working

I am trying to use Microsoft flow to retrieve Microsoft Bookings data. Im doing this by using the HTTP with azure AD connector. I have set up all permissions. it was working perfectly fine before till yesterday the connector said i'm unauthorized to retrieve the data. i can't even hit https://graph.microsoft.com/beta/bookingBusinesses/page_id/appointments anymore. Is there some issue with Microsoft ??? or is there an issue on my side.i’ve used graph explorer and im able to successfully retrieve the bookings api. could someone provide some feedback as this is becoming business critical as i need to obtain the data for reporting. Or maybe guide me on how i can retrieve an access token that never expires. It would be much appreciated if someone can really help me out. I've attached a screenshot of my flow failing.
Screenshot of HTTP with Azure AD failing . I've just also found out that i can query https://graph.microsoft.com/beta but i cant hit the BookingBusinesses api
Screen shot of https://graph.microsoft.com/beta working using connector
What i have already tried:
Deleted the connection and created it again
Created a connection using another account
Created App registrations and used the Client_id, tenant_id and client_secret to Created a connection using the HTTP request. but still doesn't work
Screenshot of HTTP Request Connector, but this still failed
App registration Permissions
For this problem, I test it by "Invoke an HTTP request" first but as I'm not familiar with this action, I didn't request it success. But we can also use "HTTP" action in microsoft flow to get the access token and use the access token to do the request as you mentioned in comments.
The reason for you failed to use the access token to request the graph api is you set the grant_type as client_credentials when you request for the access token. Since the permissions you added are "delegated" type but not "application" type, so we can not use "client_credentials" grant to get the access token. We need to use "password" as the grant_type (shown as below screenshot).
Then use "Parse JSON" action to parse the response of the "HTTP" request above to get the access token. And use the access token to request the graph api.
My guess is the flow connector lost its refresh token or something to that effect. you may need to just refresh your flow connector. either by switching accounts or smoething or deleting the azure ad connector and reconnecting it.
give that a try

How to debug the 401 error of ASP.NET 4.6 WebAPI?

I'm working on a web api project which is secured by Azure AD endpoint v2.0. However, I get tons of 401 errors, even I copy the code from the working examples for Github.
My question is how can I debug the 401 error in a most efficient way? As there is little information for the error message:
{
"Message": "Authorization has been denied for this request."
}
You can use Fiddler to dig into the details of exactly what is being sent and received, when.
Have you made sure the user you're attempting to authenticate with does not have multifactor authentication enabled? You'll get 401's for seemingly no reason if MFA is enabled and you try to auth programmatically. If you have already disabled it, post up your auth code here and we'll take a close look.

"An error occurred while processing your request." with facebook authentication

I have a fresh asp.net application which has facebook authentication button on it. When I do the authentication on localhost it works flawlessly but when I publish and try to do it on work4me.azurewebsites.net it comes up with the error:
An error occurred while processing your request.
I have set the appID, app secret, domain, correct URL, and http://work4me.azurewebsites.net/signin-facebookas the oauth redirect URI. But it seems like it is hanging for a bit saying "waiting for domain name" before giving me the error.
If I try to enable facebook authentication on the azure portal it works however after logging in the application crashes and gives me the error "Server Error in '/' Application.".
I have followed the guide to enable facebook authentication on azures website but with no luck.
What am I doing wrong here?
EDIT:
It seems to get past that point now, and the error is with the redirect URI. However I have followed this example and use the URL https://work4me.azurewebsites.net/.auth/login/facebook/callback as the guide says but still it wont work, giving me the error that the URI is blocked.
It's been a few months since I first tried this, but I was able to get it working both locally and on Azure, by following the online instructions.
Did you enable User Secrets during development to access your credentials from Application Secrets? If so, you need to create environment variables in your Azure Web App to mirror these values under Application Settings.
Let me know if you still have any issues, then I can look into it some more.
All the best! :)

How do you debug an ASP.Net application accessing an OAuth secured API?

I know there has to be an obvious solution to this problem and I am missing it, so I would much appreciate someone enlightening me so I don't spin my wheels...
I am writing an ASP.Net application that will interact with a service API (Evernote specifically). Evernote requires OAuth for security and before I can actually interact with the objects I need to obtain a token.
The workflow goes like this (explaining it to myself as much as anyone else!):
Build a url with my development api key and secret key and some other OAuth stuff, send it to Evernote to request an access token.
Send the url as a request to Evernote and pull the new access token out of the response
Build another url with the access token to request an authentication token for the user. This url goes to a page the user must interact with to login (if they haven't already) and then authorize my application to access their account. The last param of the url I build is a callback url which will be called from Evernote's servers.
If all goes well, Evernote will request the callback url and include the new authentication token as a param.
Once my server receives the callback with the embedded token I can use it so that my app can interact with the users' notes on subsequent requests.
The problem is that I'm writing this app on a local box, not an ISP under a public domain. So my callback is to the localhost server. Of course, localhost is relative, so Evernote can't resolve my callback... I can't ever receive an authentication token and debug at the same time.
There has to be a way around this problem because this authentication model is not unique to Evernote (by a longshot... Flickr uses it as do a lot of other services). So can someone tell me how to set things up so I can get the authentication token and still be able to debug on my local box?
Help is much appreciated!
OAuth is quite tough to implement. It may not be the answer you're looking for, but this is how I managed to get the job done:
Write some code on my local dev machine.
Run a bat file (or alternatively hook a post-build event in VS) that executes a msbuild deploy script and deploys the application to a test server.
Run the application on the test server. After obtaining the request token and requesting for authorization it redirects to the Evernote website.
After successful authorization the Evernote website redirects back to my test server and the authorized request token is exchanged for an access token.
Instead of debugging (I don't have VS on the test server) I examine the logs of the application (the logging I used was as simple as writing to a text file).
Rinse and repeat
For the purposes of testing I registered a temporary public subdomain (e.g. testing.oauth.mydomain.com) so that Evernote will be able redirect to that url.
According to this (How do I develop against OAuth locally?) the callback is issued by the browser, so it should be able to hit localhost.

Resources