The new Java project studies online notes -day16 (b)

2 2.1 User Authentication aspect aspect single sign
distributed system to implement single sign-independent authentication system typically extracted, and the user identity information stored in a separate storage medium, such as: MySQL, Redis, considering the performance requirements, Redis typically stored in the following chart:
The new Java project studies online notes -day16 (b)
single sign-on features are:
1, the authentication system is a separate system.
2, each of the subsystems Http or other communication protocol with the authentication system, user authentication is completed.
3, the user identity information stored in the cluster Redis.
There are a lot of Java user authentication framework can achieve single sign-on:
. 1, the Apache Shiro
2, CAS 3, CAS 2.2 Oauth2 the Spring Security Certification
2.2.1 Oauth2 certification process
3.
third-party certification is the most important technical solutions to solve the authentication protocol the common standards, due to the cross-certification system, to follow certain protocol interfaces between systems.
OAUTH protocol provides a secure authorized user resources, open but simple standard. At the same time, any third party can use OAUTH authentication service, any service provider can achieve their own OAUTH certification services, thus OAUTH is open. OAUTH industry provides multiple implementations such as PHP, JavaScript, Java, Ruby and other language development kits, saves time programmer, so OAUTH is simple. Many Internet service such as Open API, many large companies such as Google, Yahoo, Microsoft and so provides OAUTH certification services, which are sufficient to show OAUTH becoming the standard open-source authorization standards.
Oauth protocol is currently at version 2.0, version 1.0 is too complex, version 2.0 has been widely used. reference:https://baike.baidu.com/item/oAuth/7153134?fr=aladdin
Oauth protocol: https://tools.ietf.org/html/rfc6749 below Oauth2 analysis of a certified example, programmers dark horse site uses micro-channel authentication the process:
The new Java project studies online notes -day16 (b)
1, the client requests a third party authorized
user enters a dark horse program login page, click on the icon to micro-channel micro-channel account login system, the user is the owner of its own information resources in the micro letter.
The new Java project studies online notes -day16 (b)
The new Java project studies online notes -day16 (b)

Guess you like

Origin blog.51cto.com/13517854/2415906