Identity authentication method, key negotiation method, dynamic route switching method and system

By introducing security modules into the access point for identity authentication and key negotiation, combined with dynamic routing switching methods, the stability and security problems of communication systems in complex electromagnetic environments of live distribution lines are solved, and efficient and reliable communication transmission is achieved.

CN120201424AActive Publication Date: 2025-06-24BEIJING SMARTCHIP MICROELECTRONICS TECHNOLOGY CO LTD +2
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202510668050.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-05-23
Publication Date
2025-06-24
Estimated Expiration
2045-05-23

AI Technical Summary

Technical Problem

In the high voltage and strong current electromagnetic environment of the distribution live line, the communication system of the operating equipment is easily disturbed, resulting in slow transmission, interruption of transmission or unclear video images, and wireless communication is vulnerable to the risks of illegal access and man-in-the-middle attacks.

Method used

By introducing a security module auxiliary access point (AP) to complete identity authentication and key negotiation, the security and reliability of communication data are realized, and dynamic routing switching method is adopted to adaptively select the optimal route based on multiple communication indicators.

Benefits of technology

It improves the stability and security of the communication system in a complex electromagnetic environment, ensures the reliability of legal access and transmission of data, and at the same time realizes adaptive switching of dynamic routing to adapt to communication needs in different scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120201424A_ABST
    Figure CN120201424A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of communication, and discloses an identity authentication method, a key negotiation method, and a dynamic route switching method and system, and the authentication method comprises the steps: forwarding an initial response message from an STA to a security module; receiving a first response code generated by the security module based on the AP private key and the STA identifier in the initial response message, wherein the AP private key is stored in the security module; forwarding the first response code to the STA, so that the STA generates a second response code based on the first response code and the STA identifier and sends a final response message; receiving a final response message; generating a verification response code based on the first response code and the STA identifier in the final response message; and if the second response code in the final response message is consistent with the verification response code, determining that STA identity authentication succeeds, thereby realizing security and reliability of communication data by introducing a security module to assist the AP in completing identity authentication and key negotiation, and realizing adaptive switching of dynamic routing.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of communication technologies, and in particular to an identity authentication method, a key negotiation method, a dynamic routing switching method and system. Background Art

[0002] In the power distribution field, although the single communication between existing operating equipment and a remote control platform meets certain information transmission requirements in a specific environment, there are still many deficiencies. For example, the high-voltage and strong-current electromagnetic environment of a live power distribution line seriously interferes with the communication system of the operating equipment. On the one hand, effective electrical isolation is required between the live line and the control system of the operating equipment, and the wired connection is limited by the cable length, making the wiring work complex and dangerous. On the other hand, due to its inherent communication characteristics, traditional single wireless communication is easily affected by the complex electromagnetic environment of the live line, resulting in slower transmission, transmission interruption, or unclear transmitted video images.

[0003] For a wireless communication network, identity authentication is mainly performed between an access point (AP) and a station (STA). However, with the increasing openness of the network, security risk problems such as illegal access and man-in-the-middle attacks have become increasingly prominent. Summary of the Invention

[0004] The object of the present invention is to provide an identity authentication method, a key negotiation method, a dynamic routing switching method and system, which achieve the security and reliability of communication data by introducing a security module to assist the AP in completing identity authentication and key negotiation, and can realize the adaptive switching of dynamic routing.

[0005] To achieve the above object, in a first aspect of the present invention, an identity authentication method is provided, which is applied to an AP. The identity authentication method includes: forwarding an initial response message corresponding to a local authentication request from the STA to the security module; receiving a first response code generated by the security module based on the AP private key and the STA identifier in the initial response message, where the AP private key is stored in the security module; forwarding the first response code to the STA, so that the STA generates a second response code based on the first response code and the STA identifier and sends a final response message, where the final response message includes the second response code and the STA identifier; receiving the final response message; generating a verification response code based on the first response code and the STA identifier in the final response message; and determining that the identity authentication of the STA is successful when the second response code is consistent with the verification response code.

[0006] Through the above technical solution, the present invention creatively stores the AP private key in the security module. The security module generates a response code by using the AP private key and the STA identifier in the initial response message corresponding to the local authentication request sent by the STA; the STA generates a new response code by using the generated response code and the STA identifier, and sends the new response code and the STA identifier to the AP; the AP generates a verification response code based on the response code generated by the security module and the received STA identifier, and confirms the successful identity authentication of the STA when the new response code generated by the STA matches the verification response code. Thus, the management and update of the AP private key are centralized on the security module, reducing the management complexity of the AP device, achieving physical isolation of the private key, and ensuring the legitimacy of the STA identity through the verification response code, realizing secure data access.

[0007] The second aspect of the present invention provides an identity authentication method applied to the STA. The identity authentication method includes: sending an initial response message corresponding to the local authentication request to the AP, so that the AP forwards the initial response message to the security module, where the initial response message includes the STA identifier, and the security module generates a first response code based on the AP private key and the STA identifier in the initial response message and sends the first response code to the AP, where the AP private key is stored in the security module; receiving the first response code forwarded by the AP; generating a second response code based on the first response code and the STA identifier locally stored by the STA; and sending a final response message to the AP, so that the AP generates a verification response code based on the first response code and the STA identifier in the final response message and determines the successful identity authentication of the STA when the second response code in the final response message is consistent with the verification response code.

[0008] Through the above technical solution, the present invention creatively stores the AP private key in the security module. The security module generates a response code by using the AP private key and the STA identifier in the initial response message corresponding to the local authentication request sent by the STA; the STA generates a new response code by using the generated response code and the STA identifier, and sends the new response code and the STA identifier to the AP; the AP generates a verification response code based on the response code generated by the security module and the received STA identifier, and confirms the successful identity authentication of the STA when the new response code generated by the STA matches the verification response code. Thus, the management and update of the AP private key are centralized on the security module, reducing the management complexity of the AP device, achieving physical isolation of the private key, and ensuring the legitimacy of the STA identity through the verification response code, realizing secure data access.

[0009] A third aspect of the present invention provides a key negotiation method, which is applied to an AP. The key negotiation method includes: performing identity authentication according to the identity authentication method; forwarding key information corresponding to a key negotiation request from an STA to a security module, so that the security module executes: generating a session key based on a second random number generated by the STA and a random number generated by the AP, generating a negotiation response code based on the session key, a second STA ciphertext in the key information, and an STA identifier, and sending a response message to the AP, where the response message includes the negotiation response code and the STA identifier; in response to receiving the response message, generating a negotiation verification code based on the session key, the second STA ciphertext, and the STA identifier in the response message; and confirming successful key negotiation when the negotiation response code is consistent with the negotiation verification code.

[0010] Through the above technical solution, the present invention creatively introduces a security module to assist the AP in completing key negotiation on the basis of establishing identity authentication confirmation between the STA and the AP, and generates a new session key for each session to ensure the freshness of the session key and improve the security and reliability of key exchange.

[0011] A fourth aspect of the present invention provides a dynamic routing switching method. The switching method includes: performing key negotiation according to the key negotiation method; determining a plurality of weights corresponding to a plurality of communication metrics according to a fuzzy consistency matrix; determining an index weighted value under each single communication mode and an index weighted value under each combined communication mode according to a plurality of index values corresponding to the plurality of communication metrics and the plurality of weights under a single communication mode in a plurality of communication modes; and adaptively selecting a single communication mode or a combined communication mode corresponding to the maximum index weighted value according to a specific scenario.

[0012] Through the above technical solution, the present invention creatively adopts an intelligent routing selection algorithm based on the fuzzy analytic hierarchy process, comprehensively considers various factors such as bandwidth, delay, packet loss rate, security, and network load, and dynamically and adaptively switches the routing.

[0013] A fifth aspect of the present invention provides an AP. The AP includes: an execution device for executing the identity authentication method, the key negotiation method, or the dynamic routing switching method.

[0014] A sixth aspect of the present invention provides an STA. The STA includes: an execution device for executing the identity authentication method or the dynamic routing switching method.

[0015] A seventh aspect of the present invention provides an identity authentication system applied to an AP. The identity authentication system includes: a first forwarding device for forwarding an initial response message corresponding to a local authentication request from an STA to a security module; a first receiving device for receiving a first response code generated by the security module based on an AP private key and an STA identifier in the initial response message, where the AP private key is stored in the security module; a second forwarding device for forwarding the first response code to the STA, so that the STA generates a second response code based on the first response code and the STA identifier and sends a final response message, where the final response message includes the second response code and the STA identifier; a second receiving device for receiving the final response message; a generating device for generating a verification response code based on the first response code and the STA identifier in the final response message; and a determining device for determining that the identity authentication of the STA is successful when the second response code is consistent with the verification response code.

[0016] For the specific details and benefits of the identity authentication system provided by the embodiments of the present invention, reference may be made to the description of the identity authentication method above, and details will not be repeated here.

[0017] An eighth aspect of the present invention provides an identity authentication system applied to an STA. The identity authentication system includes: a first sending device for sending an initial response message corresponding to a local authentication request to an AP, so that the AP forwards the initial response message to a security module, where the initial response message includes an STA identifier, and the security module generates a first response code based on an AP private key and the STA identifier in the initial response message and sends the first response code to the AP, where the AP private key is stored in the security module; a receiving device for receiving the first response code forwarded by the AP; a generating device for generating a second response code based on the first response code and the STA identifier locally stored by the STA; and a second sending device for sending a final response message to the AP, so that the AP generates a verification response code based on the first response code and the STA identifier in the final response message and determines that the identity authentication of the STA is successful when the second response code in the final response message is consistent with the verification response code.

[0018] For the specific details and benefits of the identity authentication system provided by the embodiments of the present invention, reference may be made to the description of the identity authentication method above, and details will not be repeated here.

[0019] A ninth aspect of the present invention provides a key negotiation system applied to an AP. The key negotiation system includes: the identity authentication system for performing identity authentication; a forwarding device for forwarding key information corresponding to a key negotiation request from an STA to a security module, so that the security module executes: generating a session key based on a second random number generated by the STA and a random number generated by the AP, generating a negotiation response code based on the session key, a second STA ciphertext in the key information, and an STA identifier, and sending a response message to the AP, where the response message includes the negotiation response code and the STA identifier; a generating device for generating a negotiation verification code based on the session key, the second STA ciphertext, and the STA identifier in the response message in response to receiving the response message; and a confirmation device for confirming successful key negotiation when the negotiation response code is consistent with the negotiation verification code.

[0020] For specific details and benefits of the key negotiation system provided in the embodiments of the present invention, reference may be made to the above description of the key negotiation method, which will not be elaborated herein.

[0021] A tenth aspect of the present invention provides a dynamic routing switching system. The switching system includes: the key negotiation system for performing key negotiation; a first determining device for determining a plurality of weights corresponding to a plurality of communication metrics according to a fuzzy consistent matrix; a second determining device for determining an index weighted value under each single communication mode and an index weighted value under each combined communication mode according to a plurality of index values corresponding to the plurality of communication metrics and the plurality of weights under a single communication mode in a plurality of communication modes; and a selecting device for adaptively selecting a single communication mode or a combined communication mode corresponding to the maximum index weighted value according to a specific scenario.

[0022] For specific details and benefits of the dynamic routing switching system provided in the embodiments of the present invention, reference may be made to the above description of the dynamic routing switching method, which will not be elaborated herein.

[0023] An eleventh aspect of the present invention provides a computer-readable storage medium with a computer program stored thereon. When the computer program is executed by a processor, it implements the identity authentication method, the key negotiation method, or the dynamic routing switching method.

[0024] Other features and advantages of the present invention will be described in detail in the subsequent specific implementation section. BRIEF DESCRIPTION OF THE DRAWINGS

[0025] The accompanying drawings are used to provide a further understanding of the embodiments of the present invention and constitute a part of the specification. Together with the following detailed description, they are used to explain the embodiments of the present invention, but do not limit the embodiments of the present invention. In the accompanying drawings: Figure 1 is a flowchart of an identity authentication method provided by an embodiment of the present invention; Figure 2 is a structural diagram of a multimodal communication system provided by an embodiment of the present invention; Figure 3 is an interactive flowchart of an identity authentication process provided by an embodiment of the present invention; Figure 4 is a flowchart of an identity authentication method provided by an embodiment of the present invention; Figure 5 is a flowchart of a key negotiation method provided by an embodiment of the present invention; Figure 6 is an interactive flowchart of a key negotiation process provided by an embodiment of the present invention; Figure 7 is a flowchart of a method for switching dynamic routing provided by an embodiment of the present invention; and Figure 8 is a flowchart of a multimodal communication method provided by an embodiment of the present invention. Detailed Description of the Embodiments

[0026] The following provides a detailed description of the specific embodiments of the present invention with reference to the accompanying drawings. It should be understood that the specific embodiments described herein are only used to illustrate and explain the present invention and do not limit the present invention.

[0027] The establishment of an initial connection between the STA and the AP is a prerequisite for identity authentication and secure communication. First, the STA selects the best wireless communication method in terms of signal quality, actively scans the surrounding wireless environment, and sends a probe request to find available WAPI access points. After each AP receives the probe request from the STA, it will reply with a probe response containing the basic information of the AP, such as the SSID (Service Set Identifier), supported frequency bands, channels, etc. Once the STA determines the target AP, it will send an association request to that AP. If the AP accepts the association request from the STA, it will allocate necessary resources to the STA, such as channels, bandwidth, etc., and generate a temporary association ID (AID) for subsequent communication management. Then, the AP sends an association response to the STA, informing the STA whether the connection has been successfully established. If the association is successful, the response will contain the AID and other necessary configuration information; if it fails, the reason will be stated in the response. After a successful association, a basic communication link is established between the STA and the AP, and at this time, unencrypted data exchange can be carried out.

[0028] Through the above process, the STA and the AP establish a preliminary communication link, preparing for subsequent identity authentication and key negotiation.

[0029] Embodiment 1 Figure 1 FIG. 6 is a flowchart of an identity authentication method provided by an embodiment of the present invention, and the identity authentication method is applied to an AP. As Figure 1 shown, the identity authentication method includes: Step S101, forwarding an initial response message corresponding to a local authentication request from the STA to a security module; Step S102, receiving a first response code generated by the security module based on the AP private key and the STA identifier in the initial response message, where the AP private key is stored in the security module; Step S103, forwarding the first response code to the STA, so that the STA generates a second response code based on the first response code and the STA identifier and sends a final response message, where the final response message includes the second response code and the STA identifier; Step S104, receiving the final response message; Step S105, generating a verification response code based on the first response code and the STA identifier in the final response message; and Step S106, determining that the identity authentication of the STA is successful when the second response code is consistent with the verification response code.

[0030] Before introducing each embodiment of the present invention, a multi-modal communication system related to the identity authentication method, key negotiation method, and dynamic routing switching method provided by the present invention will be briefly introduced, as Figure 2 shown.

[0031] The hardware system may include an AS (Application Server) 10, an AP (Access Point) 20, a STA (Station) 30, a security module 40, etc.

[0032] Among them, the AS 10 (for example, a remote cloud platform) is located in a remote data center or a cloud server cluster, responsible for remote storage, computing, and analysis tasks of a large amount of data, providing core business logic support and services such as remote monitoring functions to ensure the normal operation of the system; communicating with the AP 20 (for example, a local control terminal, a static access point, etc., the AP specifically depends on the application scenario and requirements, such as: a router, a smart phone / tablet computer, an Internet of Things gateway, an embedded system) and the STA (for example, one or more of the STAs 30-1, 30-2, 30-3... 30-N, where the STA can be a local execution terminal, specifically such as a robot receiving device, a camera, a drone, a smart wearable device, an Internet of Things device) through remote broadband (4G / 5G) communication.

