I have created a REST service using spring and security with oauth2 currently when I hit the url I get the access token and then using it I send my basic login credentials which is static in my file in the spring_security.xml file.
How can I provide user authentication using database?
<authentication-manager alias="authenticationManager"
xmlns="http://www.springframework.org/schema/security">
<authentication-provider>
<user-service>
<user name="majid" password="majid" authorities="ROLE_APP" />
<user name="majid1" password="majid1" authorities="ROLE_USER" />
</user-service>
</authentication-provider>
</authentication-manager>