1. About Oauth2
Vaguely feel integrated oauth2, with good it is a less simple thing, need to understand oauth2.
Oauth2 better reference, are others original article: integrated OAuth2 Getting Started detailed tutorial Understanding OAuth 2.0
2. Integration process 2.1 Adding dependencies
<!-- oauth2 --> < dependency > < groupid > org.springframework.security.oauth</ groupid > < artifactid > Spring-security-oauth2</ artifactid Span style= "COLOR: #0000ff" >> </ Dependency >
After adding dependencies, if the pom file is an error, type
Failure to transfer org.hamcrest:hamcrest-core:jar:1.3 .... is chached in the local repository
This means that there is a local cache, the corresponding packet in the local repository deleted, and then right-click the project to->maven->update Project, report which package is the wrong to delete the package.
The reason for this error is that there is a. lastupdated file under the corresponding package, which you can delete by deleting the files.
There are similar solutions on StackOverflow.
Springboot Integrated Oauth2