[0033] The AP 20 communicates with the STA (such as one or more of STA 30-1, 30-2, 30-3... 30-N) through local narrowband, local broadband, and remote broadband. It is responsible for sending on-site operation instructions, remotely controlling one or more STAs (such as one or more of STA30-1, 30-2, 30-3... 30-N) to carry out work, and collecting information such as the status information, environmental data, and operation video images of the STA (such as one or more of STA30-1, 30-2, 30-3... 30-N), which is saved on the AP 20 for subsequent copying and transferring to the AS 10. It can also directly connect to the AS 10 through 4G / 5G communication during idle time and upload it to the AS10 for analysis.

[0034] The STA (such as one or more of STA30-1, 30-2, 30-3... 30-N) is responsible for continuously monitoring the working environment and equipment status of the operation equipment, collecting raw data, receiving instructions from the AP 20, performing corresponding actions, and real-time feedback of the execution results or equipment status to the AP 20.

[0035] The security module 40 can be a third-party trusted mobile security medium, directly connected to the AP 20 through an external port, saves the certificate and secret key of the AP, is responsible for generating a response code, and can communicate with the AS 10 during idle time to update the certificate information and key.

[0036] Specifically, the STA sends an initial response message Response to the AP: Response = (ID STA , ID AP ), where ID STA is the STA identifier, and ID AP is the AP identifier.

[0037] Then, the AP receives the initial response message Response, and the AP forwards the initial response message to the security module.

[0038] Next, the security module generates a first response code S AP : , where SK AP is the private key of the AP saved in the security module, and where F HMAC is the HMAC algorithm, representing the hash-based message authentication code. The security module's first response code S AP is forwarded to the STA by the AP.

[0039] The STA receives the first response code S APAfter that, add its own relevant information ID to the first response code again STA , generate its own response information (i.e., the second response code) :[[]] .[[]]

[0040] The STA sends the final response message Final Response to the AP: Final Response = ( , ID STA ).[[]]

[0041] The AP receives the final response message and generates a verification response code according to the first response code and the STA identifier in the final response message: .[[]]

[0042] If , the authentication of the STA is successful and the STA is allowed to access temporarily; otherwise, the authentication of the STA is not successful and the access is refused, ensuring the security of the STA identity.

[0043] In this embodiment, during the identity authentication process, the private key of the AP is stored in the security module instead of directly on the AP device, realizing the physical isolation of the private key. When the independent security module is removed, the network is automatically disconnected and the certificate is deleted, improving the security; the security module, as an independent security medium, is logically isolated from the AP device, further enhancing the security of the system. Thus, simplified management can be achieved: the management and update of the private key can be centralized on the security module, reducing the management complexity of the AP device; the AP device can be replaced while the security module remains unchanged, improving the flexibility and maintainability of the system.

[0044] That is to say, use the security module as an external security medium to save the certificate and key of the access point (AP), be responsible for identity authentication with the terminal (STA), and adopt the HMAC (Hash-based Message AuthenticationCode) algorithm during the authentication process to improve the security of identity authentication.

[0045] In this embodiment, the AP verifies the STA identifier information to ensure that the response code is generated by a specific STA, preventing the STA from being impersonated; and supports multiple STAs to connect to the same AP. The AP can distinguish different STAs through the STA identifier information to ensure that the identity of each STA is legal.

[0046] Embodiment 2 Based on the above Embodiment 1, the final response message further includes the first STA ciphertext and the first HMAC generated by the STA.

[0047] Accordingly, the identity authentication method further includes: generating a local verification HMAC based on the AP private key, the first STA ciphertext in the final response message, and the AP identifier; and confirming whether the local verification HMAC is consistent with the first HMAC generated by the STA in the final response message.

[0048] The step of generating the verification response code is executed when the local verification HMAC is consistent with the first HMAC generated by the STA in the final response message.

[0049] Specifically, the STA sends an initial response message Response to the AP.

[0050] Response = (C STA , ID STA , HMAC STA , ID AP ), where C STA is the first STA ciphertext, ID STA is the STA identifier, HMAC STA is the first HMAC generated by the STA, and ID AP is the AP identifier.

[0051] Then, the AP receives the initial response message Response, and the AP forwards the initial response message to the security module.

[0052] Next, the security module generates a first response code S AP .

[0053] , where SK AP is the AP private key stored in the security module. The security module forwards the first response code S AP to the STA via the AP.

[0054] After receiving the first response code S AP , the STA adds its own relevant information ID STA , to the first response code again to generate its own response information (i.e., the second response code) : .

[0055] The STA sends a final response message Final Response to the AP: Final Response = (C STA , , ID STA, HMAC STA ).

[0056] After the AP receives the final response message Final Response sent by the STA, the AP uses its own private key SK AP to decrypt the ciphertext C sent by the STA STA , and extracts the decryption result r: r = D(SK AP , C STA ), where D is the decryption operation and SK AP is the AP private key.

[0057] The AP generates a local verification HMAC (i.e., HMAC AP-check-STA ): , If HMAC AP-check-STA = HMAC STA , the preliminary verification of the STA's identity is successful.

[0058] The AP receives the final response message and generates a verification response code based on the first response code and the STA identifier in the final response message: .

[0059] If , the STA's authentication is successful and the STA is allowed to access temporarily; otherwise, the STA's authentication fails and access is denied, ensuring the security of the STA's identity.

[0060] The AP distinguishes different STAs by verifying the STA identifier information, can support multiple STAs to connect to the same AP simultaneously, and ensures that the identity of each STA is legal.

[0061] This embodiment can achieve anti-tampering: the security module is responsible for generating the response code to ensure that the response code is generated by a legitimate security module, preventing man-in-the-middle attacks and tampering; the AP uses its own private key to verify the HMAC to ensure the integrity and authenticity of the message.

[0062] Embodiment Three Based on the above-mentioned Second Embodiment, before executing step S101, the identity authentication method further includes: receiving the initial response message from the STA, where the initial response message includes an AP identifier, an STA identifier, a first STA ciphertext, and a first HMAC generated by the STA; and verifying whether the AP identifier in the initial response message is consistent with the AP identifier in the local authentication request. Correspondingly, the step of forwarding the initial response message corresponding to the local authentication request from the STA to the security module is executed when the AP identifier in the initial response message is consistent with the AP identifier in the local authentication request.

[0063] Specifically, the STA sends an initial response message Response to the AP: Response = (C STA , ID STA , HMAC STA , ID AP ), where C STA is the first STA ciphertext, ID STA is the STA identifier, HMAC STA is the first HMAC generated by the STA, and ID AP is the AP identifier.

[0064] Then, the SP receives the initial response message Response and verifies whether the ID AP is consistent with the AP identifier in the local authentication request. Only when they are consistent will the AP forward the initial response message to the security module.

[0065] Next, the security module generates a first response code S AP based on the received initial response message: , where SK AP is the AP private key stored in the security module. The security module's first response code S AP is forwarded to the STA via the AP.

[0066] After receiving the first response code S AP , the STA adds its own relevant information ID STA , to the first response code again to generate its own response information (i.e., the second response code) : .

[0067] The STA sends a final response message Final Response to the AP: Final Response = (CSTA , , ID STA , HMAC STA ).

[0068] After the AP receives the Final Response message sent by the STA, the AP uses its own private key SK AP to decrypt the ciphertext C sent by the STA STA , and extracts the decryption result r: r = D(SK AP , C STA ), where D is the decryption operation and SK AP is the private key of the AP.

[0069] The AP generates a local verification HMAC (i.e., HMAC AP-check-STA ): , If HMAC AP-check-STA = HMAC STA , the preliminary verification of the STA's identity is successful.

[0070] The AP receives the final response message and generates a verification response code based on the first response code and the STA identifier in the final response message: .

[0071] If , the authentication of the STA is successful and the STA is allowed to access temporarily; otherwise, the authentication of the STA is not successful and the access is refused, ensuring the security of the STA's identity.

[0072] Embodiment 4 Based on any of the above embodiments, when forwarding the initial response message corresponding to the local authentication request from the STA to the security module (i.e., step S101), simultaneously or afterwards, the identity authentication method further includes: retaining the STA identifier in the initial response message; verifying whether the STA identifier in the final response message is consistent with the STA identifier in the initial response message. Correspondingly, the step of generating the local verification HMAC (i.e., performing step S105) is executed when the STA identifier in the final response message is consistent with the STA identifier in the initial response message.

[0073] After the AP receives the initial response message sent by the STA, it first verifies whether the ID AP in the initial response message is consistent with the AP identifier of the AP itself. After confirmation, it forwards the initial response message to the security module and retains the identifier ID STA. Then, the AP verifies the reserved ID STA against the ID in the final response message STA to ensure the legitimacy of the STA. Only when they match, the AP uses its own private key SK AP to decrypt the ciphertext C STA sent by the STA to obtain the decryption result. Finally, the AP verifies the HMAC of the STA to ensure the integrity of the message and the authenticity of the source.

[0074] Embodiment 5 Based on any of the above embodiments, the identity authentication method further includes: sending the local authentication request so that the STA generates a first HMAC based on the AP identifier in the local authentication request and the first random number generated by the STA, and the STA sends the initial response message, where the initial response message includes the first HMAC generated by the STA, the local authentication request further includes the AP public key, and the first STA ciphertext is generated based on the AP public key and the first random number generated by the STA.

[0075] For step S105, generating the local verification HMAC includes: decrypting the first STA ciphertext in the final response message based on the AP private key to obtain a random number; and generating the local verification HMAC based on the obtained random number and the AP identifier in the final response message.

[0076] Specifically, first, the AP sends a local authentication request Request: Request = (ID AP , PK AP ), where ID AP is the AP identifier and PK AP is the AP public key.

[0077] Alternatively, the AP generates a random number r AP . Then, the AP sends a local authentication request Request: Request = (ID AP , r AP , PK AP ), where ID AP is the AP identifier, r AP is the random number generated by the AP, and PK AP is the AP public key.

[0078] Secondly, the STA generates a first random number r STA . Then, the STA generates a first STA ciphertext C STA : C STA= E(PK AP ,r STA ), where C STA is the first STA ciphertext generated by the STA, E is the encryption operation, PK AP is the AP public key, and r STA is the first random number generated by the STA.

[0079] Upon receiving a local authentication request, the STA generates a first HMAC: , where F HMAC is the HMAC algorithm, representing a hash-based message authentication code, and HMAC is used to verify that the message has not been tampered with during transmission.

[0080] Alternatively, upon receiving a local authentication request, the STA generates a first HMAC: , where F HMAC is the HMAC algorithm, representing a hash-based message authentication code; K STA is the key of the STA, and the STA uses its own key K STA to generate a hash-based message authentication code (HMAC) to ensure the integrity and authenticity of the source of the message. HMAC is used to verify that the message has not been tampered with during transmission and to ensure that the message indeed comes from a legitimate STA.

[0081] After receiving the final response message Final Response sent by the STA, the AP uses its own private key SK AP to decrypt the first STA ciphertext C STA sent by the STA to extract the first random number r STA generated by the STA: r STA =D(SK AP , C STA ), where D is the decryption operation and SK AP is the AP private key.

[0082] The AP generates a local verification HMAC (i.e., HMAC AP-check-STA ): .

[0083] If HMAC AP-check-STA =HMAC STA , the preliminary verification of the STA's identity is successful.

[0084] Example Six Based on the second or third embodiment above, when the security module generates the first response code based on the AP private key, the first STA ciphertext, the STA identifier, the first timestamp of the AP, and the first timestamp of the STA in the initial response message, the second response code is generated by the STA based on the first response code, the STA identifier stored locally by the STA, and the second timestamp of the STA.

[0085] Correspondingly, generating the verification response code based on the first response code and the STA identifier in the final response message includes: confirming whether the second timestamp of the STA in the second response code is within a first preset time range; and when the second timestamp is within the first preset time range, generating the verification response code based on the first response code, the STA identifier, and the second timestamp of the STA in the final response message.

[0086] Specifically, the security module generates the first response code S according to the received message AP : , where SK AP is the AP private key stored in the security module.

[0087] After the STA receives the first response code S AP , it adds the second timestamp information TS STA-second and its own relevant information ID STA to the response code again to generate the second response code : .

[0088] The STA sends the final response message Final Response to the AP: Final Response = (C STA , , ID STA , TS STA-first , HMAC STA ).

[0089] Verify whether the second timestamp TS STA-second of the STA in STA is within the first preset time range to ensure that the response code is generated within the valid time; at the same time, verify the validity of the identifier ID

[0090] to ensure that the response code is generated by a specific STA, and ensure the integrity and freshness of the message through the two aspects of verification to prevent replay attacks. , generate an authentication response code based on the STA identifier and the second timestamp of the STA in the final response message: , If , the authentication of the STA is successful, and the STA is allowed to access temporarily; otherwise, the authentication of the STA fails and access is refused, ensuring the security of the STA identity.

[0091] Furthermore, the identity authentication method further includes: sending the local authentication request, where the local authentication request includes the AP identifier, the AP public key, the first timestamp of the AP, and the first random number generated by the STA, so that the STA generates the first HMAC based on the STA key, the first random number generated by the STA, and the AP identifier and the first timestamp of the AP in the local authentication request and sends the initial response message.

[0092] Correspondingly, forwarding the initial response message corresponding to the local authentication request from the STA to the security module includes: when the AP identifier and the first timestamp of the AP in the initial response message are respectively consistent with the AP identifier and the first timestamp of the AP in the local authentication request, confirming whether the first timestamp of the STA is within the second preset time range; and when the first timestamp of the STA is within the second preset time range, retaining the first timestamp and the STA identifier of the STA in the initial response message, and forwarding the initial response message and the first timestamp of the AP to the security module, so that the security module generates a first response code based on the AP private key, the first STA ciphertext in the initial response message, the first timestamp and the STA identifier of the STA, and the first timestamp of the AP and sends the first response code to the AP.

[0093] First, the AP generates a random number r AP and the first timestamp TS AP ; the AP sends the local authentication request to the STA: Request=(ID AP ,r AP ,TS AP-first ,PK AP ), where, ID AP is the AP identifier, r AP is the random number generated by the AP, TS AP-first is the first timestamp generated by the AP, and PK AP is the AP public key.

[0094] Then, the STA generates the first random number r STA and the first timestamp TSSTA ; The STA generates the ciphertext: C STA = E(PK AP , r STA ), where C STA is the first STA ciphertext generated by the STA, E is the encryption operation, PK AP is the AP public key, and r STA is the first random number generated by the STA.

[0095] Next, the STA generates the first HMAC: , where F HMAC is the HMAC algorithm, representing the hash-based message authentication code; K STA is the STA key. The STA uses its own key K STA to generate the hash-based message authentication code (HMAC) to ensure the integrity of the message and the authenticity of the source. The HMAC is used to verify that the message has not been tampered with during transmission and to ensure that the message indeed comes from a legitimate STA.

[0096] The STA sends the initial response message Response to the AP.

[0097] Response = (C STA , ID STA , TS STA-first , HMAC STA , ID AP , TS AP-first ), where ID STA is the STA identifier, TS STA-first is the first timestamp generated by the STA, and HMAC STA is the message authentication code generated by the STA using its own key (i.e., the STA generates the first HMAC).

[0098] After receiving the initial response message sent by the STA, the AP first verifies whether the ID AP and TS AP-first in the response message are consistent with the corresponding information in the local authentication request sent by the AP before, and checks the timestamp freshness of TS STA-first . After confirming that there is no error, it forwards the response message to the security module and retains the STA's ID STA and the timestamp TS STA-first generated by it; At the same time, the AP also sends the first timestamp TS AP-first generated by itself to the security module. The security module generates the first response code S AP : , where SK AP is the AP private key stored in the security module.

[0099] The security module forwards the first response code S AP to the STA via the AP.

[0100] In this embodiment, by adding timestamp information to the response code, the AP can verify whether the response code is generated within the valid time, preventing replay attacks. At the same time, the timestamp ensures the real-time nature of the authentication process, improving the response speed and security of the system.

