title: Can OAuth2 be utilized for token generation for non-social login types?
body: <p>I'm creating a RESTful web service with Spring MVC. I'm attempting to locate a secure way to generate authentication / access tokens for the client side (website) to connect to the web service. I've read up on OAuth2, but I've only seen it used for logging in through other platforms (Facebook, Google, etc.).</p>
  
  <p>My question is, can OAuth2 be used as a secure token generating library for access to a RESTful web service (no social media connection what-so-ever)? If not, what library is used for generating authentication codes?</p>
  
  <p><strong>EDIT FOR CLARIFICATION</strong></p>
  
  <p>The accounts are created and stored into my database and NOT connected to social media what-so-ever. I only see OAuth 2.0 talked about / mentioned when it's related to integrating social media login. </p>
  
  <p>Is OAuth 2.0 used for non-social media connection login systems or are there better options for this?</p>