Announcement Announcement Module
No announcement yet.
Authentication Only: Resource Owner Password Credentials Grant Type Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • Authentication Only: Resource Owner Password Credentials Grant Type

    Hi there,

    I am trying to migrate one of our web applications to authenticate against a remote authorization server (which is implemented by Spring Security OAuth 2.0).

    This web application uses Spring Security already, and I'd like to just capture the login credentials and pass them through a resource owner password credentials grant flow. Properly capitalizing on OAuth2 authorization needs to come later.

    As this is a divergence from the sparkr/tonr example, I'm having trouble figuring out how to configure the OAuth2 components on the client side.

    My question is:
    In order to get this working, what Spring Security configuration elements are required in the client web application?

    Many thanks for any help,

  • #2
    The main interface for a client is OAuth2RestTemplate, so get yourself an instance of that and everything follows from there. Fot passwrod grant you should create a new instance for every call because you can't hard-code the user credentials in a configuration file.


    • #3
      Thank you Dave,

      I will try it from that angle.