[0101] Embodiment Seven Based on the above various embodiments, the identity authentication method further includes: sending a remote authentication request to the AS, where the remote authentication request includes: the first STA ciphertext, the STA identifier, the first HMAC generated by the STA, and the AP identifier, so that the AS generates a remote verification HMAC based on the STA public key and the first STA ciphertext and the AP identifier in the remote authentication request, and when the remote verification HMAC is consistent with the first HMAC generated by the STA, the AS confirms that the identity authentication of the STA is successful.

[0102] Specifically, the AP generates a remote authentication request Forward, which includes the first STA ciphertext C of the STA STA , the identifier ID STA , the first HMAC generated by the STA STA , and the AP identifier ID AP : Forward = (C STA , ID STA , HMAC STA , ID AP ).

[0103] The AP sends the request Forward to the AS.

[0104] The AS uses the STA public key to decrypt the first STA ciphertext of the STA to obtain the decryption result; then, the AS uses the STA key ( is a pre-shared key that the AS has) to recalculate the remote verification HMAC of the STA (i.e., ), and compares it with the first HMAC generated by the STA (i.e., ): r = D(PK STA , C STA ),

[0105] Among them, FHMAC is the HMAC algorithm, representing the hash-based message authentication code.

[0106] If , the authentication of the STA is successful.

[0107] Embodiment VIII Based on the above Embodiment VI, the identity authentication method further includes: sending a remote authentication request to the AS, where the remote authentication request includes: the first STA ciphertext, the STA identifier, the first HMAC generated by the STA, the AP identifier, and the second timestamp of the STA, so that the AS generates a remote verification HMAC based on the STA public key and the first STA ciphertext and the AP identifier in the remote authentication request, and the AS confirms that the identity authentication of the STA is successful when the remote verification HMAC is consistent with the first HMAC generated by the STA and the second timestamp of the STA is within the first preset time range.

[0108] Specifically, the AP generates a remote authentication request Forward, which includes the first STA ciphertext C of the STA STA and the identifier ID STA , the first HMAC generated by the STA STA , the AP identifier ID AP , the second timestamp TS of the STA STA-second : Forward = (C STA , ID STA , TS STA-second , HMAC STA , ID AP ).

[0109] The AP sends the request Forward to the AS.

[0110] The AS uses the STA public key PKSTA to decrypt the first STA ciphertext CSTA of the STA to obtain the decryption result; then, the AS recalculates the remote verification HMAC of the STA (i.e., ), and compares it with the first HMAC generated by the STA (i.e., ): r = D(PK STA , C STA ),

[0111] where It is the HMAC algorithm, representing the Hash-based Message Authentication Code.

[0112] If , the authentication of the STA is successful.

[0113] Alternatively, in the seventh or eighth embodiment above, the decryption result r is a random number generated by the STA.

[0114] Embodiment Nine Based on any of the above embodiments, the identity authentication method further includes: sending a remote authentication request to the AS, where the remote authentication request includes: the STA identifier, the HMAC generated by the AP, the random number generated by the AP, the second timestamp of the AP, so that the AS generates a remote verification HMAC based on the STA identifier and the second timestamp of the AP in the remote authentication request and confirms that the identity authentication of the AP is successful when the remote verification HMAC is consistent with the HMAC generated by the AP.

[0115] Specifically, the AP generates a remote authentication request Forward, including the STA identifier (i.e., ID STA ), the random number r generated by the AP AP-new , the HMAC generated by the AP (i.e., HMAC AP ), and the second timestamp TS of the AP AP-second : , Forward = (ID STA , HMAC AP , r AP-new , TS AP-second ).

[0116] The AS generates a remote verification HMAC based on the random number r of the AP AP-new , the STA identifier (ID STA ), and the second timestamp TS of the AP AP-second : , where K AP is the AP key used to generate the HMAC.

[0117] If HMAC AS-check-AP = HMAC AP , the authentication of the AP is successful, and the AS subsequently sends an authentication message to notify the AP to allow the STA to access. Otherwise, the AS notifies the AP to reject the STA access.

[0118] In this embodiment, the AS authenticates the identity of the AP through a remote authentication process, ensuring that the AP received by the STA is legal and preventing man-in-the-middle attacks. For example, combined with the STA identity authentication in Embodiment 1: The AP verifies the STA identification information in the response code forwarded by the STA, ensuring that the identity of the STA is legal and preventing the STA from being forged. Thus, two-way authentication can be achieved.

[0119] Embodiment Ten Based on any of the above embodiments, the identity authentication method further includes: receiving a secondary authentication message from the AS, where the secondary authentication message includes: a first AP ciphertext, an AP identifier, and an HMAC about the AP generated by the AS; decrypting the first AP ciphertext based on the AP private key to obtain an AS random number; generating a first AS verification HMAC based on the AS random number and the AP identifier in the secondary authentication message; and confirming that the signature verification of the AS is successful when the first AS verification HMAC is consistent with the HMAC about the AP and the AP identifier in the secondary authentication message is consistent with the AP identifier locally stored by the AP.

[0120] Specifically, the AS sends a secondary authentication message AS Response to the AP: AS Response=(C AP , HMAC AS-AP , ID AP ), The AP decrypts the first AP ciphertext C AP based on the AP private key SK AP to obtain the AS random number r AS : r AS =D(SK AP ,C AP ); Then, a first AS verification HMAC (i.e., HMAC AP-check-AS ) is generated based on the AS random number and the AP identifier: , where K AS is the AS key, If and the AP identifier in the secondary authentication message received by the AP is consistent with its own unique identifier, the signature verification of the AS is successful. The AP receives the remote authentication response from the AS and allows the STA to access.

[0121] This embodiment can achieve double verification: The AP verifies the identity of the STA locally, and the remote AS performs secondary verification to ensure the overall security of the system.

[0122] Embodiment Eleven Based on the above-mentioned Ninth Embodiment, the identity authentication method further includes: receiving a secondary authentication message from the AS, where the secondary authentication message includes: the first AP ciphertext, the AP identifier, the HMAC of the AP generated by the AS, the AS timestamp, and the second timestamp of the AP; decrypting the first AP ciphertext based on the AP private key to obtain the AS random number; generating the first AS verification HMAC based on the AS random number, the AP identifier, and the AS timestamp; and confirming that the signature verification of the AS is successful when the first AS verification HMAC is consistent with the HMAC of the AP, the AP identifier in the secondary authentication message is consistent with the AP identifier locally stored in the AP, and the second timestamp of the AP in the secondary authentication message is consistent with the second timestamp of the AP in the remote authentication request.

[0123] Specifically, the AS generates the first AP ciphertext of the AP and the HMAC of the AP generated by the AS (i.e., ): , where E is the encryption operation, is the AP public key, .

[0124] Among them, is the timestamp generated by the AS, is the HMAC of the newly generated AP by the AS.

[0125] The AS sends the secondary authentication message AS Response to the AP: AS Response =( C AP , HMAC AS-AP , TS AS ,ID AP , TS AP-second ), The AP decrypts the first AP ciphertext C AP based on the AP private key SK AP to obtain the AS random number r AS : r AS =D(SK AP ,C AP ); Then, the first AS verification HMAC (i.e., HMAC AP-check-AS ) is generated based on the AS random number, the AP identifier, and the AS timestamp: , where, K AS is the AS key, If , the AP identifier in the secondary authentication message received by the AP is consistent with its own unique identifier, and the TS in the secondary authentication message AP-second is consistent with the TS in the remote authentication request AP-second , then the signature verification of the AS is successful. The AP receives the remote authentication response from the AS and allows the STA to access. Since the AS may be attacked, the AP identifier and / or TS AP-second in the sent secondary authentication request may both change, so the security of the AS can be confirmed through the above verification.

[0126] In addition, the STA can also verify the response of the AS in the following way.

[0127] First, the AS generates a random number r AS , generates a timestamp TS AS , generates an AS ciphertext C AS and an HMAC AS-STA : C AS = E(PK STA , r AS ), , where C AS is the generated AS ciphertext, K AS is the AS key, and HMAC AS-STA is the newly generated HMAC of the STA by the AS.

[0128] Second, the secondary authentication request AS Response may also include: C AS , HMAC AS-STA , ID STA , and the AP forwards some information Response1 in the secondary authentication request to the STA: Response1 = (C AS , HMAC AS-STA , ID STA , TS AS ).

[0129] The STA decrypts the ciphertext of the AS: r AS = D(PK STA , C AS ); The STA generates an AS verification HMAC STA-check-AS : , If HMAC STA-check-AS = HMAC AS-STA , and the STA identifier in the secondary authentication request is consistent with the STA's own unique identifier, then the signature verification of the AS is successful, the secondary authentication process is completed, and the STA accesses the AP network.

[0130] In summary, the present invention stores the AP private key in a security module. The security module generates a response code by using the AP private key and the STA identifier in the initial response message corresponding to the local authentication request sent by the STA. The STA generates a new response code by using the generated response code and the STA identifier, and sends the new response code and the STA identifier to the AP. The AP generates a verification response code based on the response code generated by the security module and the received STA identifier, and confirms that the identity authentication of the STA is successful when the new response code generated by the STA matches the verification response code. Thus, the management and update of the AP private key are centralized on the security module, reducing the management complexity of the AP device, achieving physical isolation of the private key, and ensuring the legitimacy of the STA identity through the verification response code, realizing secure data access.

[0131] Embodiment Twelve Figure 4 is a flowchart of an identity authentication method provided by an embodiment of the present invention. The identity authentication method is applied to the STA. As Figure 4 shown, the identity authentication method includes: Step S401, sending an initial response message corresponding to a local authentication request to the AP, so that the AP forwards the initial response message to the security module, where the initial response message includes the STA identifier, and the security module generates a first response code based on the AP private key and the STA identifier in the initial response message and sends the first response code to the AP, where the AP private key is stored in the security module; Step S402, receiving the first response code forwarded by the AP; Step S403, generating a second response code based on the first response code and the STA identifier locally stored by the STA; and Step S404, sending a final response message to the AP, so that the AP generates a verification response code based on the first response code and the STA identifier in the final response message and determines that the identity authentication of the STA is successful when the second response code in the final response message is consistent with the verification response code.

[0132] For specific details, please refer to the relevant description in Embodiment One above, and no further elaboration will be provided here.

[0133] Embodiment Thirteen Based on the above Embodiment Twelve, the final response message further includes a first STA ciphertext and a first HMAC generated by the STA.

[0134] Correspondingly, the AP performs: generating a local verification HMAC based on the AP private key, the first STA ciphertext in the final response message, and the AP identifier; and confirming whether the local verification HMAC is consistent with the first HMAC generated by the STA in the final response message.

[0135] The step of generating the verification response code is performed when the locally verified HMAC is consistent with the first HMAC generated by the STA in the final response message.

[0136] For the specific content, please refer to the relevant description in the second embodiment above, and details will not be repeated here.

[0137] Embodiment Fourteen Based on the above Embodiment Twelve, the identity authentication method further includes: receiving the local authentication request; generating a first HMAC based on the AP identifier in the local authentication request and the first random number generated by the STA, and sending, by the STA, the initial response message, where the initial response message includes the first HMAC generated by the STA, and the local authentication request includes the AP public key; generating the first STA ciphertext based on the AP public key and the first random number generated by the STA.

[0138] (By the AP) in step S404, generating the locally verified HMAC based on the AP private key, the first STA ciphertext in the final response message, and the AP identifier includes: decrypting the first STA ciphertext in the final response message based on the AP private key to obtain a random number; and generating the locally verified HMAC based on the obtained random number and the AP identifier in the final response message.

[0139] For the specific content, please refer to the relevant description in the fifth embodiment above, and details will not be repeated here.

[0140] Embodiment Fifteen Based on the above Embodiment Fourteen, when the security module generates the first response code based on the AP private key, the first STA ciphertext, the STA identifier, the first timestamp of the AP, and the first timestamp of the STA, generating the second response code based on the first response code and the STA identifier locally stored by the STA includes: generating the second response code based on the first response code, the STA identifier locally stored by the STA, and the second timestamp of the STA.

[0141] Generating the verification response code based on the first response code and the STA identifier in the final response message includes: confirming whether the second timestamp of the STA in the second response code is within a first preset time range; and when the second timestamp is within the first preset time range, generating the verification response code based on the first response code, the STA identifier in the final response message, and the second timestamp of the STA.

[0142] Further, the identity authentication method further includes: receiving the local authentication request, where the local authentication request includes the AP identifier, the AP public key, and the first timestamp of the AP; generating a first HMAC based on the STA key, the first random number generated by the STA in the local authentication request, the AP identifier, and the first timestamp of the AP, and sending the initial response message, where the initial response message includes the first HMAC generated by the STA.

[0143] Correspondingly, (by the AP) forwarding the initial response message to the security module includes: when the AP identifier and the first timestamp of the AP in the initial response message are respectively consistent with the AP identifier and the first timestamp of the AP in the local authentication request, confirming whether the first timestamp of the STA is within the second preset time range; and when the first timestamp of the STA is within the second preset time range, retaining the first timestamp of the STA and the STA identifier in the initial response message, and forwarding the initial response message and the first timestamp of the AP to the security module, so that the security module generates a first response code based on the AP private key, the first STA ciphertext, the first timestamp of the STA, the STA identifier, and the first timestamp of the AP in the initial response message, and sends the first response code to the AP.

[0144] For specific details, please refer to the relevant description in Embodiment 6 above, and details will not be elaborated here.

[0145] Embodiment 16 Based on any of the above embodiments, the identity authentication method further includes: receiving a secondary authentication message forwarded by the AP, where the secondary authentication message includes: the AS ciphertext, the STA identifier, and the HMAC of the STA generated by the AS; decrypting the AS ciphertext based on the STA public key to obtain the AS random number; generating a second AS verification HMAC based on the AS random number and the STA identifier in the secondary authentication message; and when the second AS verification HMAC is consistent with the HMAC of the STA generated by the AS and the STA identifier in the secondary authentication message is consistent with the STA identifier locally stored by the STA, confirming that the signature verification of the AS is successful.

[0146] First, the AS generates a random number r AS , generates a timestamp TS AS , generates an AS ciphertext C AS and an HMAC AS-STA : C AS =E(PK STA , r AS ), , where C AS is the generated AS ciphertext, K AS is the AS key, and HMAC AS-STA is the HMAC of the newly generated STA by AS.

[0147] Secondly, the secondary authentication request AS Response may further include: the AS ciphertext C AS , the HMAC of the STA generated by AS (i.e., HMAC AS-STA ), and ID STA . The AP forwards part of the information Response1 in the secondary authentication request to the STA: Response1 = (C AS , HMAC AS-STA , ID STA ).

[0148] The STA decrypts the AS ciphertext r AS = D(PK STA , C AS ), where PK STA is the STA public key; the STA verifies the HMAC of AS AS-STA , , where K AS is the AS key, If HMAC STA-check-AS = HMAC AS-STA , and the STA identifier in the secondary authentication request is consistent with the unique identifier of the STA itself, then the signature verification of AS is successful, the secondary authentication process is completed, and the STA accesses the AP network.

[0149] Embodiment Seventeen Based on the above Embodiment Fifteen, the identity authentication method further includes: receiving a secondary authentication message forwarded by the AP, where the secondary authentication message includes: an AS ciphertext, an STA identifier, an HMAC of the STA generated by AS, and an AS timestamp; decrypting the AS ciphertext based on the STA public key to obtain an AS random number; generating a second AS verification HMAC based on the AS random number, the STA identifier in the secondary authentication message, and the AS timestamp; and confirming that the signature verification of the AS is successful when the second AS verification HMAC is consistent with the HMAC of the STA generated by AS and the STA identifier in the secondary authentication message is consistent with the STA identifier stored locally by the STA.

[0150] First, the AS generates a random number r AS , generates a timestamp TS AS , and generates an AS ciphertext C ASand HMAC AS-STA : C AS = E(PK STA , r AS ), where PK AP is the public key of AP, , where, C AS is the generated AS ciphertext, K AS is the AS key, HMAC AS-STA is the HMAC of the newly generated STA by AS.

