OAuth login for full-petstore-api no working
I just downloaded the code as of today and tried out the (full-petsotre-api(/v2/api-docs?group=full-petstore-api)) pull down
when I select the Authorize button, I see the Available authorizations dialog come up. I select one and select Authorize.
the url changes to http://petstore.swagger.io/api/oauth/dialog?response_type=token&redirect_uri=http%3A%2F%2Flocalhost%3A8080%2Fspringfox%2Fwebjars%2Fspringfox-swagger-ui%2Fo2c.html&realm=pets&client_id=abc&scope=write%3Apets%2Cread%3Apets%2CvendorExtensions&state=petstore_auth
then I see Http Error 404 Problem accessing /api/oauth/dialog. Reason: Not Found
All I did was build and run as per the example. Is something missing?
That is just a fake endpoint for oauth. It doesnt support authentication. Also make sure swagger-ui support the authentication profile you want. AFAIK its not 100% supported.
hmmm, I wanted to compare somethign that worked with the code I wrote for my own project.
I wrote a oauth server app that my spring boot service authenticates via Oauth2. The login on the oauth server (spring security OAuth2 AuthorizationServer) works as well as hitting it with a curl. So I setup the implict grant as per the example and I can see that the spring fox swagger does go to the login on my oauth2 server.
However, after I feed in creds, the redirect url is nonsense.
Just wanted to compare with something that was already working.