Implement FOSoAuth2 in Symfony 3

0

I am setting up an APIRest with the following bundles

  • FOSUserBundle
  • FOSRestBundle
  • FOSoAuth2Bundle
  • NelmioBundle (this to document the API)

I know how to get the authorization token to make the requests to the controllers. My problem is in the mechanism to obtain the authorization token through a route for a login action with public access.

I've been following this example and all I've come to get access_token launching the following request:

http://api.miapp.dev/app_dev.php/oauth/v2/token?grant_type=password&client_id=1_3bcbxd9e24g0gk4swg0kwgcwg4o8k8g4g888kwc44gcc0gwwk4&client_secret=4ok2x70rlfokc8g0wws8c8kwcokw80k44sg48goc0ok4w0so0k&username=usuario1&password=usuario1

My question is how to use another mechanism to not send all this churro when it comes to performing the part that consumes the services.

The user registry does not worry me because I will manage it personally, but the way that users consume the login through its corresponding endpoint.

    
asked by Makros 20.03.2018 в 20:38
source

0 answers