[0151] Secondly, the secondary authentication request AS Response may include: AS ciphertext C AS , ID STA , the HMAC of STA generated by AS (i.e., HMAC AS-STA ), AS timestamp TSAS. AP forwards some information Response1 in the secondary authentication request to STA: Response1 = (C AS , HMAC AS-STA , ID STA , TS AS ).

[0152] STA decrypts the AS ciphertext r AS = D(PK STA , C AS ), where, PK STA is the public key of STA; STA verifies the HMAC of AS AS-STA , , where, K AS is the AS key, If HMAC STA-check-AS = HMAC AS-STA , and the STA identifier in the secondary authentication request is consistent with the unique identifier of STA itself, then the signature verification of AS is successful, the secondary authentication process is completed, and STA accesses the AP network.

[0153] Example 18 As Figure 3 shown, the interaction process between AP, STA, and the security module may include steps 1-9, which are specifically described below.

[0154] 1. AP generates a random number and a timestamp AP generates a random number r AP and a timestamp TS AP .

[0155] 2. AP sends an authentication request AP sends the authentication request to STA.

[0156] Request=(ID AP ,r AP ,TS AP-first ,PK AP ) Among them, ID AP is the AP identifier, r AP is a random number generated by the AP, TS AP-first is the first timestamp generated by the AP, PK AP is the AP public key.

[0157] 3. The STA generates a random number and a timestamp The STA generates a random number r STA and a timestamp TS STA .

[0158] 4. The STA generates a ciphertext C STA = E(PK AP ,r STA ) Among them, C STA is the ciphertext generated by the STA, E is the encryption operation, PK AP is the AP public key, r STA is the random number generated by the STA.

[0159] 5. The STA generates an HMAC , Among them, F HMAC is the HMAC algorithm, representing the hash-based message authentication code, K STA is the STA key. The STA uses its own key K STA to generate the hash-based message authentication code (HMAC) to ensure the integrity of the message and the authenticity of the source. The HMAC is used to verify that the message has not been tampered with during transmission and to ensure that the message indeed comes from a legitimate STA.

[0160] 6. The STA sends the response message for the first time The STA sends the response message Response to the AP.

[0161] Response = (C STA ,ID STA ,TS STA-first ,HMAC STA ,ID AP ,TS AP-first ), Among them, ID STA is the STA identifier, TS STA-first is the first timestamp generated by the STA, HMAC STAIt is the message authentication code generated by the STA using its own key.

[0162] 7. The security module generates a response code After the AP receives the first response message sent by the STA, it first verifies the ID in the response message AP and TS AP-first to see if they are the same as those in the authentication request sent by the AP before, and checks the timestamp freshness of TS STA-first . After confirmation, it forwards the response message to the security module. Also, the AP retains the ID of the STA STA and the first timestamp TS generated by it STA-first ; at the same time, the AP also sends the first timestamp TS generated by itself AP-first to the security module. The security module generates a response code S AP : , where SK AP is the private key of the AP stored in the security module.

[0163] The security module forwards the response code S AP to the STA via the AP. At the same time, the AP also sends the retained ID STA , the first timestamp TS generated by itself AP-first , and the first timestamp TS generated by the STA STA-first to the STA: Forward=(S AP , ID STA ,TS STA-first ,TS AP-first ).

[0164] 8. The STA sends the final response message After the STA receives the response code S AP , it processes the response message and then verifies the ID STA and TS STA-first to see if they are the unique identifier sent by the STA itself and the first generated timestamp. After confirmation, it adds the second timestamp TS STA-second and its own related information ID STA to the response code again, generating a new response code : .

[0165] The STA sends the final response message Final Response to the AP: Final Response = (C STA , , ID STA, TS STA-first , HMAC STA ).

[0166] 9. The AP performs local response verification After the AP receives the Final Response sent by the STA, it first verifies the STA identifier ID STA and the timestamp TS STA-first to ensure consistency with what was previously retained (used to verify the legitimacy of the STA and distinguish different STAs), and then the AP uses its private key SK AP to decrypt the ciphertext C sent by the STA STA to extract the random number r generated by the STA STA . Finally, the AP verifies the HMAC of the STA to ensure the integrity of the message and the authenticity of the source.

[0167] r STA =D(SK AP , C STA ), where D is the decryption operation and SK AP is the AP private key.

[0168] The AP verifies the HMAC of the STA: , where K STA is the STA key.

[0169] If the HMAC AP-check-STA =HMAC STA , the preliminary verification of the STA's identity is successful.

[0170] The AP verifies the response code : Verify the timestamp in to ensure that the response code is generated within the valid time, and at the same time verify the validity of the identifier ID STA to ensure that the response code is generated by a specific STA, and through the two - aspect verification, ensure the integrity and freshness of the message, and prevent replay attacks.

[0171] , If , the authentication of the STA is successful, and the STA is allowed to access temporarily; otherwise, access is denied. This process goes through two responses from the STA and is finally completed by the AP for the local identity authentication process, ensuring the security of the STA's identity.

[0172] The remote identity authentication process may include the following steps 1 - 9.

[0173] 1. The AP sends a remote authentication request (i.e., a remote authentication request) to the AS. The AP generates a remote authentication request Forward, which contains a new timestamp TS AP-second , HMAC AP , the ciphertext C of the STA STA , the STA identifier ID STA , the second timestamp TS generated by the STA STA-second , the HMAC generated by the STA STA , the HMAC generated by the AP AP , the AP identifier ID AP , the random number r generated by the AP AP-new and the second timestamp TS AP-second and other information: Forward = (C STA , ID STA , TS STA-second , HMAC STA , HMAC AP , ID AP , r AP-new , TS AP-second ), where .

[0174] The AP sends the remote authentication request Forward to the AS.

[0175] 2. The AS generates a new random number and timestamp The AS generates a random number r AS , generates a timestamp TS AS .

[0176] 3. The AS verifies the identity of the STA Verify the legitimacy of HMACSTA: The AS uses the STA public key to decrypt the ciphertext C of the STA STA to extract the random number r generated by the STA STA ; then, the AS uses the STA key K STA to recalculate the local verification HMAC AS-check-STA , and compare it with the HMAC sent by the STA STA : r STA = D(PK STA , C STA ), , where F HMAC is the HMAC algorithm, representing the hash-based message authentication code; K STA is the STA key, used to generate the HMAC.

[0177] If HMAC AS-check-STA = HMAC STA and the timestamp TS STA-second is valid, the authentication of the STA is successful.

[0178] 4. The AS authenticates the identity of the AP Verify the legality of HMAC AP : The AS uses the random number r AP-new generated by the AP and the second timestamp TS AP-second to recalculate the local verification HMAC AS-check-AP : , where K AP is the AP key used to generate the HMAC.

[0179] If HMAC AS-check-AP = HMAC AP , the authentication of the AP is successful, and the AS subsequently sends an authentication message to notify the AP that the STA is allowed to access. Otherwise, the AS notifies the AP to reject the STA's access.

[0180] 5. The AS generates a new ciphertext and a new HMAC for the STA The AS generates a random number r AS , generates a timestamp TS AS , generates a new ciphertext C AS and HMAC AS-STA : C AS = E(PK STA , r AS ), , where C AS is the newly generated ciphertext, K AS is the AS key, and HMAC AS-STA is the HMAC generated by the AS for the STA.

[0181] 6. The AS generates a new ciphertext and a new HMAC for the AP: C AP = E(PK AP , r AS ), where E is the encryption operation, , where, TS AS is the timestamp generated by the AS, and HMAC AS-AP is the HMAC generated by the AS for the AP.

[0182] 7. The AS sends a secondary authentication message to the AP The secondary authentication message AS Response is as follows: AS Response=(C AS ,C AP ,HMAC AS-STA ,HMAC AS-AP ,ID STA ,TS AS , ID AP ,TS AP-second ), Among them, the secondary authentication message may be included in Figure 3 the remote authentication response shown, and the remote authentication response may further include the verification result of the AS for the AP and the verification result of the AS for the STA.

[0183] 8. The AP verifies the response from the AS The AP decrypts the verification ciphertext of the AS: r AS =D(SK AP ,C AP ), , If HMAC AP-check-AS =HMAC AS-AP , the self-identifier received by the AP is the same as ID AP , and the TS AP-second received by the AP is the same as the second timestamp information generated by it, then the signature verification of the AS is successful. The AP receives the verification result of the AS for the STA and allows the STA to access.

[0184] At the same time, the AP forwards the remote authentication response of the AS (i.e., part of the information Response1 in the secondary authentication message) to the STA: Response1 =(C AS ,HMAC AS-STA ,ID STA ,TS AS ).

[0185] 9. The STA verifies the response from the AS The STA decrypts the ciphertext of the AS: r AS =D(PK STA ,C AS ), The STA generates the AS verification HMAC STA-check-AS : , If HMAC STA-check-AS =HMAC AS-STA , and the self-identifier received by the STA is the same as ID STAIf they are consistent, the signature verification of the AS is successful, the secondary authentication process is completed, and the STA accesses the AP network.

[0186] Before the local execution terminal and the local control terminal are connected to the network, identity authentication needs to be carried out. During the identity authentication process, both the STA and the AP use digital certificates as their identity credentials, and each STA and AP needs to install the public key certificate issued by the AS. When the STA accesses the local broadband wireless network or re-associates with the local broadband wireless network, the local response authentication of the identities of both the STA and the AP and the remote authentication of the AS are required, otherwise the association is released. In the present invention, it is set that the AP sends authentication activation information to the STA to start the identity authentication process, and the identity authentication process is as Figure 3 shown.

[0187] In summary, in the present invention, the AP private key is stored in the security module. The security module uses the AP private key and the STA identifier in the initial response message corresponding to the local authentication request sent by the STA to generate a response code; the STA uses the generated response code and the STA identifier to generate a new response code, and sends the new response code and the STA identifier to the AP; the AP generates a verification response code based on the response code generated by the security module and the received STA identifier, and confirms the successful identity authentication of the STA when the new response code generated by the STA matches the verification response code. Thus, the management and update of the AP private key are centralized on the security module, reducing the management complexity of the AP device, realizing the physical isolation of the private key, and ensuring the legitimacy of the STA identity through the verification response code, realizing secure data access.

[0188] Embodiment Nineteen Figure 5 is a flowchart of a key negotiation method provided by an embodiment of the present invention, and the key negotiation method is applied to the AP. As Figure 5 shown, the key negotiation method includes: Step S501, performing identity authentication according to the identity authentication method; Step S502, forwarding the key information corresponding to the key negotiation request from the STA to the security module, so that the security module executes: generating a session key based on the second random number generated by the STA and the random number generated by the AP, generating a negotiation response code based on the session key, the second STA ciphertext in the key information and the STA identifier, and sending a response message to the AP, where the response message includes the negotiation response code and the STA identifier; Step S503, in response to receiving the response message, generating a negotiation verification code based on the session key, the second STA ciphertext and the STA identifier in the response message; and Step S504, confirming the successful key negotiation when the negotiation response code is consistent with the negotiation verification code.

[0189] For step S501, identity authentication is performed according to the identity authentication method described in each of the above embodiments, and the specific process will not be elaborated here.

[0190] For step S502, the AP generates a random number r AP_key , and the AP generates a key negotiation request (such as KeyRequest) and sends the key negotiation request to the STA: Key Request=(ID AP , r AP_key ), where ID AP is the AP identifier.

[0191] The STA sends the key information (such as Key Material) corresponding to the key negotiation request to the AP, where the key information (such as Key Material) includes the second STA ciphertext (C STA_key ) and the STA identifier (ID STA ): Key Material=(C STA_key , ID STA ).

[0192] The AP forwards the key information (such as Key Material) to the security module.

[0193] After the security module receives the key information (such as Key Material) forwarded by the AP, the security module uses a key derivation function (KDF) to derive a session key STA_key from the second random number r AP_key generated by the STA and the random number r STA_key generated by the AP: , where KDF is a key derivation function, an algorithm for generating one or more keys from the original key material, mainly to increase the strength and security of the key. KDF ensures that the generated session key has sufficient randomness and unpredictability and is suitable for subsequent encrypted communication.

[0194] The security module generates a negotiation response code S based on the session key STA , the second STA ciphertext C AP_key in the key information, and the STA identifier ID AP_key :

[0195] And, the security module sends the negotiation response code S STAWith the STA identification ID STA Included in the response message Response: Response=(S AP_key ,ID STA ).

[0196] Then, the security module sends the response message to the AP.

[0197] For step S503, the AP generates a negotiation verification code : .

[0198] For step S504, if S AP_key = S AP_key_check , the key negotiation is successful.

[0199] In this embodiment, a new session key is generated for each session to ensure the freshness of the session key and prevent replay attacks; the session key message is confirmed by encryption and decryption to ensure the consistency and validity of the session key.

[0200] In this embodiment, a new session key is generated for each session to ensure the freshness of the session key and prevent replay attacks.

[0201] Embodiment 20 Based on the above-mentioned embodiment 19, the key negotiation method also includes: sending the key negotiation request, wherein the key negotiation request includes the AP public key, so that the STA generates key material based on the second random number generated by the STA and uses the AP public key to encrypt the key material to generate the second STA ciphertext.

[0202] For step S502, the AP generates a random number r AP_key , and the AP generates a key negotiation request (such as KeyRequest) and sends the key negotiation request to the STA: Key Request=(ID AP , r AP_key , PK AP ), Where ID AP It is AP logo, PK AP It is the public key of the AP.

[0203] After receiving the key negotiation request from the AP, the STA generates a second random number r STA_key STA generates key material M based on the second random number STA , and use the AP public key PK AP Encrypt it to generate the second STA ciphertext CSTA_key : M STA =r STA_key ; C STA_key =E(PK AP , M STA ).

[0204] Embodiment 21 Based on Example 19 or Example 20, the key negotiation method also includes: using the session key to encrypt a combination of a fixed string, an AP identifier and a STA identifier in the key information to generate a key confirmation code; and sending the key confirmation message to the STA, wherein the key confirmation message includes the key confirmation code, the AP identifier and the STA identifier, so that the STA generates a key verification code based on the session key, the AP identifier and the STA identifier in the key confirmation message, and the fixed string, and confirms that the key negotiation is successful when the key confirmation code is consistent with the key verification code.

[0205] AP uses session key Encrypt the fixed string "Confirmation" to generate a key confirmation code .

[0206] , The AP sends a key confirmation message (such as Key Confirmation) to the STA, which contains the following information: Key Confirmation =( , ID AP , ID STA ), in, This is a confirmation message used to verify the success of the key negotiation between the AP and the STA and to ensure that both parties use the same session key. is the session key, and "Confirmation" is a fixed string used for confirmation.

[0207] After receiving the key confirmation message from the AP, the STA uses the session key Generate key verification code .

[0208] , if , the STA confirms that the key negotiation is successful and is ready to use the session key Carry out subsequent encrypted communication.

[0209] Embodiment 22 Based on the above nineteenth embodiment, the key information further includes a third time stamp of the AP and a third time stamp of the STA.

[0210] Accordingly, the session key is generated based on the second random number generated by the STA, the random number generated by the AP, and the third timestamp of the STA and the third timestamp of the AP in the key information, and the negotiation response code is generated based on the session key, the second STA ciphertext, the STA identifier, and the third timestamp of the STA and the third timestamp of the AP in the key information.

[0211] The response message includes the negotiation response code, the STA identifier, a third time stamp of the STA, and a third time stamp of the AP.

[0212] Generating the negotiation response code (by the security module) includes: in response to receiving the response message, generating the negotiation verification code based on the session key, the second STA ciphertext, the STA identifier in the response message, the third timestamp generated by the STA and the third timestamp of the AP.

[0213] For step S501, identity authentication is performed according to the identity authentication methods described in the above embodiments, and the specific process will not be repeated here.

[0214] For step S502, the AP generates a random number r AP_key , and the AP generates a key negotiation request (such as KeyRequest) and sends the key negotiation request to the STA: Key Request=(ID AP ,r AP_key ), Where ID AP AP ID.

