Authentication and data storage methods and devices for cross-system login based on blockchain
By generating and uploading blockchain authentication factors for dual-match verification during cross-system login, the security issue of identity authentication between systems is solved, data immutability and traceability are achieved, and the security and user experience between systems are improved.
Patent Information
- Application Number
- CN202510328696.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-19
- Publication Date
- 2025-10-28
- Estimated Expiration
- 2045-03-19
AI Technical Summary
Existing technologies lack multi-layered security for inter-system identity authentication, authentication data is easily tampered with, and data reliability and traceability cannot be achieved. Single sign-on mechanisms rely on the first system's authentication factor, resulting in low security. Traditional encryption and decryption methods lack the protection of blockchain technology.
By using blockchain technology during the cross-system login process, first and second authentication factors are generated and uploaded. The immutability and traceability of the blockchain are used for dual matching verification to ensure the security of cross-system data transmission. User information is stored in the blockchain for automatic updates and matching.
It achieves high security and consistency in cross-system login, prevents authentication factor tampering, enhances the system's resistance to attacks, ensures data integrity and reliability, and improves user experience and system stability.
Smart Images

Figure CN120017406B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of system login technology, and more specifically, to an authentication and data storage method and a data storage device for cross-system login based on blockchain. Background Technology
[0002] With the rapid development of information and digital technologies, more and more companies rely on the interaction and collaboration between multiple systems in their daily operations. However, with the frequent data transfer and switching between systems, ensuring effective user authentication and secure switching between systems has become a major challenge in current technology applications. Especially in enterprise applications, Single Sign-On (SSO) has become a common authentication solution. Through SSO, users only need to log in to one system to access all related systems without repeatedly entering their username and password. While this mechanism facilitates user operations, it also presents significant security vulnerabilities.
[0003] Currently, many systems rely solely on the authentication factor provided by the first system during single sign-on (SSO) for subsequent system access verification. While this reduces the complexity of user operations, it significantly reduces security. Specifically, all cross-system requests use only the authentication factor generated by the first system, failing to individually encrypt or securely verify identity authentication between different systems. This makes it easy for authentication factors to be leaked or forged, failing to adequately guarantee the legitimacy of user access and the security of the system.
[0004] Furthermore, most existing systems on the market only employ traditional encryption and decryption methods to protect identity authentication data, lacking a reliable storage and traceability mechanism for core authentication factor data. Specifically, although these systems provide some protection for authentication data through encryption and decryption, they fail to upload the core authentication factor data to the blockchain, resulting in a lack of immutable and traceable records, thus failing to effectively guarantee the integrity and reliability of the authentication data.
[0005] In summary, current single sign-on mechanisms suffer from serious security issues in cross-system identity authentication: on the one hand, over-reliance on the authentication factor of the first system leads to lower security in other systems; on the other hand, the lack of blockchain technology to protect authentication factor data and its on-chain operation makes the data susceptible to tampering, failing to ensure the authenticity and integrity of authentication data. Therefore, existing technologies suffer from a lack of multi-layered security guarantees for inter-system identity authentication, vulnerability to tampering of authentication data, and an inability to achieve data reliability and traceability. Summary of the Invention
[0006] The main objective of this application is to provide an authentication and data storage method and a data storage device for cross-system login based on blockchain, so as to at least solve the problems of lack of multi-layered security protection for inter-system identity authentication, easy tampering of authentication data, and inability to achieve data reliability and traceability in the prior art.
[0007] To achieve the above objectives, according to one aspect of this application, an authentication method for cross-system login based on blockchain is provided. The blockchain includes a user node, a first system node, and a second system node. The method includes: responding to a system redirection request initiated by the user node; extracting a first authentication factor based on the system redirection request; the system redirection request being used to request redirection to the second system node when the user node is logged into the first system node; the first authentication factor being an authentication factor encrypted and generated by the first system node based on authentication information and user information; sending a first decryption request to the blockchain based on the first authentication factor; the first decryption request being used to instruct the blockchain to decrypt and match the first authentication factor, and, if the decryption and matching are successful, sending the user information to the second system node; responding to the user information, encrypting it using blockchain technology to generate a second authentication factor, and uploading the second authentication factor to the blockchain; and authenticating all messages based on the first authentication factor and the second authentication factor during the interaction between the second system node and the blockchain.
[0008] Optionally, in response to the user information, encryption is performed using blockchain technology to generate a second authentication factor, including: combining the user information and the authentication information of the second system node to obtain a data packet to be encrypted, wherein the authentication information includes one or more of the unique identifier of the second system node, a timestamp, and a random number; in response to the user information, encryption is performed using blockchain technology to generate a second authentication factor, and the second authentication factor is uploaded to the blockchain.
[0009] Optionally, after encrypting the user information using blockchain technology, generating a second authentication factor, and uploading the second authentication factor to the blockchain, the method further includes: embedding the second authentication factor into a local token to obtain a first authentication token; and issuing the first authentication token to the user node so that the user node incorporates the second authentication factor into all operations of the second system node.
[0010] Optionally, during the interaction between the second system node and the blockchain, all messages are authenticated based on the first authentication factor and the second authentication factor, including: when the second system node sends a message to the blockchain, generating a data packet to be sent according to operation instructions and related data; appending the first authentication factor and the second authentication factor to the data packet to be sent to obtain a message to be sent; sending the message to be sent to the blockchain, whereby the blockchain uses a private key in an asymmetric algorithm to decrypt the received message to be sent to obtain the second authentication factor; when the second authentication factor is obtained, using an asymmetric decryption algorithm to decrypt the first authentication factor to obtain the first authentication factor; and matching the authentication information stored in the blockchain based on the first authentication factor and the second authentication factor to complete the authentication process.
[0011] Optionally, during the interaction between the second system node and the blockchain, all messages are authenticated based on the first authentication factor and the second authentication factor, including: when the blockchain sends a message to the second system node, receiving the message to be decrypted sent by the blockchain, parsing the message to be decrypted to obtain the operation instruction, the first authentication factor, and the second authentication factor; obtaining the private key in the asymmetric algorithm, decrypting the first authentication factor, and decrypting the second authentication factor after the first authentication factor has been decrypted; matching based on the first authentication factor and the second authentication factor, and executing the operation instruction if the matching is successful.
[0012] According to another aspect of this application, a data storage method for cross-system login based on blockchain is provided. The blockchain includes user nodes, a first system node, and a second system node. The method includes: responding to login verification information uploaded by the first system node, matching the login verification information with user information stored in the blockchain, and generating a matching result that is sent to the first system node; responding to a first authentication factor uploaded by the first system node and the user information, storing the first authentication factor, and updating the user information stored in the blockchain according to the user information uploaded by the first system node; responding to a first decryption request uploaded by the second system node, matching the first authentication factor carried in the first decryption request with the first authentication factor stored in the blockchain, and if the matching is successful, sending the user information stored in the blockchain to the second system node; responding to a second authentication factor uploaded by the second system node and the user information, storing the second authentication factor, and updating the user information stored in the blockchain according to the user information uploaded by the second system node.
[0013] Optionally, in response to the login verification information uploaded by the first system node, a matching process is performed based on the login verification information and the user information stored in the blockchain, and a matching result is generated and sent to the first system node. This includes: decrypting the login verification information using a private key in asymmetric encryption technology, and analyzing the decrypted login verification information to obtain first user information; comparing the first user information with second user information; if the second user information matches the first user information, determining the matching result as a successful match, and the second user information being the user information stored in the blockchain; if the second user information does not match the first user information, determining the matching result as a failed match; and sending the matching result to the first system node.
[0014] Optionally, in response to a first decryption request uploaded by the second system node, matching the first authentication factor carried in the first decryption request with the first authentication factor stored in the blockchain, and if the match is successful, sending the user information stored in the blockchain to the second system node, includes: parsing the first decryption request, extracting the first authentication factor carried in the first decryption request to obtain a first target factor; comparing the first target factor with a second target factor, and if the first target factor and the second target factor are consistent, determining that the matching result is a successful match, and the second target factor is the first authentication factor stored in the blockchain; if the first target factor and the second target factor are inconsistent, determining that the matching result is a failed match; and if the matching result is a successful match, sending the user information stored in the blockchain to the second system node.
[0015] According to another aspect of this application, an authentication device for cross-system login based on blockchain is provided, wherein the blockchain includes user nodes, a first system node, and a second system node, and the device includes:
[0016] A first acquisition unit is configured to, in response to a system redirection request initiated by the user node, extract a first authentication factor based on the system redirection request. The system redirection request is used to request redirection to a second system node when the user node is logged into the first system node. The first authentication factor is an authentication factor encrypted and generated by the first system node based on authentication information and user information. A first sending unit is configured to send a first decryption request to the blockchain based on the first authentication factor. The first decryption request instructs the blockchain to decrypt and match the first authentication factor, and if the decryption match is successful, to send the user information to the second system node. A first processing unit is configured to, in response to the user information, encrypt it using blockchain technology, generate a second authentication factor, and upload the second authentication factor to the blockchain. A control unit is configured to, during interaction with the blockchain, authenticate all messages based on the first authentication factor and the second authentication factor.
[0017] According to another aspect of this application, a data storage device for cross-system login based on blockchain is provided, wherein the blockchain includes user nodes, a first system node, and a second system node, and the device includes:
[0018] The second sending unit is used to respond to the login verification information uploaded by the first system node, match the login verification information with the user information stored in the blockchain, and generate a matching result to send to the first system node.
[0019] The first storage unit is configured to, in response to the first authentication factor and the user information uploaded by the first system node, store the first authentication factor and update the user information stored in the blockchain according to the user information uploaded by the first system node.
[0020] The third sending unit is used to respond to the first decryption request uploaded by the second system node, match the first authentication factor carried in the first decryption request with the first authentication factor stored in the blockchain, and if the match is successful, send the user information stored in the blockchain to the second system node.
[0021] The second storage unit is used to store the second authentication factor in response to the second authentication factor and the user information uploaded by the second system node, and to update the user information stored in the blockchain according to the user information uploaded by the second system node.
[0022] By employing blockchain technology, user information and authentication factors are encrypted and stored in the blockchain. A dual matching process between system redirection requests and authentication factors ensures that all data transmitted across systems undergoes rigorous identity verification and security. By extracting the first authentication factor and sending a decryption request, identity matching based on a valid authentication factor is ensured during login to the second system node, thus preventing unauthorized user intrusion. Furthermore, through blockchain interaction between cross-system nodes, all operation messages undergo detailed authentication between the first and second authentication factors, ensuring high security and consistency during cross-system data exchange. Regarding data storage, storing user information in the blockchain and automatically updating and matching user authentication factors across system nodes achieves decentralized information management, avoiding single points of failure and data tampering issues inherent in traditional storage methods. All data related to user information and authentication factors is encrypted and decrypted for verification, ensuring data consistency and security and enhancing the system's resistance to attacks. Ultimately, through this cross-system authentication mechanism, users can securely and seamlessly log in across multiple systems, improving user experience while also ensuring system security and stability. Therefore, the technical solution of this application effectively solves the problems in the prior art, such as the lack of multi-layered security for identity authentication between systems, the susceptibility of authentication data to tampering, and the inability to achieve data reliability and traceability. It achieves a more secure, efficient and reliable cross-system login solution through blockchain technology, which can meet the high requirements for authentication and data storage in a multi-system environment. Attached Figure Description
[0023] Figure 1 A hardware structure block diagram of a mobile terminal for authentication and data storage based on blockchain cross-system login, provided in an embodiment of this application, is shown.
[0024] Figure 2 A flowchart illustrating an authentication method for cross-system login based on blockchain, according to an embodiment of this application, is shown.
[0025] Figure 3 A schematic flowchart of a data storage method for cross-system login based on blockchain, according to an embodiment of this application, is shown.
[0026] Figure 4 A structural block diagram of an authentication device for cross-system login based on blockchain, according to an embodiment of this application, is shown.
[0027] Figure 5 A structural block diagram of a data storage device for cross-system login based on blockchain, according to an embodiment of this application, is shown.
[0028] The above figures include the following reference numerals:
[0029] 102. Processor; 104. Memory; 106. Transmission device; 108. Input / output device. Detailed Implementation
[0030] It should be noted that, unless otherwise specified, the embodiments and features described in this application can be combined with each other. This application will now be described in detail with reference to the accompanying drawings and embodiments.
[0031] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present application, and not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative effort should fall within the scope of protection of the present application.
[0032] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate for the embodiments of this application described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0033] For ease of description, the following explains some of the nouns or terms used in the embodiments of this application:
[0034] Blockchain: Blockchain technology is a new distributed infrastructure and computing paradigm that uses a block-chain data structure to verify and store data, uses distributed node consensus algorithms to generate and update data, uses cryptography to ensure the security of data transmission and access, and uses smart contracts composed of automated script code to program and manipulate data.
[0035] Consortium blockchains: Only stakeholders or pre-agreed specific organizational clients can use them. Nodes must undergo identity verification and authorization before joining the blockchain network. Nodes within a consortium blockchain have different roles, participating in ledger maintenance as needed according to the blockchain's transaction submission methods and consensus mechanisms. They exhibit relatively weak decentralized characteristics.
[0036] Consensus Verification: The consensus mechanism is the method by which all accounting nodes in a blockchain determine the validity of a record. This serves as both a means of verification and a means of preventing tampering. The consensus mechanism features "majority rule" and "equality among all nodes." "Majority rule" does not solely refer to the number of nodes; it can also refer to computing power, shareholding, or other comparable computer characteristics. "Equality among all nodes" means that when a node meets the conditions, all nodes have the right to propose a consensus result first, which can then be directly accepted by other nodes and potentially become the final consensus result.
[0037] Decentralization: Blockchain technology does not rely on additional third-party management institutions or hardware facilities, and has no central control. Besides the self-contained blockchain itself, through distributed computing and storage, each node achieves self-verification, transmission, and management of information. Decentralization is the most prominent and essential characteristic of blockchain.
[0038] Asymmetric encryption algorithms: Unlike symmetric encryption algorithms, asymmetric encryption algorithms require two keys: a public key and a private key. The public and private keys are a pair; if data is encrypted using the public key, it can only be decrypted using the corresponding private key; conversely, if data is encrypted using the private key, it can only be decrypted using the corresponding public key. Because encryption and decryption use two different keys, this type of algorithm is called an asymmetric encryption algorithm.
[0039] As described in the background section, existing technologies suffer from problems such as a lack of multi-layered security for inter-system identity authentication, susceptibility to tampering of authentication data, and inability to achieve data reliability and traceability. To address these issues, embodiments of this application provide an authentication and data storage method for cross-system login based on blockchain, an authentication and data storage device for cross-system login based on blockchain, a computer-readable storage medium, a processor, and an electronic device.
[0040] The technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention.
[0041] The methods and embodiments provided in this application can be executed on a mobile terminal, computer terminal, or similar computing device. Taking running on a mobile terminal as an example, Figure 1 This is a hardware structure block diagram of a mobile terminal based on a blockchain-based cross-system login authentication and data storage method, according to an embodiment of the present invention. Figure 1 As shown, a mobile terminal may include one or more ( Figure 1Only one is shown in the diagram. A processor 102 (which may include, but is not limited to, a microprocessor MCU or a programmable logic device FPGA, etc.) and a memory 104 for storing data are also shown. The mobile terminal may further include a transmission device 106 for communication functions and an input / output device 108. Those skilled in the art will understand that... Figure 1 The structure shown is for illustrative purposes only and does not limit the structure of the mobile terminal described above. For example, the mobile terminal may also include components that are more... Figure 1 The more or fewer components shown, or having the same Figure 1 The different configurations shown.
[0042] The memory 104 can be used to store computer programs, such as application software programs and modules, like the computer program corresponding to the device information display method in this embodiment of the invention. The processor 102 executes various functional applications and data processing by running the computer program stored in the memory 104, thereby implementing the above-described method. The memory 104 may include high-speed random access memory and non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory 104 may further include memory remotely located relative to the processor 102, and these remote memories can be connected to the mobile terminal via a network. Examples of the aforementioned networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof. The transmission device 106 is used to receive or send data via a network. Specific examples of the aforementioned networks may include wireless networks provided by the mobile terminal's communication provider. In one example, the transmission device 106 includes a network interface controller (NIC), which can be connected to other network devices via a base station to communicate with the Internet. In one example, the transmission device 106 may be a radio frequency (RF) module, which is used to communicate with the Internet wirelessly.
[0043] This embodiment provides an authentication and data storage method for blockchain-based cross-system login that runs on a mobile terminal, computer terminal, or similar computing device. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Also, although the logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.
[0044] Figure 2 This is a flowchart of a blockchain-based cross-system login authentication method according to an embodiment of this application. Figure 2As shown, the blockchain includes user nodes, first system nodes, and second system nodes. The method includes the following steps:
[0045] Step S201: In response to the system redirection request initiated by the user node, extract the first authentication factor according to the system redirection request. The system redirection request is used to request redirection to the second system node when the user node is logged into the first system node. The first authentication factor is an authentication factor generated by the first system node based on authentication information and user information.
[0046] Specifically, when a user node initiates a cross-system jump request, the request information is retrieved from the user node, and a first authentication factor for authentication is extracted. This authentication factor is generated by the first system node during user login, based on encrypted user information (such as username, password, biometrics, etc.) and authentication information (such as session information, tokens, etc.). Encryption ensures that the first authentication factor is not leaked or tampered with during transmission. Extracting and encrypting the first authentication factor effectively prevents malicious tampering or theft of authentication information, while reducing the exposure of sensitive data transmitted between systems, thus enhancing the security of cross-system jumps.
[0047] Step S202: Send a first decryption request to the blockchain based on the first authentication factor. The first decryption request is used to instruct the blockchain to decrypt and match the first authentication factor. If the decryption and matching are successful, send the user information to the second system node.
[0048] Specifically, after a user node initiates a redirection request carrying the first authentication factor, the first system node sends a first decryption request to the blockchain, requesting the blockchain to verify and decrypt the authentication factor. The blockchain performs a decryption matching operation based on pre-stored public and private keys. If the decryption match is successful, it indicates that the user's identity has been verified, and the blockchain forwards the user information to the second system node for further authentication and authorization. By decrypting and verifying the authentication factor, the blockchain ensures data consistency and identity legitimacy during cross-system redirection, avoiding the risks of identity forgery or unauthorized access. The decryption matching process is supported by blockchain technology, increasing trust and system security.
[0049] In step S203, in response to the user information, the information is encrypted using blockchain technology, a second authentication factor is generated, and the second authentication factor is uploaded to the blockchain.
[0050] Specifically, when the blockchain receives user information from a second system node, the system encrypts the information and generates a second authentication factor. This second authentication factor is generated based on encrypted user authentication data and uploaded to the blockchain for subsequent authentication. By encrypting user information, the security of authentication data during transmission is ensured.
[0051] Step S204: During the interaction between the second system node and the blockchain, all messages are authenticated based on the first authentication factor and the second authentication factor.
[0052] Specifically, when the second system node interacts with the blockchain, the system authenticates messages based on a first authentication factor and a second authentication factor already uploaded to the blockchain. By comparing the matching of these two authentication factors, the legitimacy of the user's identity is ensured. If the match is successful, the user is allowed to access the second system; otherwise, their access request is denied. Authentication of messages based on two authentication factors further enhances system security. This dual authentication factor mechanism effectively prevents malicious attacks, ensuring that only verified legitimate users can access cross-system resources, greatly improving the system's protection capabilities.
[0053] Therefore, the embodiments of this application provide an authentication method for cross-system login based on blockchain. By leveraging the decentralized, immutable, and traceable characteristics of blockchain technology, the security of inter-system identity authentication is significantly improved. First and second authentication factors are generated encryptively and uploaded to the blockchain, ensuring the integrity and security of the authentication data. The blockchain verifies the user's identity by decryption and matching, avoiding the problem of authentication factors being tampered with or forged. Throughout the authentication process, dual authentication factors are used to strictly verify the identity of messages, preventing unauthorized access and thus ensuring the legitimacy of the user and the security of cross-system operations.
[0054] As one possible implementation, in response to user information, encryption is performed using blockchain technology to generate a second authentication factor, including the following steps:
[0055] Step S301: Combine the user information and the authentication information of the second system node to obtain the data packet to be encrypted. The authentication information includes one or more of the unique identifier of the second system node, timestamp, and random number.
[0056] Specifically, user information is combined with the authentication information of the second system node to form the data packet to be encrypted. The authentication information of the second system node can include the following aspects: Unique identifier: A unique string or identifier used to identify the second system node itself, helping to ensure that the authentication process is specific to a particular system. Timestamp: Used to identify the specific time of the authentication request, preventing replay attacks or expired authentication information. Random number: Used to increase the randomness in the encryption process, ensuring that each generated authentication factor is unique, even if the user information is the same, different authentication factors can be generated. By combining these information, a sufficiently complex and secure data packet can be generated for subsequent encryption operations. Combining multiple authentication information (such as unique identifier, timestamp, and random number) to generate the data packet to be encrypted effectively increases the complexity and security of the authentication factor. In this way, even if an attacker can obtain some authentication information, it is difficult to recover a valid authentication factor, thereby effectively preventing identity forgery and replay attacks, and further enhancing the system's resistance to attacks.
[0057] In step S302, in response to the user information, the information is encrypted using blockchain technology, a second authentication factor is generated, and the second authentication factor is uploaded to the blockchain.
[0058] Specifically, after generating the data packet to be encrypted, it is encrypted using blockchain technology. Specifically, an encryption algorithm (such as symmetric or asymmetric encryption) is used to encrypt the data packet, and a second authentication factor is generated based on the encryption result. The encryption process is implemented using blockchain technology, which means that the encryption operation not only ensures the immutability of the data during encryption but also ensures that the generated authentication factor is secure and unforgeable. Finally, the generated second authentication factor is uploaded to the blockchain and stored in the blockchain's immutable distributed ledger for use in subsequent authentication processes. By using blockchain technology for encryption, the security of the second authentication factor during its generation and storage is ensured. The decentralized nature of blockchain ensures that encrypted data cannot be tampered with, and the authentication factor uploaded to the blockchain can be effectively traced and verified, greatly enhancing the security of identity authentication.
[0059] Therefore, this embodiment of the application generates a data packet to be encrypted by combining user information and authentication information of the second system node, then encrypts it using blockchain technology to generate a second authentication factor, and uploads it to the blockchain for storage. By combining multiple authentication information (unique identifier, timestamp, and random number, etc.), the generated authentication factor is more complex and secure, preventing forgery and tampering of the authentication factor. Encryption and uploading using blockchain technology ensures the immutability and traceability of the data, greatly enhancing the security of the cross-system login process. The entire authentication process is supported by a decentralized blockchain, avoiding the security vulnerabilities of traditional centralized systems, making the entire system more secure and reliable.
[0060] As one possible implementation, after responding to user information, encrypting it using blockchain technology, generating a second authentication factor, and uploading the second authentication factor to the blockchain, the method further includes the following steps:
[0061] Step S401: Embed the second authentication factor into the local token to obtain the first authentication token.
[0062] Specifically, the second authentication factor is embedded into the local token to generate the first authentication token. The local token is an identifier carrying authentication information; after embedding the authentication factor, it can carry that factor for authentication in subsequent operations. The first authentication token typically includes additional information such as a timestamp and session information to ensure the token's validity and uniqueness, and to prevent replay attacks or forgery. Embedding the second authentication factor into the local token makes carrying the authentication factor more convenient and efficient.
[0063] Step S402: The first authentication token is issued to the user node so that the user node can add the second authentication factor to all operations of the second system node.
[0064] Specifically, after generating and embedding the second authentication factor into the first authentication token, the token is issued to the user node. The user node uses this token for authentication during interactions with the second system node. Specifically, the user node includes the first authentication token in its requests; the second authentication factor contained within this token will be used by the second system node for authentication and authorization. By issuing the first authentication token to the user node, the second authentication factor can be automatically added to all operations with the second system node, making the authentication process more automated and efficient. The need for complex authentication factor generation and verification each time is eliminated, greatly improving the convenience of cross-system operations. Furthermore, the use of the first authentication token reduces repetitive input of user information, improving user experience and enhancing system security.
[0065] Therefore, this application embodiment improves the convenience and security of identity verification by embedding the second authentication factor into the local token to generate the first authentication token and then issuing it to the user node. First, the generated first authentication token carries the encrypted second authentication factor, making the authentication process in cross-system operations more efficient and avoiding the tedious process of regenerating the authentication factor and performing verification each time. Second, the first authentication token automatically adds the authentication factor when the user node performs all operations with the second system node, effectively simplifying the authentication process and improving the automation level of the operation. Finally, using the token for identity verification avoids the frequent transmission of sensitive user information, thereby improving the system's security and protection capabilities. This method is suitable for scenarios requiring secure and efficient identity authentication between multiple systems, improving the convenience, security, and user experience of cross-system operations.
[0066] As one possible implementation, during the interaction between the second system node and the blockchain, all messages are authenticated based on the first authentication factor and the second authentication factor, including the following steps:
[0067] Step S501: When the second system node sends a message to the blockchain, a data packet to be sent is generated according to the operation instructions and related data.
[0068] Specifically, when a second system node prepares to send a message to the blockchain, it first generates a data packet to be sent based on the executed operation instructions and related data. Operation instructions may include user actions, requested resources, target system information, etc., while related data includes user information, session information, etc. This information forms the data packet to be sent, used for subsequent verification and processing. The process of generating the data packet to be sent ensures that the content and requests of each message are valid and purposeful, and all information is preprocessed and organized, providing a solid foundation for subsequent identity verification and data security.
[0069] Step S502: Append the first authentication factor and the second authentication factor to the data packet to be sent to obtain the message to be sent;
[0070] Specifically, in the data packet to be sent, a first authentication factor and a second authentication factor are appended as key authentication data. These two authentication factors contain the user's identity information and authentication data, ensuring that the data packet carries complete authentication information during transmission. Appending the first and second authentication factors to the data packet ensures the security of the authentication process during data transmission. As part of the message, the authentication factors can be verified promptly at the receiver, guaranteeing the legitimacy and integrity of data transmission. The step of appending authentication factors adds multiple layers of verification, thereby reducing the risk of tampering or forgery.
[0071] Step S503: The message to be sent is sent to the blockchain. The blockchain is used to decrypt the received message to be sent using the private key in the asymmetric algorithm to obtain the second authentication factor. With the second authentication factor obtained, the first authentication factor is decrypted using the asymmetric decryption algorithm to obtain the first authentication factor. The authentication information stored in the blockchain based on the first authentication factor and the second authentication factor is matched to complete the authentication process.
[0072] Specifically, the message to be sent contains a first authentication factor and a second authentication factor. After being sent to the blockchain, the blockchain uses the private key in an asymmetric algorithm to decrypt the received message, first obtaining the second authentication factor. Subsequently, based on the decryption result of the second authentication factor, the blockchain again uses an asymmetric decryption algorithm to decrypt the first authentication factor, finally obtaining the value of that factor. The blockchain will complete the final identity authentication process by matching the decrypted first and second authentication factors with the authentication information stored on the blockchain. The use of asymmetric encryption and decryption technology ensures the security and privacy of the message during transmission. Since asymmetric encryption requires a private key for decryption, only the blockchain holding the private key can correctly decrypt the message, effectively avoiding the risk of man-in-the-middle attacks or data tampering. In addition, the matching method based on the decrypted authentication factor improves the accuracy and security of authentication, ensuring reliable verification of user identity and preventing identity forgery and unauthorized access.
[0073] Therefore, this embodiment of the application significantly improves the security of cross-system data transmission by authenticating all messages based on a first authentication factor and a second authentication factor during the interaction between the second system node and the blockchain. Based on the generated data packet to be sent, the first and second authentication factors are appended to the message, and the message is decrypted and verified using an asymmetric encryption algorithm, ensuring the reliability and integrity of authentication information during data transmission. This method effectively prevents security threats such as data tampering, identity forgery, and man-in-the-middle attacks, ensuring the legitimacy of inter-system communication and data security. This authentication mechanism ensures that each message in cross-system operations undergoes strict identity verification, improving system security and making it suitable for cross-domain authentication and data exchange between multiple systems.
[0074] As one possible implementation, during the interaction between the second system node and the blockchain, all messages are authenticated based on the first authentication factor and the second authentication factor, including the following steps:
[0075] Step S601: When the blockchain sends a message to the second system node, receive the message to be decrypted sent by the blockchain, and parse the message to be decrypted to obtain the operation instruction, the first authentication factor and the second authentication factor.
[0076] Specifically, the second system node first receives messages from the blockchain. Upon receiving the message, the system parses it, extracting the operation instructions and authentication factors (i.e., the first authentication factor and the second authentication factor). The operation instructions may contain specific operations or data requests to be performed, while the first and second authentication factors are used to verify the legitimacy of the requester's identity. Parsing the message to be decrypted ensures that the messages sent by the blockchain contain all necessary information, especially the authentication factors for identity verification. This process ensures data integrity and the accuracy of authentication information, laying the foundation for subsequent decryption and authentication operations.
[0077] Step S602: Obtain the private key in the asymmetric algorithm, decrypt the first authentication factor, and decrypt the second authentication factor after the first authentication factor has been decrypted.
[0078] Specifically, after the second system node receives the message containing the authentication factor, the system uses the private key from the asymmetric encryption algorithm to decrypt the first authentication factor. After successfully decrypting the first authentication factor, the system continues to use the private key to decrypt the second authentication factor. This process ensures that only legitimate systems can decrypt the authentication factors and complete identity verification. By using an asymmetric algorithm to decrypt the authentication factors, the system ensures that only legitimate nodes holding the private key can decrypt the data, which greatly enhances system security and prevents identity information from being maliciously tampered with or forged during transmission. Asymmetric encryption technology, through the cooperation of public and private key pairs, makes the identity verification process more secure and reliable, and effectively avoids man-in-the-middle attacks.
[0079] Step S603: Match based on the first authentication factor and the second authentication factor, and execute the operation instruction if the match is successful.
[0080] Specifically, after successful decryption, the system matches the decrypted first and second authentication factors with the authentication information stored in the system. If the match is successful, it proves the sender's identity is legitimate, and the system executes the operation instructions contained in the message (e.g., querying or modifying data). If the match fails, the system refuses to execute the operation and records the security event. By matching authentication factors, the system can confirm the legitimacy of the identity information, ensuring that only authenticated users can perform operations. This step effectively prevents unauthorized user operations and increases the system's protection level. The success or failure of the matching process directly affects whether the operation is executed; therefore, its correctness is directly related to the system's security and data reliability.
[0081] Therefore, this embodiment of the application significantly enhances the security of cross-system operations by receiving and parsing the message to be decrypted from the blockchain at the second system node, and performing identity verification and operation instruction execution based on the decrypted first and second authentication factors. First, the message parsing process ensures that all necessary authentication information and operation instructions are accurately extracted, providing complete data for subsequent identity verification. Second, the use of an asymmetric encryption algorithm to decrypt the authentication factors ensures that only legitimate system nodes can decrypt the data, effectively preventing malicious tampering and forgery. Finally, by matching the decrypted authentication factors with the stored authentication information, the system ensures that only legitimate requests are executed, thereby effectively preventing unauthorized operations. The entire process not only improves the accuracy and security of identity verification but also makes cross-system operations more efficient and reliable, preventing potential security risks.
[0082] Figure 3 This is a flowchart of a data storage method for cross-system login based on blockchain, according to an embodiment of this application. Figure 3 As shown, the blockchain includes user nodes, first system nodes, and second system nodes. The method includes the following steps:
[0083] Step S701: In response to the login verification information uploaded by the first system node, match the login verification information with the user information stored in the blockchain, and generate a matching result to be sent to the first system node;
[0084] Specifically, when a user attempts to log in to the first system, the first system node uploads login verification information (such as username, password, authentication factor, etc.), which is then matched against user information stored on the blockchain. Upon successful matching, the system generates a matching result and returns it to the first system node, indicating whether the user's authentication has passed or failed. This ensures the consistency and security of the authentication process across multiple systems. Matching user information stored on the blockchain ensures consistency of user identity information across different systems, preventing tampering and forgery. The generation and distribution of matching results guarantee the legality and accuracy of the user login operation.
[0085] Step S702: In response to the first authentication factor and user information uploaded by the first system node, the first authentication factor is stored, and the user information stored in the blockchain is updated according to the user information uploaded by the first system node.
[0086] Specifically, when the first system node uploads the first authentication factor, this factor is stored in the blockchain and serves as core data for user authentication. Simultaneously, the first system node also uploads relevant user information (such as personal data and account status), which is used to update the user information already stored on the blockchain to keep user data up-to-date. By storing and updating the first authentication factor and user information, the blockchain ensures that users have consistent and up-to-date authentication information across multiple systems. This not only improves the efficiency of data synchronization between systems but also enhances data security and reliability through decentralized storage, preventing data loss and tampering.
[0087] Step S703: In response to the first decryption request uploaded by the second system node, the first authentication factor carried in the first decryption request is matched with the first authentication factor stored in the blockchain, and if the match is successful, the user information stored in the blockchain is sent to the second system node.
[0088] Specifically, when the second system node receives the first decryption request from a user, the system matches the first authentication factor carried in the first decryption request with the authentication factors stored on the blockchain. If the match is successful, the system retrieves the user's relevant information from the blockchain and sends this user information to the second system node for further authentication or authorization. By matching the decryption request with the first authentication factor stored on the blockchain, the system ensures that the second system node can verify the user's legitimacy using accurate authentication information. This method improves the reliability and security of cross-system authentication and prevents the tampering and leakage of identity information.
[0089] Step S704: In response to the second authentication factor and user information uploaded by the second system node, the second authentication factor is stored, and the user information stored in the blockchain is updated according to the user information uploaded by the second system node.
[0090] Specifically, after the second system node successfully verifies the user's identity, it uploads a second authentication factor and related user information. The system stores the second authentication factor in the blockchain and updates the user data in the blockchain based on the user information uploaded by the second system node to ensure the consistency and real-time nature of the user's authentication information and personal profile across all systems.
[0091] Therefore, the embodiments of this application provide a data storage method for cross-system login based on blockchain. By authenticating user information stored on the blockchain between the first and second system nodes, the security and consistency of user information are ensured. After each system node uploads authentication factors and user information, the blockchain can update and store the latest user data in real time, ensuring data validity and consistency. The decentralized storage method of blockchain not only improves data security but also reduces the risk of data tampering and loss. Furthermore, this method enables efficient data synchronization between multiple systems, allowing users to have consistent authentication information across different systems, improving interoperability and security, and is suitable for cross-platform authentication and data storage needs in multi-system environments.
[0092] As one possible implementation, in response to the login verification information uploaded by the first system node, a match is made between the login verification information and the user information stored on the blockchain, and a matching result is generated and sent to the first system node, including the following steps:
[0093] Step S801: Decrypt the login verification information using the private key in asymmetric encryption technology, and analyze the decrypted login verification information to obtain the first user information;
[0094] Specifically, after the first system node uploads the user's login verification information, the system first decrypts the information using a private key in asymmetric encryption technology. The decrypted login verification information contains the user's basic authentication information (such as username, password, device information, etc.). The system analyzes the decrypted information and extracts the first user information, which serves as the basis for matching with the user information stored on the blockchain. Decrypting the login verification information using a private key in asymmetric encryption technology ensures the confidentiality and integrity of the information during transmission. The decrypted user information effectively prevents data tampering or leakage, ensuring the security and credibility of identity verification. Furthermore, by analyzing and extracting the first user information, accurate data is provided for the subsequent matching process, enhancing the system's identity verification capabilities.
[0095] Step S802: Based on the comparison between the first user information and the second user information, if the second user information is consistent with the first user information, the matching result is determined to be a successful match, and the second user information is the user information stored in the blockchain;
[0096] Specifically, the decrypted first user information is compared with the second user information stored in the blockchain. The second user information is the user authentication information already stored on the blockchain, including the user's personal information, account status, etc. If the first user information matches the second user information, it indicates that the user's identity verification is successful, the matching result is "match passed," and the second user information is confirmed as valid user information. By comparing user information, the legitimacy of the user's identity can be effectively confirmed, ensuring that only legitimate users can pass the identity verification. The comparison process avoids the forgery or tampering of the identity of unauthorized users, improving the accuracy and security of identity verification.
[0097] Step S803: If the second user information is inconsistent with the first user information, determine the matching result as a failed match.
[0098] Specifically, if the first user information does not match the second user information stored on the blockchain, user authentication is considered to have failed, and the matching result is "match failed." In this case, the user information will not be sent back to the first system node, and the user will not be allowed to continue logging in or performing other operations. By detecting inconsistent user information, it is possible to prevent unauthorized users from logging in by forging identity information. The "match failed" result allows the system to reject illegal requests, thereby effectively protecting user data and system security, and preventing identity fraud and abuse.
[0099] Step S804: Send the matching result to the first system node.
[0100] Specifically, regardless of whether the match is successful or unsuccessful, the system will send the final matching result (i.e., "successful match" or "unsuccessful match") back to the first system node. The first system node then decides whether to allow the user to log in or prompts the user for further authentication based on this result. By promptly sending the matching result to the first system node, the system ensures that the first system node can respond correctly. If the match is successful, the system allows the user to continue logging in; if the match is unsuccessful, the user cannot log in. This process improves the system's response efficiency, ensures a simple and fast authentication process, and reduces unnecessary waiting time.
[0101] Therefore, this application's embodiments effectively improve the security and efficiency of cross-system authentication by decrypting login verification information and comparing and matching user information. First, asymmetric encryption technology is used to decrypt the login verification information, ensuring data security during transmission and accurately extracting the first user information. Second, by comparing the first user information with the second user information stored in the blockchain, it is ensured that only legitimate and consistent user information can pass authentication, effectively preventing the forgery or tampering of identity information. When the match fails, the system can automatically reject access requests from unauthorized users, ensuring system security. Finally, the matching results are promptly fed back to the first system node, ensuring a smooth and secure user login process.
[0102] As one possible implementation, in response to a first decryption request uploaded by a second system node, the system matches the first authentication factor carried in the first decryption request with the first authentication factor stored in the blockchain. If the match is successful, the user information stored in the blockchain is sent to the second system node, including the following steps:
[0103] Step S901: Parse the first decryption request, extract the first authentication factor carried in the first decryption request, and obtain the first target factor;
[0104] Specifically, when the second system node uploads the first decryption request, the system parses the request and extracts the first authentication factor carried within it. This factor contains information required for user authentication, typically an authentication identifier generated through an encryption algorithm.
[0105] Step S902: Based on the comparison between the first target factor and the second target factor, if the first target factor and the second target factor are consistent, the matching result is determined to be a successful match, and the second target factor is the first authentication factor stored in the blockchain.
[0106] Specifically, after obtaining the first target factor, the system compares it with a second target factor stored in the blockchain. The second target factor is authentication data generated from the first authentication factor and stored on the blockchain. If the first and second target factors match, identity verification is successful, and the system determines the matching result as "match passed." At this point, the second target factor becomes the first authentication factor stored in the blockchain. After successful verification, the system allows further operations. By comparing authentication factors, the system can accurately verify the legitimacy of the user's identity. This comparison process effectively prevents identity forgery and data tampering, ensuring the authenticity and consistency of the user's identity. A successful match confirms that the system provides security guarantees, preventing unauthorized access.
[0107] Step S903: If the first target factor and the second target factor are inconsistent, the matching result is determined to be a failed match.
[0108] Specifically, if the first target factor does not match the second target factor stored on the blockchain, authentication fails. In this case, the matching result is determined as "match failed." This situation typically occurs when authentication information does not match or has been tampered with, and further operations are rejected. This ensures that only legitimate users can pass authentication, preventing unauthorized users from forging or tampering with authentication information to enter the system. By accurately identifying matching failures, the system can promptly prevent unauthorized access, effectively improving system security.
[0109] Step S904: If the matching result is successful, the user information stored in the blockchain is sent to the second system node.
[0110] Specifically, when the matching result is "match successful," the system sends the user information stored on the blockchain to the second system node. This user information includes the user's profile, account status, etc., which will be used for subsequent operation verification, access permission allocation, etc. Once the authentication factor matches successfully, the system can promptly transmit the complete user information to the second system node, allowing the user to successfully access the system. By sending information to the second system node, the consistency and transparency of user data across systems are ensured. This process improves the user experience, making cross-system access smoother and more secure.
[0111] Therefore, this embodiment of the application ensures the security and reliability of identity verification by parsing the first decryption request uploaded by the second system node and comparing the extracted first authentication factor with the authentication factor stored in the blockchain. Through a precise matching process, the system can accurately verify the user's identity and prevent unauthorized users from obtaining access by forging or tampering with authentication information. The system will only allow the user's information to be sent when the first target factor matches the second target factor stored in the blockchain, ensuring data security and consistency. The entire process improves the accuracy of identity authentication and the system's security capabilities, and enhances cross-system collaboration and user experience.
[0112] It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions, and although a logical order is shown in the flowchart, in some cases the steps shown or described may be executed in a different order than that shown here.
[0113] This application also provides an authentication and data storage device for cross-system login based on blockchain. It should be noted that this device can be used to execute the authentication and data storage method for cross-system login based on blockchain provided in this application. This device is used to implement the above embodiments and preferred embodiments; details already described will not be repeated. As used below, the term "module" can refer to a combination of software and / or hardware that performs a predetermined function. Although the device described in the following embodiments is preferably implemented in software, hardware implementation, or a combination of software and hardware, is also possible and contemplated.
[0114] The following describes the authentication and data storage device for cross-system login based on blockchain provided in the embodiments of this application.
[0115] Figure 4 This is a structural block diagram of an authentication device for cross-system login based on blockchain, according to an embodiment of this application. Figure 4 As shown, the device includes: a first acquisition unit 10, a first transmission unit 20, a first processing unit 30, and a control unit 40.
[0116] The first acquisition unit 10 is used to respond to a system jump request initiated by a user node, and extract a first authentication factor according to the system jump request. The system jump request is used to request a jump to a second system node when the user node logs into the first system node. The first authentication factor is an authentication factor generated by the first system node based on authentication information and user information.
[0117] The first sending unit 20 is used to send a first decryption request to the blockchain based on the first authentication factor. The first decryption request is used to instruct the blockchain to decrypt and match the first authentication factor, and if the decryption and matching are successful, to send user information to the second system node.
[0118] The first processing unit 30 is used to respond to user information, encrypt it using blockchain technology, generate a second authentication factor, and upload the second authentication factor to the blockchain.
[0119] The control unit 40 is used to authenticate all messages based on a first authentication factor and a second authentication factor during interaction with the blockchain.
[0120] As one possible implementation, the first processing unit includes:
[0121] The module combines user information and authentication information of the second system node to obtain the data packet to be encrypted. The authentication information includes one or more of the unique identifier of the second system node, timestamp, and random number.
[0122] The second authentication factor upload module is used to respond to user information, encrypt it using blockchain technology, generate a second authentication factor, and upload the second authentication factor to the blockchain.
[0123] As one possible implementation, blockchain-based cross-system login authentication devices also include:
[0124] The second authentication factor embedding and token generation unit is used to embed the second authentication factor into the local token to obtain the first authentication token.
[0125] The first authentication token issuing unit is used to issue the first authentication token to the user node so that the user node can add the second authentication factor to all operations of the second system node.
[0126] As one possible implementation, the control unit includes:
[0127] The data packet generation module is used to generate data packets to be sent based on operation instructions and related data when the second system node sends a message to the blockchain.
[0128] The message appending authentication factor module is used to append the first authentication factor and the second authentication factor to the data packet to be sent to obtain the message to be sent.
[0129] The message sending module is used to send the message to be sent to the blockchain. The blockchain uses the private key in the asymmetric algorithm to decrypt the received message to be sent to obtain the second authentication factor. With the second authentication factor obtained, the first authentication factor is decrypted using the asymmetric decryption algorithm to obtain the first authentication factor. The authentication information stored in the blockchain based on the first authentication factor and the second authentication factor is matched to complete the authentication process.
[0130] As one possible implementation, the control unit includes:
[0131] The decryption message parsing module is used to receive the message to be decrypted sent by the blockchain when the blockchain sends a message to the second system node, and to parse the message to be decrypted to obtain the operation instruction, the first authentication factor and the second authentication factor.
[0132] The asymmetric decryption processing module is used to obtain the private key in the asymmetric algorithm, decrypt the first authentication factor, and decrypt the second authentication factor after the first authentication factor has been decrypted.
[0133] The execution module is used to perform matching based on the first authentication factor and the second authentication factor, and execute operation instructions if the matching is successful.
[0134] Figure 5This is a structural block diagram of a data storage device for cross-system login based on blockchain, according to an embodiment of this application. Figure 5 As shown, the device includes: a second transmitting unit 11, a first storage unit 21, a third transmitting unit 31, and a second storage unit 41.
[0135] The second sending unit 11 is used to respond to the login verification information uploaded by the first system node, match the login verification information with the user information stored in the blockchain, and generate a matching result to send to the first system node.
[0136] The first storage unit 21 is used to store the first authentication factor in response to the first authentication factor and user information uploaded by the first system node, and to update the user information stored in the blockchain according to the user information uploaded by the first system node.
[0137] The third sending unit 31 is used to respond to the first decryption request uploaded by the second system node, match the first authentication factor carried in the first decryption request with the first authentication factor stored in the blockchain, and send the user information stored in the blockchain to the second system node if the match is successful.
[0138] The second storage unit 41 is used to store the second authentication factor in response to the second authentication factor and user information uploaded by the second system node, and to update the user information stored in the blockchain according to the user information uploaded by the second system node.
[0139] As one possible implementation, the first storage unit includes:
[0140] The decryption and analysis module is used to decrypt the login verification information using the private key in asymmetric encryption technology, and analyze the decrypted login verification information to obtain the first user information.
[0141] The information comparison module is used to compare the first user information with the second user information. If the second user information is consistent with the first user information, the matching result is determined to be a successful match. The second user information is user information stored on the blockchain.
[0142] The matching result determination module is used to determine the matching result as a match failure when the second user information is inconsistent with the first user information;
[0143] The matching result sending module is used to send the matching results to the first system node.
[0144] As one possible implementation, the third transmitting unit includes:
[0145] The parsing and extraction module is used to parse the first decryption request, extract the first authentication factor carried in the first decryption request, and obtain the first target factor;
[0146] The matching confirmation module is used to compare the first target factor with the second target factor. If the first target factor and the second target factor are consistent, the matching result is determined to be a successful match. The second target factor is the first authentication factor stored in the blockchain.
[0147] The matching failure confirmation module is used to determine the matching result as a matching failure when the first target factor and the second target factor are inconsistent.
[0148] The information generation module is used to send the user information stored on the blockchain to the second system node when the matching result is a successful match.
[0149] The aforementioned authentication and data storage device for cross-system login based on blockchain includes a processor and a memory. The first acquisition unit, first sending unit, first processing unit, control unit, second sending unit, first storage unit, third sending unit, and second storage unit are all stored as program units in the memory. The processor executes these program units stored in the memory to achieve the corresponding functions. All of the above modules are located in the same processor; alternatively, the modules may be located in different processors in any combination.
[0150] The processor contains a kernel, which retrieves the corresponding program units from memory. One or more kernels can be configured, and communication efficiency can be improved by adjusting kernel parameters.
[0151] The memory may include non-permanent memory in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM, and the memory includes at least one memory chip.
[0152] This invention provides a computer-readable storage medium that includes a stored program, wherein, when the program is running, it controls the device where the computer-readable storage medium is located to execute an authentication and data storage method for cross-system login based on blockchain.
[0153] This invention provides a processor for running a program, wherein the program executes an authentication and data storage method for cross-system login based on blockchain.
[0154] This invention provides a device, which includes a processor, a memory, and a program stored in the memory and executable on the processor. The device may be a server, PC, PAD, mobile phone, etc. When the processor executes the program, it implements at least the authentication and data storage method steps for cross-system login based on blockchain.
[0155] This application also provides a computer program product that, when executed on a data processing device, is suitable for performing a program that initializes authentication and data storage methods with at least one blockchain-based cross-system login method.
[0156] It will be apparent to those skilled in the art that the modules or steps of this invention can be implemented using general-purpose computing devices. They can be centralized on a single computing device or distributed across a network of multiple computing devices. They can be implemented using computer-executable program code, and thus can be stored in a storage device for execution by a computing device. In some cases, the steps shown or described can be performed in a different order than those presented herein, or they can be fabricated as separate integrated circuit modules, or multiple modules or steps can be fabricated as a single integrated circuit module. Thus, this invention is not limited to any particular combination of hardware and software.
[0157] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0158] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart... Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0159] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 a process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.
[0160] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing the instructions executed on the computer or other programmable device for implementing the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.
[0161] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0162] Memory may include non-persistent memory in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.
[0163] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0164] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.
[0165] As can be seen from the above description, the embodiments of this application achieve the following technical effects:
[0166] 1) The blockchain-based cross-system login authentication method of this application significantly improves the security of inter-system identity authentication by leveraging the decentralized, immutable, and traceable characteristics of blockchain technology. First and second authentication factors are generated encryptively and uploaded to the blockchain, ensuring the integrity and security of the authentication data. The blockchain verifies the user's identity by decryption and matching, avoiding the problem of authentication factors being tampered with or forged. Throughout the authentication process, dual authentication factors are used to strictly verify the identity of messages, preventing unauthorized access and thus ensuring the legitimacy of the user and the security of cross-system operations.
[0167] 2) The data storage method for cross-system login based on blockchain in this application ensures the security and consistency of user information by authenticating user information stored on the blockchain between the first and second system nodes. After each system node uploads authentication factors and user information, the blockchain can update and store the latest user data in real time, ensuring data validity and consistency. The decentralized storage method of blockchain not only improves data security but also reduces the risk of data tampering and loss. Furthermore, this method enables efficient data synchronization between multiple systems, allowing users to have consistent authentication information across different systems, improving interoperability and security, and is suitable for cross-platform authentication and data storage needs in multi-system environments.
[0168] 3) The authentication device for cross-system login based on blockchain of this application includes: a first acquisition unit, a first sending unit, a first processing unit, and a control unit. By utilizing the decentralized, immutable, and traceable characteristics of blockchain technology, the security of inter-system identity authentication is significantly improved. First and second authentication factors are generated through encryption and uploaded to the blockchain, ensuring the integrity and security of the authentication data. The blockchain verifies the user's identity by decryption and matching, avoiding the problem of authentication factors being tampered with or forged. Throughout the authentication process, dual authentication factors are used to strictly verify the identity of messages, preventing unauthorized access and thus ensuring the legitimacy of the user and the security of cross-system operations.
[0169] 4) The data storage device for cross-system login based on blockchain of this application includes: a second sending unit, a first storage unit, a third sending unit, and a second storage unit. By authenticating user information stored on the blockchain between the first system node and the second system node, the security and consistency of user information are ensured. After each system node uploads authentication factors and user information, the blockchain can update and store the latest user data in real time, ensuring data validity and consistency. Through the decentralized storage method of blockchain, not only is data security improved, but the risk of data tampering and loss is also reduced. Furthermore, this method can achieve efficient data synchronization between multiple systems, enabling users to have consistent authentication information in different systems, improving interoperability and security between systems, and is suitable for cross-platform authentication and data storage needs in multi-system environments.
[0170] The above description is merely a preferred embodiment of this application and is not intended to limit this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the protection scope of this application.
Claims
1. An authentication method for cross-system login based on blockchain, characterized in that, The blockchain includes user nodes, first system nodes, and second system nodes, and the method includes: In response to the system redirection request initiated by the user node, a first authentication factor is extracted based on the system redirection request. The system redirection request is used to request a redirection to a second system node when the user node logs into the first system node. The first authentication factor is an authentication factor encrypted and generated by the first system node based on authentication information and user information. Based on the first authentication factor, a first decryption request is sent to the blockchain. The first decryption request is used to instruct the blockchain to decrypt and match the first authentication factor, and if the decryption and matching are successful, to send the user information to the second system node. In response to the user information, the system encrypts the information using blockchain technology, generates a second authentication factor, and uploads the second authentication factor to the blockchain. During the interaction between the second system node and the blockchain, all messages are authenticated based on the first authentication factor, the second authentication factor, and the authentication information stored in the system.
2. The method according to claim 1, characterized in that, In response to the user information, a second authentication factor is generated by encrypting it using blockchain technology, including: The user information and the authentication information of the second system node are combined to obtain the data packet to be encrypted. The authentication information includes one or more of the unique identifier of the second system node, a timestamp, and a random number. In response to the user information, the system encrypts the information using blockchain technology, generates a second authentication factor, and uploads the second authentication factor to the blockchain.
3. The method according to claim 1, characterized in that, After responding to the user information, encrypting it using blockchain technology, generating a second authentication factor, and uploading the second authentication factor to the blockchain, the method further includes: The second authentication factor is embedded into the local token to obtain the first authentication token; The first authentication token is issued to the user node so that the user node incorporates the second authentication factor into all operations of the second system node.
4. The method according to claim 1, characterized in that, During the interaction between the second system node and the blockchain, all messages are authenticated based on the first authentication factor and the second authentication factor, including: When the second system node sends a message to the blockchain, a data packet to be sent is generated according to the operation instructions and related data. The first authentication factor and the second authentication factor are appended to the data packet to be sent to obtain the message to be sent. The message to be sent is sent to the blockchain. The blockchain is used to decrypt the received message to be sent using a private key in an asymmetric algorithm to obtain the second authentication factor. After obtaining the second authentication factor, the first authentication factor is decrypted using an asymmetric decryption algorithm to obtain the first authentication factor. The blockchain is then matched with the stored authentication information based on the first authentication factor and the second authentication factor to complete the authentication process.
5. The method according to claim 1, characterized in that, During the interaction between the second system node and the blockchain, all messages are authenticated based on the first authentication factor and the second authentication factor, including: When the blockchain sends a message to the second system node, the system receives the message to be decrypted sent by the blockchain and parses the message to be decrypted to obtain the operation instruction, the first authentication factor and the second authentication factor. Obtain the private key in the asymmetric algorithm, decrypt the first authentication factor, and decrypt the second authentication factor after the first authentication factor has been decrypted; The first authentication factor and the second authentication factor are matched with the stored authentication information, and the operation instruction is executed if the match is successful.
6. A data storage method for cross-system login based on blockchain, characterized in that, The blockchain includes user nodes, first system nodes, and second system nodes, and the method includes: In response to the login verification information uploaded by the first system node, the system matches the login verification information with the user information stored in the blockchain and generates a matching result which is then sent to the first system node. In response to the first authentication factor and the user information uploaded by the first system node, the first authentication factor is stored, and the user information stored in the blockchain is updated according to the user information uploaded by the first system node. In response to the first decryption request uploaded by the second system node, the first authentication factor carried in the first decryption request is matched with the first authentication factor stored in the blockchain, and if the match is successful, the user information stored in the blockchain is sent to the second system node. In response to the second authentication factor and the user information uploaded by the second system node, the second authentication factor is stored, and the user information stored in the blockchain is updated according to the user information uploaded by the second system node. The first authentication factor and the second authentication factor are used to authenticate all messages in combination with the authentication information stored in the system during the interaction between the second system node and the blockchain.
7. The method according to claim 6, characterized in that, In response to the login verification information uploaded by the first system node, a match is performed between the login verification information and the user information stored in the blockchain, and a matching result is generated and sent to the first system node, including: The login verification information is decrypted using a private key in asymmetric encryption technology, and the decrypted login verification information is analyzed to obtain the first user information; Based on the comparison between the first user information and the second user information, if the second user information is consistent with the first user information, the matching result is determined to be a successful match, and the second user information is the user information stored in the blockchain; If the second user information is inconsistent with the first user information, the matching result is determined to be a failed match; The matching results are sent to the first system node.
8. The method according to claim 6, characterized in that, In response to a first decryption request uploaded by the second system node, the system matches the first authentication factor carried in the first decryption request with the first authentication factor stored in the blockchain, and if the match is successful, sends the user information stored in the blockchain to the second system node, including: The first decryption request is parsed, and the first authentication factor carried in the first decryption request is extracted to obtain the first target factor; Based on the comparison between the first target factor and the second target factor, if the first target factor and the second target factor are consistent, the matching result is determined to be a successful match, and the second target factor is the first authentication factor stored in the blockchain; If the first target factor and the second target factor are inconsistent, the matching result is determined to be a failed match; If the matching result is successful, the user information stored in the blockchain is sent to the second system node.
9. An authentication device for cross-system login based on blockchain, characterized in that, The blockchain includes user nodes, first system nodes, and second system nodes, and the device includes: The first acquisition unit is configured to respond to a system redirection request initiated by the user node, and extract a first authentication factor according to the system redirection request. The system redirection request is used to request a redirection to a second system node when the user node logs into the first system node. The first authentication factor is an authentication factor encrypted and generated by the first system node based on authentication information and user information. The first sending unit is configured to send a first decryption request to the blockchain based on the first authentication factor. The first decryption request is used to instruct the blockchain to decrypt and match the first authentication factor, and if the decryption and matching are successful, to send the user information to the second system node. The first processing unit is configured to, in response to the user information, encrypt it using blockchain technology, generate a second authentication factor, and upload the second authentication factor to the blockchain; The control unit is used to authenticate all messages based on the first authentication factor, the second authentication factor, and the authentication information stored in the system during interaction with the blockchain.
10. A data storage device for cross-system login based on blockchain, characterized in that, The blockchain includes user nodes, first system nodes, and second system nodes, and the device includes: The second sending unit is used to respond to the login verification information uploaded by the first system node, match the login verification information with the user information stored in the blockchain, and generate a matching result to send to the first system node. The first storage unit is configured to, in response to the first authentication factor and the user information uploaded by the first system node, store the first authentication factor and update the user information stored in the blockchain according to the user information uploaded by the first system node. The third sending unit is used to respond to the first decryption request uploaded by the second system node, match the first authentication factor carried in the first decryption request with the first authentication factor stored in the blockchain, and if the match is successful, send the user information stored in the blockchain to the second system node. The second storage unit is used to store the second authentication factor in response to the second authentication factor and the user information uploaded by the second system node, and to update the user information stored in the blockchain according to the user information uploaded by the second system node. The first authentication factor and the second authentication factor are used to authenticate all messages in combination with the authentication information stored in the system during the interaction between the second system node and the blockchain.
Citation Information
Patent Citations
Login method and system of double-Token cross-end jump system
CN115102724A
Login authentication method and device based on block chain, equipment and storage medium
CN117614704A