Single sign-on method, apparatus, device, and medium
By generating a signature through an authentication server and using the username and interface key for secure authentication, the issues of user sensitive information security and high interaction frequency in single sign-on are resolved, enabling users to securely access multiple systems with a single login.
Patent Information
- Application Number
- CN202311236232.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-09-22
- Publication Date
- 2026-11-20
- Estimated Expiration
- 2043-09-22
AI Technical Summary
Existing single sign-on technology poses risks to the security of sensitive user information and involves too many interactions, impacting efficiency.
The authentication server generates the first signature, and then uses the username, the destination server's interface key, and the timestamp for authentication to ensure secure access for the user and reduce the number of interactions.
This allows users to access multiple systems with a single login while ensuring security, simplifying the access process and improving efficiency.
Smart Images

Figure CN117176455B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of network technology, and in particular to a single sign-on method, apparatus, device, and medium. Background Technology
[0002] Single sign-on (SSO) refers to a system in which multiple systems coexist, allowing users to access all trusted applications by logging in only once. This simplifies user operations and improves work efficiency.
[0003] However, single sign-on technology often involves users' sensitive information. If this sensitive information is compromised, it can have a significant impact on multiple systems. Therefore, in order to ensure the security of users' information, existing technologies generally increase the number of interactions between the user and the server to repeatedly confirm whether the interaction standard has been met. Only when the standard is met can access the system. In fact, this approach does not fully leverage the advantages of single sign-on.
[0004] Therefore, further optimization of single sign-on is urgently needed. Summary of the Invention
[0005] This application provides a single sign-on method, apparatus, device, and medium to solve the problem of cumbersome user login to multiple systems in the prior art.
[0006] Firstly, this application provides a single sign-on method, including:
[0007] The authentication server determines whether the user terminal is allowed to access the destination server based on the user terminal's username and the identifier initiated by the user terminal, wherein the identifier is used to indicate the destination server to be accessed by the user terminal.
[0008] If it is confirmed that the user terminal is prohibited from accessing the destination server, a first signature is generated based on the username, the interface key of the destination server, and the timestamp, and the first signature is sent to the destination server.
[0009] If feedback is received from the destination server that the signature matches the first signature, the URL of the destination server and the encrypted token are sent back to the source server to switch the user's login from the source server to the destination server.
[0010] In one possible implementation, confirming that the user terminal is prohibited from accessing the destination server includes:
[0011] The database is queried based on the username and the identifier to confirm whether there is a valid token to access the target server.
[0012] If no valid token exists to access the destination server, then the client is confirmed to be prohibited from accessing the destination server.
[0013] In one possible implementation, generating a first signature based on the username, the interface key of the destination server, and a timestamp, and sending the first signature to the destination server, includes:
[0014] The authentication server transcodes the username, the interface key of the destination server, and the timestamp to generate a first signature. The transcoding method includes encrypted transcoding. The first signature includes the transcoded username, the interface key of the destination server, and the timestamp, where the timestamp is the current system time of the authentication server.
[0015] The generated first signature is sent to the destination server.
[0016] In one possible implementation, receiving feedback from the destination server regarding the first signature matching includes:
[0017] The username and timestamp are encrypted and sent to the destination server;
[0018] After the destination server confirms that the first signature is consistent with the second signature generated by the destination server, feedback from the destination server confirming the match of the first signature is received. The second signature is a signature generated by the destination server through transcoding based on the interface key of the destination server, the decrypted username, and the timestamp.
[0019] In one possible implementation, before confirming with the destination server that the first signature matches the second signature generated by the destination server, the method further includes:
[0020] After decrypting the timestamp through the destination server and confirming that the timestamp has not exceeded the preset time, the username is then decrypted through the destination server.
[0021] In one possible implementation, before sending the URL of the destination server and the encrypted token back to the source server, the method further includes:
[0022] Based on the feedback received from the destination server through the first signature matching, the encrypted token generated by the destination server and the URL of the destination server are obtained, wherein the URL is used to locate the user terminal from the source server to the destination server, and the token is the key for the user terminal to log in to the destination server.
[0023] Secondly, this application provides a single sign-on device, comprising:
[0024] The acquisition module is used by the authentication server to determine whether the user terminal is allowed to access the destination server based on the username of the user terminal and the identifier initiated by the user terminal, wherein the identifier is used to indicate the destination server to be accessed by the user terminal.
[0025] The processing module is configured to, if it is confirmed that the user terminal is prohibited from accessing the destination server, generate a first signature based on the username, the interface key of the destination server and the timestamp, and send the first signature to the destination server.
[0026] The forwarding module is used to send the URL of the destination server and the encrypted token back to the source server if it receives feedback from the destination server that matches the first signature, so as to switch the user's login from the source server to the destination server.
[0027] In one possible implementation, the processing module is specifically used for:
[0028] The database is queried based on the username and the identifier to confirm whether there is a valid token to access the target server.
[0029] If no valid token exists to access the destination server, then the client is confirmed to be prohibited from accessing the destination server.
[0030] Thirdly, this application provides a single sign-on device, comprising: at least one processor and a memory;
[0031] The memory stores computer-executed instructions;
[0032] The at least one processor executes the computer execution instructions stored in the memory, causing the at least one processor to perform the single sign-on method as described above.
[0033] Fourthly, this application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the single sign-on method as described above.
[0034] This application provides a single sign-on method, apparatus, device, and medium. An authentication server determines whether a user is allowed to access a destination server based on the user's username and an identifier initiated by the user. The identifier indicates the destination server the user is trying to access. If the user is denied access to the destination server, a first signature is generated based on the username, the destination server's interface key, and a timestamp, and sent to the destination server. If feedback is received from the destination server confirming a match with the first signature, the URL of the destination server and an encrypted token are sent back to the source server to switch the user's login from the source server to the destination server.
[0035] In the above method, the authentication server identifies the user by username and determines the destination server the user wants to access by using the identifier initiated by the user. If the user fails authentication, an access process is established. First, the server verifies whether the first signature, containing the username, the destination server's interface key, and a timestamp, passes the destination server's verification. If it does, the server receives feedback and forwards the destination server's URL and encrypted token to the source server. The user can then switch between servers, from the source server to the destination server. Therefore, the application ensures secure access to different servers while maintaining single sign-on for the user. Attached Figure Description
[0036] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0037] Figure 1 A schematic diagram of a single sign-on scenario provided in an embodiment of this application;
[0038] Figure 2 A flowchart illustrating a single sign-on method provided in this application embodiment. Figure 1 ;
[0039] Figure 3 A flowchart illustrating a single sign-on method provided in this application embodiment. Figure 2 ;
[0040] Figure 4 A flowchart illustrating a single sign-on method provided in this application embodiment. Figure 3 ;
[0041] Figure 5 A diagram of a single sign-on device provided in an embodiment of the present invention;
[0042] Figure 6 This is a hardware schematic diagram of a single sign-on device provided in an embodiment of the present invention. Detailed Implementation
[0043] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0044] Single sign-on (SSO) refers to a system in which multiple systems coexist, allowing users to access all trusted / authorized applications by logging in only once. As web technologies mature, enterprises may develop various distributed application systems to support their operations and growth. These independently operating systems require a unified authentication center for management to prevent users from logging in repeatedly—this is single sign-on—effectively improving work efficiency.
[0045] However, existing technologies do not prioritize security. During single sign-on, sensitive user information is often transmitted between multiple systems. If this sensitive information is stolen, it will have a significant impact on multiple systems. Furthermore, existing technologies typically require the client to initiate at least two requests to successfully access the target system, increasing the number of interactions between the client and the server and the number of times sensitive information is transmitted.
[0046] Therefore, this application proposes a method that allows access to multiple systems with a single login, taking into account security issues and simplifying transmission.
[0047] The implementation process of a single sign-on method proposed in this application is described below with reference to the accompanying drawings and specific embodiments.
[0048] Figure 1 This is a schematic diagram illustrating a single sign-on scenario provided in an embodiment of this application. For example... Figure 1 As shown, the system includes: a user terminal 101, an authentication server 102, and a business server 103; wherein, the business server 103 includes a source server 1031 and a destination server 1032.
[0049] Business server 103 is used to provide business support to client 101 and can install application systems as needed; source server 1031 is the server that client 101 is currently logging into and accessing; destination server 1032 is the server that client 101 will log into and access in the business server, and there must be at least one of them.
[0050] The authentication server 102 is used to authenticate the access of the user terminal 101. The authentication server 102 receives the username and the identifier initiated by the user terminal 101, identifies which destination server 1032 the user terminal 101 wants to access, and whether to allow the user terminal 101 to access it.
[0051] If not allowed, then the authentication server 102 generates a first signature based on the username, the interface key of the destination server 1032, and the timestamp (the system time of the authentication server 102). The destination server 1032 then authenticates the first signature. If the authentication is successful, the destination server's URL and an encrypted token are given to the user, allowing the user to complete the access switch using the token and the URL.
[0052] Figure 2 A flowchart illustrating a single sign-on method provided in this application embodiment. Figure 1 .like Figure 2 As shown, the method includes:
[0053] S201. The authentication server determines whether the user terminal is allowed to access the destination server based on the username of the user terminal and the identifier initiated by the user terminal, wherein the identifier is used to indicate the destination server to be accessed by the user terminal.
[0054] An authentication server can be used to perform preliminary authentication of information when a user requests access to a business server. When a user initiates a request to access a destination server from the source server, it will carry the identifier of the destination server. At this time, the authentication server can be invoked. The authentication server can determine which user is accessing the server based on the username and which destination server the user is preparing to access based on the identifier.
[0055] Both the source server and the destination server are business servers. Each business server has a unique identifier, so each business server can be identified through the identifier, including the destination server.
[0056] Based on the username and identifier, initial authentication can be performed to determine whether the client can access the destination server. The actual access process requires verification of the token carried by the client.
[0057] For example, the database is queried based on the username and the identifier to confirm whether there is a valid token to access the destination server;
[0058] If no valid token exists to access the destination server, then the client is confirmed to be prohibited from accessing the destination server.
[0059] When a client initiates a request to access the destination server, it also carries a token. The source server can obtain the client's username based on the token and send the client's username, the destination server's identifier, and the token to the authentication server.
[0060] The authentication server queries its database based on the username and identifier to verify whether the target server the user wants to access matches the user's token. If they match, the token is considered valid, and the user can access the target server. If they do not match, the token is considered invalid, and the user does not have a valid token to access the target server. In this case, the user cannot access the target server. Subsequently, the target server can generate a new token for the user, allowing the user to access the target server.
[0061] S202. If it is confirmed that the user terminal is prohibited from accessing the destination server, a first signature is generated based on the username, the interface key of the destination server and the timestamp, and the first signature is sent to the destination server.
[0062] If it is confirmed that the destination server does not allow the client to access, the destination server can generate a token for the client so that the client has a valid token for subsequent access. Before generating this token, the authentication server needs to create a signature, i.e., the first signature, and the destination server needs to authenticate the first signature before generating the token.
[0063] The rules for generating the first signature are pre-set in the authentication server. Using these rules, the authentication server can create the first signature from the username, the destination server's API key, and the timestamp. This is to prevent the information being transmitted from being leaked when the first signature is transmitted. The first signature also needs to be encrypted when it is transmitted to the destination server to ensure information security. The encryption method includes symmetric encryption (Advanced Encryption Standard, AES).
[0064] S203. If feedback is received from the destination server that the signature matches the first signature, the URL of the destination server and the encrypted token are sent back to the source server to switch the user's login from the source server to the destination server.
[0065] After receiving the first signature, the destination server can also receive the username and timestamp. The destination server uses the username, timestamp, and its own identifier to check whether they match the information in the first signature. If they match, the first signature is valid, and the destination server performs a match based on the first signature.
[0066] After the initial signature is matched, the destination server sends a response to the authentication server, which includes the generated token (which will be transmitted in encrypted form) and the URL of the destination server.
[0067] For example, based on the feedback received from the destination server through the first signature matching, the encrypted token generated by the destination server and the URL of the destination server are obtained, wherein the URL is used to locate the user terminal from the source server to the destination server, and the token is the key for the user terminal to log in to the destination server.
[0068] Based on the feedback received from the destination server that the first signature is matched, the authentication server can retrieve the URL of the destination server and the encrypted token. The authentication server will then concatenate the URL and the token and forward them to the source server. The source server will then allow the user to switch access to the destination server. The URL is a transition page for accessing the destination server. The user finds the destination server on the source server based on the URL and logs in to the destination server using the token, thus completing the access switch. The user only needs to log in once.
[0069] In this embodiment, the authentication server identifies the user by username and determines the destination server the user intends to access by using the identifier initiated by the user. If the user fails authentication, an access process is initiated. First, the server verifies the first signature, which includes the username, the destination server's interface key, and a timestamp. If successful, the server receives feedback and forwards the destination server's URL and encrypted token to the source server. The user can then switch between servers, from the source server to the destination server. Therefore, this application ensures secure access to different servers while maintaining single sign-on for the user.
[0070] Figure 3 A flowchart illustrating a single sign-on method provided in this application embodiment. Figure 2 .like Figure 3 As shown, the method includes:
[0071] S301, the authentication server transcodes the username, the interface key of the destination server, and the timestamp to generate a first signature, wherein the transcoding method includes encrypted transcoding, and the first signature includes the transcoded username, the interface key of the destination server, and the timestamp, wherein the timestamp is the current system time of the authentication server.
[0072] The authentication server encodes the username, destination server's interface key, and timestamp using rules pre-written into the authentication server, a process similar to encrypting the information. The resulting signature includes the username, destination server's interface key, and timestamp, but even if a non-transmission object accidentally obtains the signature, it cannot know the meaning of the signature's content, ensuring information security. The timestamp represents the authentication server's current system time and is used later to compare whether the information has expired.
[0073] S302. Send the generated first signature to the destination server.
[0074] The authentication server forwards the first signature to the destination server, pending confirmation from the destination server that the first signature matches the second signature it generated.
[0075] S303. The username and timestamp are encrypted and sent to the destination server.
[0076] Before generating the second signature, the destination server will also receive the username and timestamp from the authentication server. This information will be transcoded by the destination server into part of the signature.
[0077] S304. After decrypting the timestamp through the destination server and confirming that the timestamp has not exceeded the preset time, decrypt the username through the destination server.
[0078] The destination server decrypts the timestamp to obtain the time when the authentication server created the first signature, and confirms whether the time corresponding to the timestamp exceeds the preset time. If it does, the first signature is confirmed to have expired and no further processing is performed. The destination server generates an error message (to indicate the access result), which is forwarded by the authentication server and the origin server to inform the user that the access result is an access failure.
[0079] If the timeout period is not exceeded, the destination server can start creating the second signature. The preset time can be set to a 30-second interval. For example, if the system time corresponding to the timestamp is more than 30 seconds earlier than the system time after decryption by the destination server, the timeout will occur. If it is within 30 seconds, the timeout will not occur.
[0080] S305. After the destination server confirms that the first signature is consistent with the second signature generated by the destination server, feedback from the destination server that the first signature is matched is received, wherein the second signature is a signature generated by the destination server through transcoding based on the interface key of the destination server, the decrypted username and the timestamp.
[0081] The destination server generates the second signature in a similar way to the authentication server, except that the generation rules may be different. The destination server receives the username and timestamp sent by the authentication server, and generates the second signature together with its own interface key. It then compares the first and second signatures to see if they are completely identical. If they are identical, the first signature is valid, and the destination server sends feedback to the authentication server that the first signature has been matched. The authentication server receives the feedback and can begin subsequent work. The feedback includes the generated token for the client to access the destination server.
[0082] In this embodiment, the authentication server generates a first signature based on the username, interface key, and timestamp. The username and timestamp are then transmitted to the destination server, which verifies that the first signature has expired. If it hasn't expired, the destination server generates a second signature based on the username, its own interface key, and the timestamp. If the first and second signatures match, a match is established. The destination server can then generate a token for the user, allowing the user to access the destination server, thus enabling secure access to multiple systems with a single login.
[0083] Figure 4 A flowchart illustrating a single sign-on method provided in this application embodiment. Figure 3 .like Figure 4 As shown, the method includes:
[0084] S401. The authentication server queries its database, obtains the single sign-on transition page URL of the destination server based on the identifier of the destination server, and concatenates the URL with the encrypted token, and returns it to the source server.
[0085] The authentication server queries its own database, finds the URL of the destination server's transition page, and concatenates the URL with the encrypted token returned by the destination server before sending it back to the origin server.
[0086] S402. The origin server redirects the client to a transition page based on the URL.
[0087] At this point, the user is still accessing the origin server. You can redirect the user to a transition page based on the URL on the origin server.
[0088] S403. The client obtains the encrypted token from the transition page URL, decrypts the encrypted token, and stores it locally.
[0089] The user receives the encrypted token on the transition page, stores it locally for use, and can use the token every time they access the destination server. In other words, they will have a valid token when authenticating with the authentication server in the future.
[0090] S404. Based on the token, the client successfully accesses the destination server and completes the destination server login.
[0091] Based on the token, the client can access the target server, which is also the process of logging into the target server.
[0092] In this embodiment of the application, after confirming the generation of the token, the subsequent access work of the user terminal is completed, ensuring that the user terminal can log in and access the target server.
[0093] Figure 5 A diagram of a single sign-on device provided in an embodiment of the present invention is shown, such as... Figure 5 As shown, the device includes: an acquisition module 501, a processing module 502, and a forwarding module 503;
[0094] The acquisition module 501 is used by the authentication server to confirm whether the user terminal is allowed to access the destination server based on the username of the user terminal and the identifier initiated by the user terminal, wherein the identifier is used to indicate the destination server to be accessed by the user terminal.
[0095] The processing module 502 is configured to, if it is confirmed that the user terminal is prohibited from accessing the destination server, generate a first signature based on the username, the interface key of the destination server and the timestamp, and send the first signature to the destination server.
[0096] The processing module 502 is further configured to query the database based on the username and the identifier to confirm whether there is a valid token for accessing the destination server;
[0097] If no valid token exists to access the destination server, then the client is confirmed to be prohibited from accessing the destination server.
[0098] The processing module 502 is further configured to transcode the username, the interface key of the destination server, and the timestamp of the authentication server to generate a first signature, wherein the transcoding method includes encrypted transcoding, and the first signature includes the transcoded username, the interface key of the destination server, and the timestamp, wherein the timestamp is the current system time of the authentication server;
[0099] The generated first signature is sent to the destination server.
[0100] The forwarding module 503 is used to send the URL of the destination server and the encrypted token back to the source server if it receives feedback from the destination server that the signature matches the first signature, so as to switch the user's login from the source server to the destination server.
[0101] The forwarding module 503 is also used to encrypt the username and the timestamp and send them to the destination server;
[0102] After the destination server confirms that the first signature is consistent with the second signature generated by the destination server, feedback from the destination server confirming the match of the first signature is received. The second signature is a signature generated by the destination server through transcoding based on the interface key of the destination server, the decrypted username, and the timestamp.
[0103] This application also provides a single sign-on device, including: at least one processor and a memory;
[0104] The memory stores computer-executed instructions;
[0105] The at least one processor executes computer execution instructions stored in the memory, causing the at least one processor to execute the single sign-on method.
[0106] Figure 6 This is a hardware schematic diagram of a single sign-on device provided in an embodiment of the present invention. Figure 6 As shown, the single sign-on device 60 provided in this embodiment includes at least one processor 601 and a memory 602. The device 60 also includes a communication component 603. The processor 601, memory 602, and communication component 603 are connected via a bus 604.
[0107] In the specific implementation process, at least one processor 601 executes the computer execution instructions stored in the memory 602, causing at least one processor 601 to execute the single sign-on method as described above.
[0108] The specific implementation process of processor 601 can be found in the above method embodiments, and its implementation principle and technical effect are similar. It will not be repeated here.
[0109] In the above Figure 6In the illustrated embodiments, it should be understood that the processor can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), etc. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in this invention can be directly implemented by a hardware processor, or implemented by a combination of hardware and software modules within the processor.
[0110] The memory may include random access memory (RAM) and may also include non-volatile memory (NVM), such as at least one disk storage device.
[0111] The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. Buses can be categorized as address buses, data buses, control buses, etc. For ease of illustration, the buses shown in the accompanying drawings are not limited to a single bus or a single type of bus.
[0112] This application also provides a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, implement the single sign-on method as described above.
[0113] The aforementioned computer-readable storage medium can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk. The readable storage medium can be any available medium accessible to a general-purpose or special-purpose computer.
[0114] An exemplary readable storage medium is coupled to a processor, enabling the processor to read information from and write information to the readable storage medium. Of course, the readable storage medium can also be a component of the processor. The processor and the readable storage medium can reside in an Application Specific Integrated Circuit (ASIC). Alternatively, the processor and the readable storage medium can exist as discrete components in the device.
[0115] The division of units described herein is merely a logical functional division. In actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be indirect coupling or communication connection through some interfaces, devices, or units, and may be electrical, mechanical, or other forms.
[0116] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0117] Those skilled in the art will understand that all or part of the steps of the above-described method embodiments can be implemented by hardware related to program instructions. The aforementioned program can be stored in a computer-readable storage medium. When executed, the program performs the steps of the above-described method embodiments; and the aforementioned storage medium includes various media capable of storing program code, such as ROM, RAM, magnetic disks, or optical disks.
[0118] Finally, it should be noted that other embodiments of the invention will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This invention is intended to cover any variations, uses, or adaptations of the invention that follow the general principles of the invention and include common knowledge or customary techniques in the art not disclosed herein, and is not limited to the precise structures described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of the invention is limited only by the appended claims.
Claims
1. A single sign-on method, characterized in that, include: The authentication server determines whether the user is allowed to access the destination server based on the user's username and the identifier initiated by the user. The identifier indicates the destination server to be accessed by the user. The authentication server performs preliminary authentication on the information of the user accessing the business server. The business server includes a source server and a destination server. The source server is the server that the user is currently logging into, and the destination server is the server that the user will log into. When the user initiates a request to access the destination server from the source server, it carries the identifier of the destination server, at which point the authentication server is invoked. If it is confirmed that the user terminal is prohibited from accessing the destination server, a first signature is generated based on the username, the interface key of the destination server, and the timestamp, and the first signature is sent to the destination server. If feedback is received from the destination server that the signature matches the first signature, the URL of the destination server and the encrypted token are sent back to the source server to switch the user's login from the source server to the destination server.
2. The method according to claim 1, characterized in that, The confirmation that the user client is prohibited from accessing the destination server includes: The database is queried based on the username and the identifier to confirm whether there is a valid token to access the target server. If no valid token exists to access the destination server, then the client is confirmed to be prohibited from accessing the destination server.
3. The method according to claim 1, characterized in that, The step of generating a first signature based on the username, the interface key of the destination server, and a timestamp, and sending the first signature to the destination server, includes: The authentication server transcodes the username, the interface key of the destination server, and the timestamp to generate a first signature. The transcoding method includes encrypted transcoding. The first signature includes the transcoded username, the interface key of the destination server, and the timestamp, where the timestamp is the current system time of the authentication server. The generated first signature is sent to the destination server.
4. The method according to claim 3, characterized in that, The receipt of feedback from the destination server through the first signature matching includes: The username and timestamp are encrypted and sent to the destination server; After the destination server confirms that the first signature is consistent with the second signature generated by the destination server, it receives feedback from the destination server that the first signature is matched. The second signature is a signature generated by the destination server through transcoding based on the interface key of the destination server, the decrypted username, and the timestamp.
5. The method according to claim 4, characterized in that, Before confirming with the destination server that the first signature matches the second signature generated by the destination server, the method further includes: After decrypting the timestamp through the destination server and confirming that the timestamp has not exceeded the preset time, the username is then decrypted through the destination server.
6. The method according to claim 1, characterized in that, Before sending the URL of the destination server and the encrypted token back to the source server, the method further includes: Based on the feedback received from the destination server through the first signature matching, the encrypted token generated by the destination server and the URL of the destination server are obtained, wherein the URL is used to locate the user terminal from the source server to the destination server, and the token is the key for the user terminal to log in to the destination server.
7. A single sign-on device, characterized in that, include: The acquisition module is used by the authentication server to determine whether the user terminal is allowed to access the destination server based on the user terminal's username and the identifier initiated by the user terminal. The identifier indicates the destination server to be accessed by the user terminal. The authentication server performs preliminary authentication on the information regarding the user terminal's access to the business server. The business server includes a source server and a destination server. The source server is the server the user terminal is currently logging into, and the destination server is the server the user terminal will be logging into from within the business server. When the user terminal initiates a request to access the destination server from the source server, it carries the identifier of the destination server, at which point the authentication server is invoked. The processing module is configured to, if it is confirmed that the user terminal is prohibited from accessing the destination server, generate a first signature based on the username, the interface key of the destination server and the timestamp, and send the first signature to the destination server. The forwarding module is used to send the URL of the destination server and the encrypted token back to the source server if it receives feedback from the destination server that matches the first signature, so as to switch the user's login from the source server to the destination server.
8. The apparatus according to claim 7, characterized in that, The processing module is specifically used for: The database is queried based on the username and the identifier to confirm whether there is a valid token to access the target server. If no valid token exists to access the destination server, then the client is confirmed to be prohibited from accessing the destination server.
9. A single sign-on device, characterized in that, include: At least one processor and memory; The memory stores computer-executed instructions; The at least one processor executes computer execution instructions stored in the memory, causing the at least one processor to perform the single sign-on method as described in any one of claims 1-6.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the single sign-on method as described in any one of claims 1-6.
Citation Information
Patent Citations
Single-point log-in method, system and system and log-in service platform
CN101764806A
Agent-based single sign on (SSO) method and system
CN102111410A