[0215] The STA sends the key information (eg, Key Material) corresponding to the key negotiation request to the AP, wherein the key information (eg, Key Material) includes the second STA ciphertext (C STA_key ), STA ID STA ) and the third timestamp TS of the STA in the key information STA_key The third timestamp TS with AP AP_key : Key Material=(C STA_key ,ID STA ,TS STA_key ,TS AP_key ).

[0216] The AP forwards the key information (eg, Key Material) to the security module.

[0217] After the security module receives the key information (eg, Key Material) forwarded by the AP, the security module uses a key derivation function (KDF) to generate a second random number r from the STA. STA_key , the random number r generated by the AP AP_key , the third timestamp of the STA in the key information Third timestamp with AP The session key K is derived from session : , The security module is based on the session key K session , the second STA ciphertext C in the key information STA_key , STA ID STA , the third timestamp of the STA in the key information Third timestamp with AP , generate negotiation response code S AP_key : .

[0218] Furthermore, the security module sends the negotiation response code S AP_key , the STA identification ID STA , the third timestamp of the STA in the key information Third timestamp with AP Included in the response message Response: Response=(S AP_key ,ID STA ,TS STA_key ,TS AP_key ).

[0219] Then, the security module sends the response message to the AP.

[0220] For step S503, the AP generates a negotiation verification code : .

[0221] For step S504, if S AP_key = S AP_key_check , the key negotiation is successful.

[0222] Embodiment 23 Based on the above-mentioned embodiment 21, the key negotiation method also includes: sending the key negotiation request, wherein the key negotiation request includes the AP public key and the third timestamp of the AP, so that the STA generates key material based on the second random number generated by the STA and the third timestamp generated by the STA and encrypts the key material using the AP public key to generate the second STA ciphertext.

[0223] For step S502, the AP generates a random number r AP_key and timestamp TS AP_key , used to ensure the freshness of the message and prevent replay attacks. And the AP generates a key negotiation request (such as Key Request) and sends the key negotiation request to the STA: Key Request=(ID AP , r AP_key ,TS AP_key ,PK AP ), Where ID AP It is AP logo, PK AP It is the public key of the AP.

[0224] After receiving the key negotiation request from the AP, the STA generates a second random number r STA_key and timestamp TS STA_key STA generates key material M based on the second random number STA , and use the AP public key PK AP Encrypt it to generate the second STA ciphertext C STA_key : ; .

[0225] Embodiment 24 Based on the above-mentioned embodiment twenty-two or twenty-three, the key negotiation method also includes: using the session key to encrypt a combination of a fixed string, an AP identifier, and the STA identifier in the key information, a third timestamp generated by the STA, and a third timestamp of the AP to generate a key confirmation code; and sending a key confirmation message to the STA, wherein the key confirmation message includes the key confirmation code, the AP identifier, the STA identifier, the third timestamp generated by the STA, and the third timestamp of the AP, so that the STA generates a key verification code based on the key confirmation code, the AP identifier, the STA identifier, the third timestamp generated by the STA, the third timestamp of the AP, and the fixed string in the key confirmation message, and confirms that the key negotiation is successful when the key confirmation code is consistent with the key verification code.

[0226] AP uses session key K session Encrypt the fixed string "Confirmation" to generate the key confirmation code K confirm : , The AP sends a key confirmation message (such as Key Confirmation) to the STA, which contains the following information: Key Confirmation =( ,ID AP , ID STA ,TS AP_key , TS STA_key ), in, It is a confirmation message used to verify the success of the key negotiation between the AP and the STA and ensure that both parties use the same session key. session is the session key, and "Confirmation" is a fixed string used for confirmation.

[0227] After receiving the key confirmation message from the AP, the STA uses the session key Generate key verification code : , if , the STA confirms that the key negotiation is successful and is ready to use the session key Carry out subsequent encrypted communication.

[0228] Embodiment 25 Based on any one of the above-mentioned embodiments 19 to 24, the key information also includes a second HMAC generated by the STA.

[0229] The security module uses the STA public key to decrypt the second STA ciphertext to obtain key material; generates an HMAC for the STA based on the key material, the STA public key, and the AP identifier; and generates a session key based on the second random number generated by the STA and the random number generated by the AP when the HMAC for the STA is consistent with the second HMAC generated by the STA.

[0230] Specifically, STA uses its own public key PK STA Generates a hash-based message authentication code to ensure the integrity of the message and the authenticity of the source; the input to HMAC includes the key material M STA , timestamp TS STA_keyAnd other related information to verify that the message has not been tampered with during transmission and to ensure that the message is indeed from a legitimate STA: , Among them, F HMAC It is the HMAC algorithm, which stands for Hash-based Message Authentication Code, PK STA STA public key.

[0231] The STA sends the key material to the AP: Key Material=(C STA_key ,ID STA ,TS STA_key ,TS AP_key ,HMAC STA_key ).

[0232] The AP can then verify that the TS AP_key ,If the timestamp is consistent with the one sent by itself, the AP forwards the key information to the security module. After receiving the key information forwarded by the AP, the security module uses the STA public key to encrypt the second STA ciphertext C STA_key Perform decryption operation to obtain M STA ( ).

[0233] Further use of STA public key PK STA Recalculate the STA's HMAC value (ie, HMAC STA_key_check ).

[0234] HMAC STA_key_check = F HMAC (PK STA , M STA , ID AP ), If HMAC STA_key_check =HMAC STA_key , then use the key derivation function (KDF) to generate a random number r from STA STA_key and timestamp TS STA_key The session key K is derived from session : .

[0235] The specific description of this embodiment includes the content related to the timestamp. Of course, this embodiment is also applicable to the case where the content related to the timestamp is not included, and will not be described in detail here.

[0236] In this embodiment, a new session key is generated for each session to ensure the freshness of the session key and prevent replay attacks; the session key message is confirmed by encryption and decryption to ensure the consistency and validity of the session key.

[0237] Embodiment 26 like Figure 6 As shown in FIG. 1 , the interactive process of key negotiation between the AP, STA, and security module is described in detail below.

[0238] 1. AP sends a key negotiation request The AP generates a random number r AP_key and timestamp TS AP_key , used to ensure the freshness of messages and prevent replay attacks.

[0239] The AP generates a key negotiation request and sends it to the STA: Key Request =(ID AP ,r AP_key ,TS AP_key ,PK AP ), Where ID AP It is AP logo, PK AP It is the AP public key.

[0240] 2. STA generates key material and ciphertext After receiving the key negotiation request from the AP, the STA generates a random number r STA_key and timestamp TS STA_key STA combines these two values ​​into key material M STA , and use the AP public key PK AP Encrypt it to generate ciphertext C STA_key : Generate key material ; Generate ciphertext , Where E is the encryption operation.

[0241] 3. STA generates HMAC STA uses its own key PK STA Generates a hash-based message authentication code to ensure the integrity of the message and the authenticity of the source; the input to HMAC includes the key material M STA , timestamp TS STA_key And other related information to verify that the message has not been tampered with during transmission and to ensure that the message is indeed from a legitimate STA: , Among them, F HMAC It is the HMAC algorithm, which stands for Hash-based Message Authentication Code, PK STA STA public key.

[0242] 4. STA sends key information The STA sends the key material to the AP: Key Material=(C STA_key ,ID STA ,TS STA_key ,TS AP_key ,HMAC STA_key ).

[0243] 5. AP forwards the key information to the security module First verify TS AP_key If the timestamp in the key information is consistent with the timestamp in the key negotiation request sent by itself, the key information is forwarded to the security module: Key Material =(C STA_key ,ID STA ,TS STA_key ,TS AP_key ,HMAC STA_key ) .

[0244] 6. The security module generates session keys and response codes After receiving the key information forwarded by the AP, the security module STA_key Perform decryption operation to obtain M STA .

[0245] Further use of STA public key PK STA Recalculate the STA's HMAC value (ie, HMAC STA_key_check ).

[0246] HMAC STA_key_check = F HMAC (PK STA , M STA , ID AP ), If HMAC STA_key_check =HMAC STA_key , then use the key derivation function (KDF) to generate a random number r from STA STA_key and timestamp TS STA_key The session key is derived from : , Among them, KDF is a key derivation function, an algorithm used to generate one or more keys from the original key material, mainly to increase the strength and security of the key. KDF ensures that the generated session key has sufficient randomness and unpredictability and is suitable for subsequent encrypted communications.

[0247] The security module generates a response code S AP_key : , Where ID STA STA identifier.

[0248] The security module will respond with code S AP_key Included in the response message Response sent to AP: Response =(S AP_key ,ID STA ,TS STA_key ,TS AP_key ).

[0249] 7.AP verification response code , If S AP_key = S AP_key_check , the key negotiation is successful.

[0250] 8.AP generates key confirmation message AP uses session key K session Encrypt the fixed string "Confirmation" to generate the key confirmation code K confirm : .

[0251] The AP sends a Key Confirmation message to the STA, which contains the following information: Key Confirmation =( , ID AP , ID STA , TS AP_key , TS STA_key ), in, Used to verify the success of key negotiation between AP and STA and ensure that both parties use the same session key; "Confirmation" is a fixed string used for confirmation.

[0252] 9.STA verification key confirmation code After receiving the key confirmation message from the AP, the STA uses the session key K session Generate key verification code K confirm_check: .

[0253] if , the STA confirms that the key negotiation is successful and is ready to use the session key Carry out subsequent encrypted communication.

[0254] To ensure the long-term security of the system, the security module regularly communicates with the AS to update authentication information and session keys. The frequency of key updates can be configured according to actual needs, and is usually set to update once every 24 hours. When the security module detects a potential security threat or finds that an existing key may have been leaked, it will immediately trigger a key update to prevent security risks caused by long-term use of the same key. In addition, as long as the security module is legal, the legitimacy of the access point can be ensured, making the system more flexible and supporting switching between different access points without the need to regenerate key pairs.

[0255] After the STA and AP establish identity authentication, they will negotiate the session key. By introducing a security module to assist the AP in completing the key negotiation, the security and reliability of the key exchange will be improved. The key negotiation request is sent by the AP node first, and the generated key is confirmed during the key negotiation process. The key negotiation flow chart is as follows: Figure 4 shown.

[0256] Both the identity authentication and key negotiation processes are completed with the help of the secure media security module, which ensures the security of the system. As long as the security module is legitimate, the legitimacy of the access point can be ensured. This makes the system more flexible and can switch between different access points without regenerating key pairs.

[0257] In summary, after the STA and AP establish identity authentication, a security module is introduced to assist the AP in completing key negotiation, and a new session key is generated for each session to ensure the freshness of the session key and improve the security and reliability of key exchange.

[0258] In order to improve the robustness and flexibility of a communication system, the present invention proposes a multi-modal fusion networking communication solution, which combines the advantages of three communication methods: local broadband communication (taking WAPI as an example), local narrowband communication (taking LoRa as an example), and remote broadband communication (taking 4G as an example, including but not limited to 4G and 5G). In order to select the optimal routing path in different application scenarios, the present invention is based on the fuzzy analytic hierarchy process (FAHP) algorithm, comprehensively considering factors such as bandwidth (Bandwidth, B), delay (Delay, D), packet loss rate (Packet Loss Rate, P), security (Security, S), and network load (NetworkLoad, L). By constructing a fuzzy consistent matrix and using a scale method of 0.1 to 0.9 to evaluate the indicators, the optimal routing path can be selected in different application scenarios.

[0259] The wireless communication network of the multi-modal communication system described in the present invention includes communication methods such as local broadband communication, local narrowband communication, and remote broadband communication. Among them, local broadband communication, with its high bandwidth and encryption capabilities, is suitable for scenarios that require a large amount of data transmission, such as transmitting large-granularity data such as high-definition videos, images, and languages, to ensure local transmission and stable communication of signals; local narrowband communication, due to its low delay, strong anti-interference ability, and long-distance transmission ability, is suitable for low-power, long-distance data transmission, such as small-granularity data such as monitoring data and local control instructions. Remote broadband communication, including but not limited to 4G / 5G communication, provides medium bandwidth and is suitable for mobility and wide-area coverage requirements, such as transmitting remote control instructions, and can also be used as a backup communication method for the local remote control platform to urgently control operating equipment.

[0260] Embodiment Twenty-Seven Figure 7 is a flowchart of a dynamic routing switching method provided by an embodiment of the present invention. As Figure 7 shown, the switching method includes: step S701, performing key negotiation according to the key negotiation method; step S702, determining multiple weights corresponding to multiple communication indicators according to the fuzzy consistent matrix; step S703, determining the index weighted value under each single communication mode and the index weighted value under each combined communication mode according to the multiple index values corresponding to the multiple communication indicators and the multiple weights under a single communication mode in multiple communication modes; and step S704, adaptively selecting the single communication mode or the combined communication mode corresponding to the maximum index weighted value according to a specific scenario.

[0261] The routing adaptive switching based on the fuzzy analytic hierarchy process in this embodiment can comprehensively consider multiple factors affecting routing selection (such as bandwidth, delay, packet loss rate, security, and network load), ensuring that the selected routing is optimal in multiple aspects.

[0262] Example Twenty-Eight For step S702, the determining of the multiple weights corresponding to the multiple communication metrics includes: converting the fuzzy consistent matrix to obtain a fuzzy complementary judgment matrix; performing normalization processing on the fuzzy complementary judgment matrix to obtain a normalized matrix; determining, according to the normalized matrix, an eigenvector corresponding to the maximum eigenvalue; and determining the multiple elements corresponding to the multiple communication metrics in the eigenvector as the multiple weights corresponding to the multiple communication metrics.

[0263] For step S701, key negotiation can be performed according to any one of the above-mentioned Examples Nineteen to Twenty-Six, which will not be elaborated herein.

[0264] Before executing step S702, a fuzzy consistent matrix A can be constructed: The fuzzy consistent matrix A is an n×m matrix, where n is the number of criteria and m is the number of solutions.

[0265] , where the matrix element a ij represents the relative importance of criterion i relative to criterion j, with a value range of [0.1, 0.9], and satisfies a ij + a ji = 1, and a ii = 0.5 (indicating that the comparison between the same criteria is equal).

[0266] For the weight calculation in step S702: According to the fuzzy consistent matrix A, the eigenvector method is used to calculate the weights of each criterion. The specific steps are as follows: ① Normalization processing: Normalize the fuzzy consistent matrix A into a fuzzy complementary judgment matrix such that the sum of the elements in each row is 1.

[0267] , where .

[0268] Further normalize each column of the fuzzy complementary judgment matrix so that the sum of the elements in each column is equal to 1, obtaining the final normalized matrix C, further eliminating the deviation and ensuring the symmetry and consistency of the matrix: .

[0269] ② Calculate the eigenvector: Solve the maximum eigenvalue of the normalized matrix C and its corresponding eigenvector w. The calculation formula for the eigenvector w is: ; The eigenvector w can be calculated by the following formula: , Solve for the eigenvector corresponding to the largest eigenvalue of the normalization matrix C .

[0270] where is the largest eigenvalue, w is the eigenvector (w i is the element of the eigenvector of the i-th criterion), k is an index used to identify one of multiple possible solutions. For example, if k = 1, then "solution k" refers to the first solution, which might be WAPI; if k = 2, then "solution k" might refer to LoRa, and so on.

[0271] ③ Normalized eigenvector: To ensure that the sum of the weights is 1, the eigenvector w needs to be normalized to obtain the weight vector W for each criterion: , where , where represents the normalized weight of the i-th criterion, and n is the number of criteria.

[0272] Suppose that based on experimental measurements, the bandwidth (Bandwidth, B), delay (Delay, D), packet loss rate (Packet Loss Rate, P), security (Security, S), and network load (Network Load, L) of three communication methods, namely local broadband communication (taking WAPI as an example), local narrowband communication (taking LoRa as an example), and remote broadband communication (taking 4G as an example, including but not limited to 4G, 5G), are as follows: Bandwidth (B): WAPI = 300 Mbps, LoRa = 0.4 Mbps, 4G = 60 Mbps; Delay (D): WAPI = 10 ms, LoRa = 80 ms, 4G = 20 ms; Packet loss rate (P): WAPI = 0.2%, LoRa = 0.1%, 4G = 0.3%; Security (S): WAPI = 90%, LoRa = 70%, 4G = 80%; Network load (L): WAPI = 50%, LoRa = 20%, 4G = 40%; That is, the measurement table is presented as Table 1.

[0273] Table 1 Measurement Table

[0274] First, assume that according to experience and actual requirements, the following fuzzy consistent matrix A is constructed, as shown in Table 2 below.

[0275] Table 2 Fuzzy consistent matrix A

[0276] Convert the fuzzy consistent matrix A into a fuzzy complementary judgment matrix , and further normalize it into matrix C. The normalized matrix C is shown in Table 3 below.

[0277] Table 3 Matrix C

[0278] Solve for the maximum eigenvalue of the normalized matrix C according to the formula and its corresponding eigenvector w. The calculated eigenvector w is: w = [0.300, 0.200, 0.200, 0.200, 0.100], Normalize the eigenvector w to obtain the final weight vector W: W = [0.300, 0.200, 0.200, 0.200, 0.100].

[0279] Example 29 For step S703, the determination of the index weighted values in each single communication mode and the index weighted values in each combined communication mode includes: determining the multiple index values corresponding to the multiple communication indicators in each combined communication mode according to the multiple index values corresponding to the multiple communication indicators in the single communication mode among the multiple communication modes; determining the index weighted values in each single communication mode according to the multiple index values corresponding to the multiple communication indicators in the single communication mode among the multiple communication modes and the multiple weights corresponding to the multiple communication indicators; and determining the index weighted values in each combined communication mode according to the multiple index values corresponding to the multiple communication indicators in each combined communication mode and the multiple weights corresponding to the multiple communication indicators.

[0280] Standardized performance scoring: Before calculating the comprehensive evaluation value, it is necessary to standardize the original scores of each scheme on different criteria, and convert the indicators with different dimensions (such as bandwidth, delay, etc.) to the same dimension for comparison, that is, it is necessary to standardize the original scores of each scheme. The standardization formula is: , where x kj is the original score of the k-th scheme on the j-th criterion, min(x j ) and max(xj ) are the minimum and maximum values of the j-th criterion among all the scenarios, respectively, and P kj is the normalized score of the k-th scenario on the j-th criterion, and its value range is [0, 1].

[0281] Calculation of the comprehensive evaluation value: The comprehensive evaluation value V k is obtained by multiplying the weight vector W by the normalized performance score. The specific formula for the comprehensive evaluation value is: , where V k is the comprehensive evaluation value of the k-th scenario, w i is the weight of the i-th criterion, and P ik is the normalized score of the k-th scenario on the i-th criterion. Finally, the scenario with the highest comprehensive evaluation value is selected as the optimal routing path.

[0282] Calculate the comprehensive score V of each scenario according to the weight vector W and the performance scores of each scenario on each criterion k .

[0283] ① Single communication mode For single communication modes (WAPI, LoRa, 4G), normalize the performance scores of each communication mode to the [0, 1] interval. This method is simple, intuitive, and easy to implement.

[0284] According to the normalization formula, the normalized performance scores are shown in Table 4 below.

[0285] Table 4 Normalized performance scores

[0286] Calculate the comprehensive score of each scenario: V WAPI = 0.300 × 1.000 + 0.200 × 0.667 + 0.200 × 0.667 + 0.200 × 1.000 + 0.100 × 0.667 = 0.867; V LoRa = 0.300 × 0.000 + 0.200 × 0.000 + 0.200 × 1.000 + 0.200 × 0.500 + 0.100 × 0.000 = 0.300; V 4G = 0.300 × 0.200 + 0.200 × 0.333 + 0.200 × 0.333 + 0.200 × 0.833 + 0.100 × 0.333 = 0.467.

[0287] ② Combined communication mode For combined communication methods (WAPI + LoRa, WAPI + 4G, LoRa + 4G, WAPI + LoRa + 4G), it can be assumed that the performance score after combination is the weighted average of each single communication method. To more accurately reflect the performance of the combined communication method, the following method is adopted: the bandwidth (B) takes the maximum value, the delay (D) takes the minimum value, the packet loss rate (P) takes the minimum value, the security (S) takes the maximum value, and the network load (L) takes the minimum value. Assume that the performance score after combination is shown in Table 5 below.

[0288] Table 5 Performance Score after Combination

[0289] The performance scores standardized according to the formula are shown in Table 6 below.

[0290] Table 6 Standardized Performance Scores

[0291] Calculate the comprehensive score of each combination scheme: V WAPI+LoRa = 0.300×1.000 + 0.200×0.667 + 0.200×1.000 + 0.200×1.000 + 0.100×0.000 = 0.933; V WAPI+4G = 0.300×1.000 + 0.200×0.667 + 0.200×0.667 + 0.200×1.000 + 0.100×0.333 = 0.867; V LoRa+4G = 0.300×0.200 + 0.200×0.333 + 0.200×1.000 + 0.200×0.833 + 0.100×0.000 = 0.533; V WAPI+LoRa+4G = 0.300×1.000 + 0.200×0.667 + 0.200×1.000 + 0.200×1.000 + 0.100×0.000 = 0.933.

[0292] It can be seen from the above calculation results that: for the single communication method, the comprehensive score of WAPI is the highest at 0.867; for the combined communication methods, the comprehensive scores of WAPI + LoRa and WAPI + LoRa + 4G are both 0.933, which are the optimal choices.

[0293] Therefore, in a specific scenario, if a single communication method is selected, WAPI is the optimal choice; if a combined communication method is selected, both WAPI + LoRa and WAPI + LoRa + 4G are the optimal choices.

[0294] The above-described Example 27 to Example 29 can be executed by the AP or the STA. For example, when the AP needs to send information to the STA, the AP executes the above-described dynamic routing switching process; when the STA needs to send information to the AP, the STA executes the above-described dynamic routing switching process.

[0295] The multi-modal communication system described in the present invention has the ability of multi-protocol communication conversion, and can handle the conversion and adaptation between local broadband communication, local narrowband communication, and remote broadband communication protocols, and support the interconnection and data exchange of the three.

[0296] In summary, the intelligent routing selection algorithm based on the fuzzy analytic hierarchy process comprehensively considers various factors such as bandwidth, delay, packet loss rate, security, and network load, and dynamically and adaptively switches the route.

[0297] Aiming at the special communication requirements of the remote control platform and the operating equipment in the complex electromagnetic environment, the present invention proposes a method, device, and system for secure access and fusion networking of multi-modal communication, which ensure the safe, orderly, and efficient transmission of videos, images, and interactive instructions during the operation of the operating equipment. The method, device, and system for secure access and fusion networking of multi-modal communication proposed by the present invention adopt a communication method of fusing local broadband, local narrowband, and remote broadband to meet the requirements of various application scenarios of the distribution network, improve work efficiency, and reduce input costs; combined with the adopted security module, it ensures the legitimacy of the remote control platform and can also be switched between different control platforms, making the system more flexible.

[0298] Example 30 The multi-modal communication system proposed in this embodiment can execute the following four processes: establishing a connection, identity authentication, key negotiation, and fusion communication, as Figure 8 shown.

[0299] Each of the above embodiments can be applied to the Figure 2 multi-modal communication system shown.

[0300] Example 31 An embodiment of the present invention provides an AP, and the AP includes: an execution device for executing the above-described identity authentication method, the above-described key negotiation method, or the switching method of the dynamic route.

[0301] Example 32 An embodiment of the present invention provides an STA, and the STA includes: an execution device for executing the above-described identity authentication method or the switching method of the dynamic route.

[0302] Example 33 An embodiment of the present invention provides an identity authentication system, which is applied to an AP. The identity authentication system includes: a first forwarding device, configured to forward an initial response message corresponding to a local authentication request from an STA to a security module; a first receiving device, configured to receive a first response code generated by the security module based on an AP private key and an STA identifier in the initial response message, where the AP private key is stored in the security module; a second forwarding device, configured to forward the first response code to the STA, so that the STA generates a second response code based on the first response code and the STA identifier and sends a final response message, where the final response message includes the second response code and the STA identifier; a second receiving device, configured to receive the final response message; a first generating device, configured to generate a verification response code based on the first response code and the STA identifier in the final response message; and a determining device, configured to determine that the identity authentication of the STA is successful when the second response code is consistent with the verification response code.

[0303] Optionally, the final response message further includes a first STA ciphertext and a first HMAC generated by the STA.

[0304] Correspondingly, the identity authentication system further includes: a second generating device, configured to generate a local verification HMAC based on the AP private key, the first STA ciphertext in the final response message, and an AP identifier; and a first confirmation device, configured to confirm whether the local verification HMAC is consistent with the first HMAC generated by the STA in the final response message.

[0305] The step of generating the verification response code is executed when the local verification HMAC is consistent with the first HMAC generated by the STA in the final response message.

[0306] Optionally, the identity authentication system further includes: a third receiving device, configured to receive the initial response message from the STA, where the initial response message includes an AP identifier, an STA identifier, a first STA ciphertext, and a first HMAC generated by the STA; and a first verification device, configured to verify whether the AP identifier in the initial response message is consistent with the AP identifier in the local authentication request.

[0307] Correspondingly, the step of forwarding the initial response message corresponding to the local authentication request from the STA to the security module is executed when the AP identifier in the initial response message is consistent with the AP identifier in the local authentication request.

[0308] Optionally, while or after forwarding an initial response message corresponding to a local authentication request from the STA to the security module, the authentication system further includes: a retention device for retaining the STA identifier in the initial response message; and a second verification device for verifying whether the STA identifier in the final response message is consistent with the STA identifier in the initial response message.

[0309] The step of generating the local verification HMAC is performed when the STA identifier in the final response message is consistent with the STA identifier in the initial response message.

[0310] Optionally, the authentication system further includes: a first sending device for sending the local authentication request, so that the STA generates a first HMAC based on the AP identifier in the local authentication request and a first random number generated by the STA, and the STA sends the initial response message, where the initial response message includes the first HMAC generated by the STA, the local authentication request further includes an AP public key, and the first STA ciphertext is generated based on the AP public key and the first random number generated by the STA.

[0311] Correspondingly, the second generating device includes: a decoding unit for decrypting the first STA ciphertext in the final response message based on the AP private key to obtain a random number; and a first generating unit for generating the local verification HMAC based on the obtained random number and the AP identifier in the final response message.

[0312] Optionally, when the security module generates the first response code based on the AP private key, the first STA ciphertext, the STA identifier, the first timestamp of the AP, and the first timestamp of the STA in the initial response message, the second response code is generated by the STA based on the first response code, the STA identifier locally stored by the STA, and the second timestamp of the STA.

[0313] Correspondingly, the first generating device includes: a first confirmation unit for confirming whether the second timestamp of the STA in the second response code is within a first preset time range; and a second generating unit for generating the verification response code based on the first response code, the STA identifier, and the second timestamp of the STA in the final response message when the second timestamp is within the first preset time range.

[0314] Optionally, the sending device is used to send the local authentication request, where the local authentication request includes an AP identifier, an AP public key, and a first timestamp of the AP, so that the STA generates the first HMAC based on the STA key, a first random number generated by the STA, the AP identifier in the local authentication request, and the first timestamp of the AP, and sends the initial response message.

[0315] Correspondingly, the first forwarding device includes: a second confirmation unit, configured to confirm whether the first timestamp of the STA is within a second preset time range when the AP identifier and the first timestamp of the AP in the initial response message are respectively consistent with the AP identifier and the first timestamp of the AP in the local authentication request; and a forwarding unit, configured to, when the first timestamp of the STA is within the second preset time range, retain the first timestamp of the STA and the STA identifier in the initial response message, and forward the initial response message and the first timestamp of the AP to the security module, so that the security module generates a first response code based on the AP private key, the first STA ciphertext in the initial response message, the first timestamp of the STA, the STA identifier, and the first timestamp of the AP, and sends the first response code to the AP.

[0316] Optionally, the identity authentication system further includes: a second sending device, configured to send a remote authentication request to the AS, where the remote authentication request includes: a first STA ciphertext, a STA identifier, a first HMAC generated by the STA, and an AP identifier, so that the AS generates a remote verification HMAC based on the STA public key and the first STA ciphertext and the AP identifier in the remote authentication request, and the AS confirms that the identity authentication of the STA is successful when the remote verification HMAC is consistent with the first HMAC generated by the STA.

[0317] Optionally, the identity authentication system further includes: a second sending device, configured to send a remote authentication request to the AS, where the remote authentication request includes: a first STA ciphertext, a STA identifier, a first HMAC generated by the STA, an AP identifier, and a second timestamp of the STA, so that the AS generates a remote verification HMAC based on the STA public key and the first STA ciphertext and the AP identifier in the remote authentication request, and confirms that the identity authentication of the STA is successful when the remote verification HMAC is consistent with the first HMAC generated by the STA and the second timestamp of the STA is within a first preset time range.

[0318] Optionally, the identity authentication system further includes: a fourth receiving device, configured to receive a secondary authentication message from the AS, where the secondary authentication message includes: a first AP ciphertext, an AP identifier, an HMAC about the AP generated by the AS; a decryption device, configured to decrypt the first AP ciphertext based on the AP private key to obtain an AS random number; a third generating device, configured to generate a first AS verification HMAC based on the AS random number and the AP identifier in the secondary authentication message; a second confirmation device, configured to confirm that the signature verification of the AS is successful when the first AS verification HMAC is consistent with the HMAC about the AP and the AP identifier in the secondary authentication message is consistent with the AP identifier locally stored in the AP.

[0319] Optionally, the identity authentication system further includes: a second sending device, configured to send a remote authentication request to the AS, where the remote authentication request includes: an STA identifier, an HMAC generated by the AP, a random number generated by the AP, a second timestamp of the AP, so that the AS generates a remote verification HMAC based on the STA identifier and the second timestamp of the AP in the remote authentication request, and the AS confirms that the identity authentication of the AP is successful when the remote verification HMAC is consistent with the HMAC generated by the AP.

[0320] Optionally, the identity authentication system further includes: a fourth receiving device, configured to receive a secondary authentication message from the AS, where the secondary authentication message includes: a first AP ciphertext, an AP identifier, an HMAC about the AP generated by the AS, an AS timestamp, a second timestamp of the AP; a decryption device, configured to decrypt the first AP ciphertext based on the AP private key to obtain an AS random number; a third generating device, configured to generate a first AS verification HMAC based on the AS random number, the AP identifier, and the AS timestamp; and a second confirmation device, configured to confirm that the signature verification of the AS is successful when the first AS verification HMAC is consistent with the HMAC about the AP, the AP identifier in the secondary authentication message is consistent with the AP identifier locally stored in the AP, and the second timestamp of the AP in the secondary authentication message is consistent with the second timestamp of the AP in the remote authentication request.

[0321] Embodiment Thirty-Four An embodiment of the present invention provides an identity authentication system, which is applied to an STA. The identity authentication system includes: a first sending device, configured to send an initial response message corresponding to a local authentication request to an AP, so that the AP forwards the initial response message to a security module. The initial response message includes an STA identifier, and the security module generates a first response code based on an AP private key and the STA identifier in the initial response message and sends the first response code to the AP, where the AP private key is stored in the security module; a first receiving device, configured to receive the first response code forwarded by the AP; a first generating device, configured to generate a second response code based on the first response code and the STA identifier locally stored by the STA; and a second sending device, configured to send a final response message to the AP, so that the AP generates a verification response code based on the first response code and the STA identifier in the final response message and determines that the identity authentication of the STA is successful when the second response code in the final response message is consistent with the verification response code.

[0322] Optionally, the final response message further includes a first STA ciphertext and a first HMAC generated by the STA. The AP performs: generating a local verification HMAC based on the AP private key, the first STA ciphertext in the final response message, and an AP identifier; and confirming whether the local verification HMAC is consistent with the first HMAC generated by the STA in the final response message.

[0323] Accordingly, the step of generating the verification response code is performed when the local verification HMAC is consistent with the first HMAC generated by the STA in the final response message.

[0324] Optionally, the identity authentication system further includes: a second receiving device, configured to receive the local authentication request; a third sending device, configured to generate a first HMAC based on the AP identifier in the local authentication request and a first random number generated by the STA, and send the initial response message, where the initial response message includes the first HMAC generated by the STA, and the local authentication request includes an AP public key; and a second generating device, configured to generate the first STA ciphertext based on the AP public key and the first random number generated by the STA.

[0325] Accordingly, generating the local verification HMAC based on the AP private key, the first STA ciphertext in the final response message, and the AP identifier includes: decrypting the first STA ciphertext in the final response message based on the AP private key to obtain a random number; and generating the local verification HMAC based on the obtained random number and the AP identifier in the final response message.

[0326] Optionally, when the security module generates the first response code based on the AP private key, the first STA ciphertext, the STA identifier, the first timestamp of the AP, and the first timestamp of the STA in the initial response message, the first generating device generates a second response code based on the first response code and the STA identifier locally stored by the STA, including: generating the second response code based on the first response code, the STA identifier locally stored by the STA, and the second timestamp of the STA.

[0327] Correspondingly, generating the verification response code based on the first response code and the STA identifier in the final response message includes: confirming whether the second timestamp of the STA in the second response code is within a first preset time range; and when the second timestamp is within the first preset time range, generating the verification response code based on the first response code, the STA identifier, and the second timestamp of the STA in the final response message.

[0328] Optionally, the identity authentication system further includes: a second receiving device, configured to receive the local authentication request, where the local authentication request includes the AP identifier, the AP public key, and the first timestamp of the AP; and a third sending device, configured to generate a first HMAC based on the STA key, the first random number generated by the STA in the local authentication request, the AP identifier, and the first timestamp of the AP, and send the initial response message, where the initial response message includes the first HMAC generated by the STA.

[0329] Correspondingly, forwarding the initial response message to the security module includes: when the AP identifier and the first timestamp of the AP in the initial response message are respectively consistent with the AP identifier and the first timestamp of the AP in the local authentication request, confirming whether the first timestamp of the STA is within a second preset time range; and when the first timestamp of the STA is within the second preset time range, retaining the first timestamp of the STA and the STA identifier in the initial response message, and forwarding the initial response message and the first timestamp of the AP to the security module, so that the security module generates a first response code based on the AP private key, the first STA ciphertext, the first timestamp of the STA, the STA identifier, and the first timestamp of the AP in the initial response message, and sends the first response code to the AP.

[0330] Optionally, the identity authentication system further includes: a third receiving device, configured to receive a secondary authentication message forwarded by an AP, where the secondary authentication message includes: an AS ciphertext, an STA identifier, and an HMAC about the STA generated by the AS; a decryption device, configured to decrypt the AS ciphertext based on the STA public key to obtain an AS random number; a third generating device, configured to generate a second AS verification HMAC based on the AS random number and the STA identifier in the secondary authentication message; and a confirmation device, configured to confirm that the signature verification of the AS is successful when the second AS verification HMAC is consistent with the HMAC about the STA generated by the AS and the STA identifier in the secondary authentication message is consistent with the STA identifier locally stored by the STA.

[0331] Optionally, the identity authentication system further includes: a third receiving device, configured to receive a secondary authentication message forwarded by an AP, where the secondary authentication message includes: an AS ciphertext, an STA identifier, an HMAC about the STA generated by the AS, and an AS timestamp; a decryption device, configured to decrypt the AS ciphertext based on the STA public key to obtain an AS random number; a third generating device, configured to generate a second AS verification HMAC based on the AS random number, the STA identifier in the secondary authentication message, and the AS timestamp; and a confirmation device, configured to confirm that the signature verification of the AS is successful when the second AS verification HMAC is consistent with the HMAC about the STA generated by the AS and the STA identifier in the secondary authentication message is consistent with the STA identifier locally stored by the STA.

[0332] Embodiment 35 An embodiment of the present invention provides a key negotiation system applied to an AP. The key negotiation system includes: the identity authentication system as described above, configured to perform identity authentication; a forwarding device, configured to forward key information corresponding to a key negotiation request from an STA to a security module, so that the security module executes: generating a session key based on a second random number generated by the STA and a random number generated by the AP, generating a negotiation response code based on the session key, a second STA ciphertext in the key information, and the STA identifier, and sending a response message to the AP, where the response message includes the negotiation response code and the STA identifier; a generating device, configured to generate a negotiation verification code based on the session key, the second STA ciphertext, and the STA identifier in the response message in response to receiving the response message; and a confirmation device, configured to confirm that the key negotiation is successful when the negotiation response code is consistent with the negotiation verification code.

[0333] Optionally, the key negotiation system further includes: a first sending device, configured to send the key negotiation request, where the key negotiation request includes an AP public key, so that the STA generates key material based on a second random number generated by the STA and encrypts the key material using the AP public key to generate the second STA ciphertext.

[0334] Optionally, the key negotiation system further includes: an encryption device, configured to encrypt a combination formed by a fixed string, an AP identifier, and an STA identifier in the key information using the session key to generate a key confirmation code; and a second sending device, configured to send the key confirmation message to the STA, where the key confirmation message includes the key confirmation code, the AP identifier, and the STA identifier, so that the STA generates a key verification code based on the session key, the AP identifier and the STA identifier in the key confirmation message, and the fixed string, and confirms that the key negotiation is successful when the key confirmation code is consistent with the key verification code.

[0335] Optionally, the key information further includes a third timestamp of the AP and a third timestamp of the STA; the session key is generated based on a second random number generated by the STA, a random number generated by the AP, and the third timestamp of the STA and the third timestamp of the AP in the key information, and the negotiation response code is generated based on the session key, the second STA ciphertext, the STA identifier, and the third timestamp of the STA and the third timestamp of the AP in the key information; the response message includes the negotiation response code, the STA identifier, the third timestamp of the STA, and the third timestamp of the AP.

[0336] Correspondingly, the generating of the negotiation response code includes: in response to receiving the response message, generating the negotiation verification code based on the session key, the second STA ciphertext, the STA identifier in the response message, the third timestamp generated by the STA, and the third timestamp of the AP.

[0337] Optionally, the key negotiation system further includes: a first sending device, configured to send the key negotiation request, where the key negotiation request includes an AP public key and a third timestamp of the AP, so that the STA generates key material based on a second random number generated by the STA and a third timestamp generated by the STA and encrypts the key material using the AP public key to generate the second STA ciphertext.

[0338] Optionally, the key negotiation system further includes: an encryption device, configured to encrypt a combination formed by a fixed string, an AP identifier, and an STA identifier, a third timestamp generated by the STA, and a third timestamp of the AP in the key information by using the session key to generate a key confirmation code; and a second sending device, configured to send a key confirmation message to the STA, where the key confirmation message includes the key confirmation code, the AP identifier, the STA identifier, the third timestamp generated by the STA, and the third timestamp of the AP, so that the STA generates a key verification code based on the key confirmation code, the AP identifier, the STA identifier, the third timestamp generated by the STA, the third timestamp of the AP, and the fixed string, and confirms that the key negotiation is successful when the key confirmation code is consistent with the key verification code.

[0339] Optionally, the key information further includes a second HMAC generated by the STA, and the security module performs: decrypting the second STA ciphertext by using the STA public key to obtain key material; generating an HMAC for the STA based on the key material, the STA public key, and the AP identifier; and generating a session key based on the second random number generated by the STA and the random number generated by the AP when the HMAC for the STA is consistent with the second HMAC generated by the STA.

[0340] Embodiment Thirty-Six An embodiment of the present invention provides a dynamic routing switching system, where the switching system includes: the key negotiation system as described above, configured to perform key negotiation; a first determining device, configured to determine a plurality of weights corresponding to a plurality of communication metrics according to a fuzzy consensus matrix; a second determining device, configured to determine an index weighted value in each single communication mode and an index weighted value in each combined communication mode according to a plurality of index values corresponding to the plurality of communication metrics and the plurality of weights in a single communication mode among a plurality of communication modes; and a selection device, configured to adaptively select a single communication mode or a combined communication mode corresponding to the maximum index weighted value according to a specific scenario.

[0341] Optionally, the second determining device includes: a first determining unit configured to determine multiple index values corresponding to the multiple communication metrics in each combined communication mode according to multiple index values corresponding to the multiple communication metrics in a single communication mode among multiple communication modes; a second determining unit configured to determine the weighted index value in each single communication mode according to multiple index values corresponding to the multiple communication metrics in a single communication mode among multiple communication modes and multiple weights corresponding to the multiple communication metrics; and a third determining unit configured to determine the weighted index value in each combined communication mode according to multiple index values corresponding to the multiple communication metrics in each combined communication mode and multiple weights corresponding to the multiple communication metrics.

[0342] Optionally, the third determining unit for determining multiple weights corresponding to multiple communication metrics includes: converting the fuzzy consistent matrix to obtain a fuzzy complementary judgment matrix; performing normalization processing on the fuzzy complementary judgment matrix to obtain a normalized matrix; determining an eigenvector corresponding to the maximum eigenvalue according to the normalized matrix; and determining multiple elements corresponding to the multiple communication metrics in the eigenvector as multiple weights corresponding to the multiple communication metrics.

[0343] Embodiment 37 An embodiment of the present invention provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, it implements the identity authentication method, the key negotiation method or the dynamic routing switching method described above.

[0344] The preferred embodiments of the present invention have been described in detail above in conjunction with the accompanying drawings. However, the present invention is not limited to the specific details in the above embodiments. Within the scope of the technical concept of the present invention, various simple modifications can be made to the technical solutions of the present invention, and these simple modifications all fall within the protection scope of the present invention.

[0345] In addition, it should be noted that, in the above specific embodiments, the various specific technical features described can be combined in any suitable manner without conflict. To avoid unnecessary repetition, the present invention does not separately describe various possible combination manners.

[0346] Those skilled in the art can understand that all or part of the steps in implementing the methods of the above embodiments can be completed by instructing relevant hardware through a program. This program is stored in a storage medium, including several instructions to enable a single-chip microcomputer, a chip, or a processor to execute all or part of the steps of the methods described in various embodiments of the present application. The aforementioned storage medium includes: various media that can store program codes, such as USB flash drives, mobile hard disks, read-only memories (ROM, Read-Only Memory), random access memories (RAM, Random Access Memory), magnetic disks, or optical discs.

[0347] Those skilled in the art should understand that the embodiments of the present application can be provided as a method, a system, or a computer program product. Therefore, the present application can adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present application can adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk memories, CD-ROMs, optical memories, etc.) containing computer-usable program codes.

[0348] The present application is described with reference to the flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each flow and / or block in the flowchart and / or block diagram, as well as the combination of flows and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing devices to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing devices generate means for implementing the functions specified in Figure 1 one flow or multiple flows and / or blocks Figure 1 one block or multiple blocks.

[0349] In addition, any combination can be made among various different embodiments of the present invention as long as it does not violate the idea of the present invention, and it should also be regarded as the content disclosed by the present invention.

Claims

1. An identity authentication method, characterized in that, Applied to an AP, the identity authentication method includes: Forwarding an initial response message corresponding to a local authentication request from the STA to the security module; Receiving a first response code generated by the security module based on the AP private key and the STA identifier in the initial response message, wherein the AP private key is stored in the security module; Forwarding the first response code to the STA, so that the STA generates a second response code based on the first response code and the STA identifier and sends a final response message, wherein the final response message includes the second response code and the STA identifier; Receiving the final response message; Generating a verification response code based on the first response code and the STA identifier in the final response message; and Determining that the identity authentication of the STA is successful when the second response code is consistent with the verification response code.

2. The identity authentication method according to claim 1, wherein The final response message further includes a first STA ciphertext and a first HMAC generated by the STA, The identity authentication method further includes: Generating a local verification HMAC based on the AP private key, the first STA ciphertext in the final response message, and the AP identifier; and Confirming whether the local verification HMAC is consistent with the first HMAC generated by the STA in the final response message, The step of generating the verification response code is executed when the local verification HMAC is consistent with the first HMAC generated by the STA in the final response message.

3. The identity authentication method according to claim 2, wherein The identity authentication method further includes: Receiving the initial response message from the STA, wherein the initial response message includes an AP identifier, an STA identifier, a first STA ciphertext, and a first HMAC generated by the STA; and Verifying whether the AP identifier in the initial response message is consistent with the AP identifier in the local authentication request, The step of forwarding the initial response message corresponding to the local authentication request from the STA to the security module is executed when the AP identifier in the initial response message is consistent with the AP identifier in the local authentication request.

4. The identity authentication method according to claim 2, wherein Simultaneously with or after forwarding the initial response message corresponding to the local authentication request from the STA to the security module, the identity authentication method further includes: Retaining the STA identifier in the initial response message; Verifying whether the STA identifier in the final response message is consistent with the STA identifier in the initial response message, The step of generating the local verification HMAC is executed when the STA identifier in the final response message is consistent with the STA identifier in the initial response message.

5. The identity authentication method according to claim 2, wherein The identity authentication method further includes: Sending the local authentication request, so that the STA generates a first HMAC based on the AP identifier in the local authentication request and a first random number generated by the STA, and the STA sends the initial response message, wherein the initial response message includes the first HMAC generated by the STA, the local authentication request further includes an AP public key, and the first STA ciphertext is generated based on the AP public key and the first random number generated by the STA, The generation of the local verification HMAC includes: Decrypting the first STA ciphertext in the final response message based on the AP private key to obtain a random number; and Generating the local verification HMAC based on the obtained random number and the AP identifier in the final response message.

6. The identity authentication method according to claim 5, characterized in that, When the security module generates the first response code based on the AP private key, the first STA ciphertext, the STA identifier, the first timestamp of the AP, and the first timestamp of the STA in the initial response message, the second response code is generated by the STA based on the first response code, the STA identifier locally stored by the STA, and the second timestamp of the STA. The generation of the verification response code includes: Confirming whether the second timestamp of the STA in the second response code is within a first preset time range; and When the second timestamp is within the first preset time range, generating the verification response code based on the first response code, the STA identifier, and the second timestamp of the STA in the final response message.

7. The identity authentication method according to claim 6, wherein The identity authentication method further includes: Sending the local authentication request, where the local authentication request includes the AP identifier, the AP public key, and the first timestamp of the AP, so that the STA generates the first HMAC based on the STA key, the first random number generated by the STA, the AP identifier in the local authentication request, and the first timestamp of the AP, and sends the initial response message. Forwarding the initial response message corresponding to the local authentication request from the STA to the security module includes: When the AP identifier and the first timestamp of the AP in the initial response message are respectively consistent with the AP identifier and the first timestamp of the AP in the local authentication request, confirming whether the first timestamp of the STA is within a second preset time range; and When the first timestamp of the STA is within the second preset time range, retaining the first timestamp of the STA and the STA identifier in the initial response message, and forwarding the initial response message and the first timestamp of the AP to the security module, so that the security module generates the first response code based on the AP private key, the first STA ciphertext, the first timestamp of the STA, the STA identifier, and the first timestamp of the AP in the initial response message, and sends the first response code to the AP.

8. The identity authentication method according to any one of claims 2-7, characterized in that, The identity authentication method further includes: Sending a remote authentication request to the AS, where the remote authentication request includes: the first STA ciphertext, the STA identifier, the first HMAC generated by the STA, and the AP identifier, so that the AS generates a remote verification HMAC based on the STA public key and the first STA ciphertext and the AP identifier in the remote authentication request, and the AS confirms that the identity authentication of the STA is successful when the remote verification HMAC is consistent with the first HMAC generated by the STA.

9. The identity authentication method according to claim 6 or 7, characterized in that, The identity authentication method further includes: Send a remote authentication request to the AS, where the remote authentication request includes: the first STA ciphertext, the STA identifier, the first HMAC generated by the STA, the AP identifier, and the second timestamp of the STA, so that the AS generates a remote verification HMAC based on the STA public key, the first STA ciphertext in the remote authentication request, and the AP identifier, and when the remote verification HMAC is consistent with the first HMAC generated by the STA and the second timestamp of the STA is within the first preset time range, confirm that the identity authentication of the STA is successful.

10. The identity authentication method according to any one of claims 1-7, characterized in that, The identity authentication method further includes: Receive a secondary authentication message from the AS, where the secondary authentication message includes: the first AP ciphertext, the AP identifier, the HMAC about the AP generated by the AS; Decrypt the first AP ciphertext based on the AP private key to obtain the AS random number; Generate a first AS verification HMAC based on the AS random number and the AP identifier in the secondary authentication message; When the first AS verification HMAC is consistent with the HMAC about the AP and the AP identifier in the secondary authentication message is consistent with the AP identifier stored locally by the AP, confirm that the signature verification of the AS is successful.

11. The identity authentication method according to any one of claims 1-7, characterized in that, The identity authentication method further includes: Send a remote authentication request to the AS, where the remote authentication request includes: the STA identifier, the HMAC generated by the AP, the random number generated by the AP, the second timestamp of the AP, so that the AS generates a remote verification HMAC based on the STA identifier and the second timestamp of the AP in the remote authentication request, and the AS confirms that the identity authentication of the AP is successful when the remote verification HMAC is consistent with the HMAC generated by the AP.

12. The identity authentication method according to claim 11, wherein The identity authentication method further includes: Receive a secondary authentication message from the AS, where the secondary authentication message includes: the first AP ciphertext, the AP identifier, the HMAC about the AP generated by the AS, the AS timestamp, the second timestamp of the AP; Decrypt the first AP ciphertext based on the AP private key to obtain the AS random number; Generate a first AS verification HMAC based on the AS random number, the AP identifier, and the AS timestamp; and When the first AS verification HMAC is consistent with the HMAC about the AP, the AP identifier in the secondary authentication message is consistent with the AP identifier stored locally by the AP, and the second timestamp of the AP in the secondary authentication message is consistent with the second timestamp of the AP in the remote authentication request, confirm that the signature verification of the AS is successful.

13. An identity authentication method, characterized in that, Applied to the STA, the identity authentication method includes: Send an initial response message corresponding to the local authentication request to the AP for the AP to forward the initial response message to the security module, where the initial response message includes the STA identifier, and the security module generates a first response code based on the AP private key and the STA identifier in the initial response message and sends the first response code to the AP, where the AP private key is stored in the security module; Receive the first response code forwarded by the AP; Generate a second response code based on the first response code and the STA identifier locally stored by the STA; and Send a final response message to the AP for the AP to generate a verification response code based on the first response code and the STA identifier in the final response message and determine that the authentication of the STA is successful if the second response code in the final response message is consistent with the verification response code.

14. The identity authentication method according to claim 13, wherein The final response message further includes a first STA ciphertext and a first HMAC generated by the STA; Execute by the AP: Generate a local verification HMAC based on the AP private key, the first STA ciphertext in the final response message, and the AP identifier; And Confirm whether the local verification HMAC is consistent with the first HMAC generated by the STA in the final response message; The step of generating the verification response code is executed when the local verification HMAC is consistent with the first HMAC generated by the STA in the final response message.

15. The identity authentication method according to claim 14, wherein The authentication method further includes: Receive the local authentication request; Generate a first HMAC based on the AP identifier in the local authentication request and a first random number generated by the STA, and send the initial response message, where the initial response message includes the first HMAC generated by the STA, and the local authentication request includes the AP public key; and Generate the first STA ciphertext based on the AP public key and the first random number generated by the STA; Generating a local verification HMAC based on the AP private key, the first STA ciphertext in the final response message, and the AP identifier includes: Decrypt the first STA ciphertext in the final response message based on the AP private key to obtain a random number; and Generate the local verification HMAC based on the obtained random number and the AP identifier in the final response message.

16. The identity authentication method according to claim 14, characterized in that, When the security module generates the first response code based on the AP private key, the first STA ciphertext, the STA identifier, the first timestamp of the AP, and the first timestamp of the STA in the initial response message, generating the second response code based on the first response code and the STA identifier locally stored by the STA includes: generating the second response code based on the first response code, the STA identifier locally stored by the STA, and the second timestamp of the STA; Generating a verification response code based on the first response code and the STA identifier in the final response message includes: Confirming whether the second timestamp of the STA in the second response code is within a first preset time range; and When the second timestamp is within the first preset time range, generate the verification response code based on the first response code and the STA identifier and the second timestamp of the STA in the final response message.

17. The identity authentication method according to claim 16, wherein The identity authentication method further includes: Receive the local authentication request, where the local authentication request includes the AP identifier, the AP public key, and the first timestamp of the AP; Generate a first HMAC based on the STA key, the first random number generated by the STA in the local authentication request, the AP identifier, and the first timestamp of the AP, and send the initial response message, where the initial response message includes the first HMAC generated by the STA; Forwarding the initial response message to the security module includes: When the AP identifier and the first timestamp of the AP in the initial response message are respectively consistent with the AP identifier and the first timestamp of the AP in the local authentication request, confirm whether the first timestamp of the STA is within the second preset time range; and When the first timestamp of the STA is within the second preset time range, retain the first timestamp and the STA identifier of the STA in the initial response message, and forward the initial response message and the first timestamp of the AP to the security module, so that the security module generates a first response code based on the AP private key, the first STA ciphertext, the first timestamp and the STA identifier of the STA, and the first timestamp of the AP in the initial response message, and send the first response code to the AP.

18. The identity authentication method according to any one of claims 13-17, characterized in that, The identity authentication method further includes: Receive the secondary authentication message forwarded from the AP, where the secondary authentication message includes: the AS ciphertext, the STA identifier, the HMAC of the STA generated by the AS; Decrypt the AS ciphertext based on the STA public key to obtain the AS random number; Generate a second AS verification HMAC based on the AS random number and the STA identifier in the secondary authentication message; When the second AS verification HMAC is consistent with the HMAC of the STA generated by the AS and the STA identifier in the secondary authentication message is consistent with the STA identifier stored locally by the STA, confirm that the signature verification of the AS is successful.

19. The identity authentication method according to any one of claims 13-17, characterized in that, The identity authentication method further includes: Receive the secondary authentication message forwarded from the AP, where the secondary authentication message includes: the AS ciphertext, the STA identifier, the HMAC of the STA generated by the AS, the AS timestamp; Decrypt the AS ciphertext based on the STA public key to obtain the AS random number; Generate a second AS verification HMAC based on the AS random number, the STA identifier in the secondary authentication message, and the AS timestamp; and When the second AS verification HMAC is consistent with the HMAC of the STA generated by the AS and the STA identifier in the secondary authentication message is consistent with the STA identifier stored locally by the STA, confirm that the signature verification of the AS is successful.

20. A key negotiation method, characterized in that, Applied to the AP, the key negotiation method includes: Perform identity authentication according to the identity authentication method described in any one of claims 1-12; Forward the key information corresponding to the key negotiation request from the STA to the security module for the security module to execute: generate a session key based on the second random number generated by the STA and the random number generated by the AP, generate a negotiation response code based on the session key, the second STA ciphertext in the key information, and the STA identifier, and send a response message to the AP, where the response message includes the negotiation response code and the STA identifier; In response to receiving the response message, generate a negotiation verification code based on the session key, the second STA ciphertext, and the STA identifier in the response message; and Confirm that the key negotiation is successful when the negotiation response code is consistent with the negotiation verification code.

21. The key negotiation method according to claim 20, wherein The key negotiation method further includes: Send the key negotiation request, where the key negotiation request includes the AP public key, for the STA to generate key material based on the second random number generated by the STA and encrypt the key material using the AP public key to generate the second STA ciphertext.

22. The key negotiation method according to claim 20 or 21, characterized in that, The key negotiation method further includes: Encrypt the combination formed by the fixed string, the AP identifier, and the STA identifier in the key information using the session key to generate a key confirmation code; and Send a key confirmation message to the STA, where the key confirmation message includes the key confirmation code, the AP identifier, and the STA identifier, for the STA to generate a key verification code based on the session key, the AP identifier and the STA identifier in the key confirmation message, and the fixed string, and confirm that the key negotiation is successful when the key confirmation code is consistent with the key verification code.

23. The key negotiation method according to claim 20, wherein The key information further includes the third timestamp of the AP and the third timestamp of the STA, The session key is generated based on the second random number generated by the STA, the random number generated by the AP, and the third timestamp of the STA and the third timestamp of the AP in the key information, and the negotiation response code is generated based on the session key, the second STA ciphertext, the STA identifier, and the third timestamp of the STA and the third timestamp of the AP in the key information, The response message includes the negotiation response code, the STA identifier, the third timestamp of the STA, and the third timestamp of the AP, The generation of the negotiation response code includes: in response to receiving the response message, generating the negotiation verification code based on the session key, the second STA ciphertext, the STA identifier in the response message, the third timestamp generated by the STA, and the third timestamp of the AP.

24. The key negotiation method according to claim 23, wherein The key negotiation method further includes: Send the key negotiation request, where the key negotiation request includes the AP public key and the third timestamp of the AP, for the STA to generate key material based on the second random number generated by the STA and the third timestamp generated by the STA and encrypt the key material using the AP public key to generate the second STA ciphertext.

25. The key negotiation method according to claim 23 or 24, characterized in that, The key negotiation method further includes: encrypting a combination formed by the session key, a fixed string, an AP identifier, an STA identifier in the key information, a third timestamp generated by the STA, and a third timestamp of the AP to generate a key confirmation code; and sending a key confirmation message to the STA, where the key confirmation message includes the key confirmation code, the AP identifier, the STA identifier, the third timestamp generated by the STA, and the third timestamp of the AP, so that the STA generates a key verification code based on the key confirmation code, the AP identifier, the STA identifier, the third timestamp generated by the STA, the third timestamp of the AP, and the fixed string, and confirms that the key negotiation is successful when the key confirmation code is consistent with the key verification code.

26. The key negotiation method according to any one of claims 20-21, 23-24, characterized in that, The key information further includes a second HMAC generated by the STA, the security module decrypts the second STA ciphertext using the STA public key to obtain key material; generating an HMAC for the STA based on the key material, the STA public key, and the AP identifier; and generating a session key based on the second random number generated by the STA and the random number generated by the AP when the HMAC for the STA is consistent with the second HMAC generated by the STA.

27. A method for switching dynamic routes, characterized in that The handover method includes: performing key negotiation according to the key negotiation method according to any one of claims 20-26; determining a plurality of weights corresponding to a plurality of communication metrics according to the fuzzy consistent matrix; determining an index weighted value for each single communication mode and an index weighted value for each combined communication mode according to a plurality of index values corresponding to the plurality of communication metrics and the plurality of weights in a single communication mode among a plurality of communication modes; and adaptively selecting, according to a specific scenario, a single communication mode or a combined communication mode corresponding to the maximum index weighted value.

28. The switching method according to claim 27, wherein The determining the index weighted value for each single communication mode and the index weighted value for each combined communication mode includes: determining a plurality of index values corresponding to the plurality of communication metrics in each combined communication mode according to a plurality of index values corresponding to the plurality of communication metrics in a single communication mode among a plurality of communication modes; determining the index weighted value for each single communication mode according to a plurality of index values corresponding to the plurality of communication metrics in a single communication mode among a plurality of communication modes and the plurality of weights corresponding to the plurality of communication metrics; and determining the index weighted value for each combined communication mode according to a plurality of index values corresponding to the plurality of communication metrics in each combined communication mode and the plurality of weights corresponding to the plurality of communication metrics.

29. The switching method according to claim 27, wherein The determining the plurality of weights corresponding to the plurality of communication metrics includes: converting the fuzzy consistent matrix to obtain a fuzzy complementary judgment matrix; performing a normalization process on the fuzzy complementary judgment matrix to obtain a normalized matrix; determining an eigenvector corresponding to the maximum eigenvalue according to the normalized matrix; and Determine multiple elements in the feature vector corresponding to the multiple communication metrics as multiple weights corresponding to the multiple communication metrics.

30. An AP, characterized in that, The AP includes: an execution device for executing the authentication method according to any one of claims 1-12, the key negotiation method according to any one of claims 20-26, or the dynamic routing switching method according to any one of claims 27-29.

31. A STA, characterized in that, The STA includes: an execution device for executing the authentication method according to any one of claims 13-19 or the dynamic routing switching method according to any one of claims 27-29.

32. An identity authentication system, characterized in that, Applied to the AP, the authentication system includes: A first forwarding device for forwarding an initial response message corresponding to a local authentication request from the STA to the security module; A first receiving device for receiving a first response code generated by the security module based on the AP private key and the STA identifier in the initial response message, wherein the AP private key is stored in the security module; A second forwarding device for forwarding the first response code to the STA, so that the STA generates a second response code based on the first response code and the STA identifier and sends a final response message, wherein the final response message includes the second response code and the STA identifier; A second receiving device for receiving the final response message; A generating device for generating a verification response code based on the first response code and the STA identifier in the final response message; and A determining device for determining that the authentication of the STA is successful when the second response code is consistent with the verification response code.

33. An identity authentication system, characterized in that, Applied to the STA, the authentication system includes: A first sending device for sending an initial response message corresponding to a local authentication request to the AP, so that the AP forwards the initial response message to the security module, wherein the initial response message includes the STA identifier, and the security module generates a first response code based on the AP private key and the STA identifier in the initial response message and sends the first response code to the AP, wherein the AP private key is stored in the security module; A receiving device for receiving the first response code forwarded by the AP; A generating device for generating a second response code based on the first response code and the STA identifier locally stored by the STA; and A second sending device for sending a final response message to the AP, so that the AP generates a verification response code based on the first response code and the STA identifier in the final response message and determines that the authentication of the STA is successful when the second response code in the final response message is consistent with the verification response code.

34. A key negotiation system, characterized in that, Applied to the AP, the key negotiation system includes: The authentication system according to claim 32 for performing authentication; A forwarding device is configured to forward key information corresponding to a key negotiation request from a STA to a security module, so that the security module performs: generating a session key based on a second random number generated by the STA and a random number generated by the AP, generating a negotiation response code based on the session key, a second STA ciphertext in the key information, and a STA identifier, and sending a response message to the AP, where the response message includes the negotiation response code and the STA identifier; A generating device is configured to, in response to receiving the response message, generate a negotiation verification code based on the session key, the second STA ciphertext, and the STA identifier in the response message; and A confirmation device is configured to confirm successful key negotiation when the negotiation response code is consistent with the negotiation verification code.

35. A dynamic routing switching system, characterized in that, The handover system includes: The key negotiation system according to claim 34, configured to perform key negotiation; A first determination device is configured to determine a plurality of weights corresponding to a plurality of communication metrics according to a fuzzy consistent matrix; A second determination device is configured to determine an index weighted value under each single communication mode and an index weighted value under each combined communication mode according to a plurality of index values corresponding to the plurality of communication metrics and the plurality of weights under a single communication mode among a plurality of communication modes; and A selection device is configured to adaptively select a single communication mode or a combined communication mode corresponding to the maximum index weighted value according to a specific scenario.

36. A computer-readable storage medium, characterized in that, A computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, it implements the identity authentication method according to any one of claims 1-19, the key negotiation method according to any one of claims 20-26, or the dynamic routing handover method according to any one of claims 27-29.

Citation Information

Patent Citations

  • Method for enhancing fast handover authentication security of wireless local land area

    CN101800982A

  • Enhanced EAP identity verification method of power wireless private network

    CN114501438A

  • Key negotiation method, device, system, equipment, medium and chip

    CN118764180A

  • Key agreement method in WAPI authentication mechanism

    CN1665183A

  • Method for mobile terminal in WLAN to apply for certificate

    CN1697370A