Anti-quantum-attack national secret SSL communication system and anti-quantum-attack national secret SSL communication method
By introducing quantum-resistant SSL client agents in Guomi SSL communication system, the mixed use of traditional cryptographic technology and quantum-resistant cryptographic technology is achieved, and the existing Guomi SSL system is solved. The problem of insufficient security in the face of quantum computer attacks is improved, the system's resistance to quantum attacks is maintained, and the system's compatibility and modification costs are maintained.
Patent Information
- Application Number
- CN202411800596.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-09
- Publication Date
- 2025-03-18
- Estimated Expiration
- 2044-12-09
AI Technical Summary
When the existing Guomi SSL communication system faces quantum computer attacks, the traditional Guomi SM2 algorithm cannot provide sufficient security, and the quantum cryptographic algorithm is highly cost and risky, making it difficult to quickly upgrade the system.
The existing SSL communication system of China Secretariat has introduced a quantum SSL client agent. Through this agent, the messages from traditional SSL clients are transformed with quantum cryptography algorithms, and the messages from mixed SSL servers are inversely transformed, thereby realizing the mixed use of traditional cryptography technology and quantum cryptography technology.
This solution effectively integrates quantum cryptographic algorithms without completely replacing the existing SSL client, improving the system's resistance to quantum attacks, and has a short transformation cycle and low transformation cost, ensuring the security and compatibility of the system.
Smart Images

Figure CN119652507A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of information security technology, and in particular to a quantum attack-resistant SSL communication system and method. Background Art
[0002] With the rapid development of quantum computing technology, traditional public key cryptography systems, such as RSA, Diffie-Hellman and elliptic curve cryptography, face huge security threats. These traditional cryptography systems are expected to become vulnerable to the powerful computing power of quantum computers. The existing national secret SSL communication technology uses the national secret SM2 algorithm based on elliptic curve cryptography to achieve identity authentication and key exchange. However, in the face of attacks by quantum computers, these algorithms will no longer have sufficient security.
[0003] Quantum-resistant cryptography is a new generation of cryptographic algorithms that can resist attacks from quantum computers, including lattice-based, coding-based, multivariate polynomial-based and other technologies. At present, although relevant studies have proposed adding quantum-resistant algorithms to the national secret SSL client to resist attacks from quantum computers, the cost and risk of transforming the existing traditional national secret SSL client to quantum-resistant cryptographic algorithms are high for various reasons, and it is difficult to quickly achieve this transformation in the short term. Therefore, there is currently a lack of mature and widely used quantum-resistant cryptographic algorithm solutions.
[0004] In this context, it is necessary to propose a new technical solution that can effectively integrate quantum-resistant cryptographic algorithms without completely replacing the existing national encryption SSL client, ensure the security and compatibility of the system, and achieve a smooth transition and upgrade. Summary of the invention
[0005] The technical problem to be solved by the present invention is: in view of the above-mentioned defects of the prior art, a national secret SSL communication system and method that is resistant to quantum attacks is provided, and a quantum-resistant cryptographic algorithm is added to the existing national secret SSL communication system to realize a secure communication system and method that combines traditional cryptographic algorithms and quantum-resistant cryptographic algorithms.
[0006] To achieve the above-mentioned purpose, in a first aspect, the present invention provides a quantum-resistant national secret SSL communication system, the system comprising a traditional SSL client, a quantum-resistant SSL client agent, and a hybrid SSL server;
[0007] The traditional SSL client is a national secret SSL client that does not support anti-quantum cryptographic algorithms;
[0008] The hybrid SSL server has both traditional national secret encryption technology and anti-quantum encryption technology;
[0009] The quantum-resistant SSL client agent and the traditional SSL client are deployed on the same device or on different devices in the same local area network;
[0010] The traditional SSL client communicates with the hybrid SSL server through the quantum-resistant SSL client proxy; the quantum-resistant SSL client proxy transforms the message sent by the traditional SSL client with a quantum-resistant cryptographic algorithm before sending it to the hybrid SSL server, and inversely transforms the message sent by the hybrid SSL server with a quantum-resistant cryptographic algorithm before sending it to the traditional SSL client;
[0011] The traditional SSL client, the anti-quantum SSL client agent, and the hybrid SSL server interact with each other through messages to complete the national secret SSL handshake process that combines traditional cryptographic technology with anti-quantum cryptographic technology.
[0012] Preferably, the quantum-resistant SSL client agent supports establishing connections with multiple traditional SSL clients at the same time.
[0013] Preferably, the quantum-resistant SSL client agent distinguishes multiple sessions established between multiple traditional SSL clients and the hybrid SSL server based on IP addresses, port numbers and session IDs.
[0014] In a second aspect, the present invention provides a quantum attack-resistant national secret SSL communication method, the method is implemented based on the above-mentioned quantum attack-resistant national secret SSL communication system, and the method comprises the following steps:
[0015] Step S1, a traditional SSL client sends a client Hello message to a quantum-resistant SSL client agent, wherein the Hello message includes a first client random number ClientRandom and a cryptographic algorithm suite list Cipher Suites;
[0016] Step S2, the quantum-resistant SSL client agent adds a hybrid quantum-resistant cryptographic algorithm suite to the client Hello message, and then sends the modified client Hello message to the hybrid SSL server;
[0017] Step S3, the hybrid SSL server selects a hybrid anti-quantum cryptographic algorithm suite according to the security policy configuration, constructs a server-side Hello message, a certificate message, and a server-side hybrid key exchange message and sends them to the anti-quantum SSL client agent; the certificate includes a hybrid signature certificate and a hybrid encryption certificate, the hybrid signature certificate includes a server-side traditional signature algorithm public key and a server-side anti-quantum signature algorithm public key, the hybrid encryption certificate includes a server-side traditional encryption algorithm public key and a server-side anti-quantum encryption algorithm public key; the server-side hybrid key message includes a traditional key exchange parameter TKEX, a traditional key exchange parameter signature TS, an anti-quantum key exchange parameter PKEX, and an anti-quantum key exchange parameter signature PS;
[0018] Step S4, the quantum-resistant SSL client agent replaces the hybrid quantum-resistant cryptographic algorithm suite in the server-side Hello message with the traditional cryptographic algorithm suite supported by the SSL client; caches the quantum-resistant key exchange parameter PKEX and the session ID locally; modifies the server-side hybrid key exchange message, removes the quantum-resistant key exchange parameter PKEX and the quantum-resistant key exchange parameter signature PS, and forms a server-side traditional key exchange message; then sends the modified server-side Hello message, certificate message, and server-side traditional key exchange message to the traditional SSL client;
[0019] Step S5, the traditional SSL client generates a pre-master key PMS and a traditional client key exchange parameter CKEX according to a traditional key exchange algorithm, constructs a client key exchange message according to the traditional client key exchange parameter CKEX, and sends the client key exchange message to the quantum-resistant SSL client agent; the traditional client key exchange parameter CKEX includes a second client random number used to generate the pre-master key PMS;
[0020] Step S6, the quantum-resistant SSL client agent searches for the server-side quantum-resistant key exchange parameter PKEX and the hybrid quantum-resistant cryptographic algorithm suite corresponding to the session ID, performs quantum-resistant encryption on the traditional client key exchange parameter CKEX to form a hybrid client key exchange parameter MIXCKEX, and then sends the hybrid client key exchange parameter MIXCKEX to the hybrid SSL server;
[0021] Step S7, the hybrid SSL server parses the client's hybrid key exchange message MIXCKEX, decrypts and generates a pre-master key PMS;
[0022] Step S8, the hybrid SSL server and the traditional SSL client each use the pre-master key PMS to calculate the working key and perform ciphertext communication according to the existing national encryption SSL specification.
[0023] Preferably, before step S4, the step further includes:
[0024] The quantum-resistant SSL client agent parses the server-side hybrid key exchange message and verifies the quantum-resistant key exchange parameter signature PS. If the verification fails, the handshake protocol is interrupted.
[0025] Preferably, before step S5, the step further includes:
[0026] The traditional SSL client parses the traditional key exchange message of the server, verifies the traditional key exchange parameter signature TS, and terminates the handshake protocol if the verification fails.
[0027] Preferably, in step S6, the specific method of performing quantum-resistant encryption on the traditional client key exchange parameter CKEX to form a hybrid client key exchange parameter MIXCKEX is:
[0028] If the quantum-resistant cryptographic algorithm in the hybrid cryptographic algorithm suite is a public key encryption algorithm, the quantum-resistant public key encryption algorithm is used to encrypt the traditional client key exchange parameter CKEX, the ciphertext ECKEX is output, and the hybrid client key exchange parameter MIXCKEX=ECKEX is generated; if the quantum-resistant cryptographic algorithm in the hybrid cryptographic algorithm suite is a quantum-resistant key encapsulation algorithm, the quantum-resistant key encapsulation algorithm and the quantum-resistant public key are used to generate a shared key plaintext SS and a ciphertext ESS, the plaintext SS is used to symmetric encrypt the traditional client key exchange parameter CKEX, the ciphertext ECKEX is output, and the hybrid client key exchange parameter MIXCKEX=ESS|ECKEX is generated.
[0029] Preferably, in step S7, the specific method of decrypting and generating the pre-master key PMS is:
[0030] If the quantum-resistant cryptographic algorithm in the hybrid cryptographic algorithm suite is a public key encryption algorithm, use the quantum-resistant private key to decrypt ECKEX and output the traditional client key exchange parameter CKEX; if the quantum-resistant cryptographic algorithm in the hybrid cryptographic algorithm suite is a quantum-resistant key encapsulation algorithm, use the quantum-resistant private key to decapsulate ESS to generate the shared key plaintext SS, and then use SS to symmetric-decrypt ECKEX to output the traditional client key exchange parameter CKEX; finally, generate the pre-master key PMS based on the traditional client key exchange parameter CKEX.
[0031] The present invention has the following beneficial effects: the quantum attack-resistant national secret SSL communication system provided by the present solution includes a traditional SSL client, a quantum-resistant SSL client agent, and a hybrid SSL server. The traditional SSL client is a national secret SSL client that does not support quantum-resistant cryptographic algorithms, and the hybrid SSL server has both traditional cryptographic technology and quantum-resistant cryptographic technology. The traditional SSL client communicates with the hybrid SSL server through the quantum-resistant SSL client agent. The quantum-resistant SSL client agent transforms the message sent by the traditional SSL client with the quantum-resistant cryptographic algorithm before sending it to the hybrid SSL server, and inversely transforms the message sent by the hybrid SSL server with the quantum-resistant cryptographic algorithm before sending it to the traditional SSL client. The traditional SSL client, the quantum-resistant SSL client agent, and the hybrid SSL server interact with each other through messages to complete the national secret SSL handshake process of mixing traditional cryptographic technology and quantum-resistant cryptographic technology. The present solution improves the system's ability to resist quantum attacks by incrementally deploying quantum-resistant SSL client agents on the SSL client, without affecting the existing SSL client or system, with a short transformation cycle and low transformation cost. BRIEF DESCRIPTION OF THE DRAWINGS
[0032] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of the present invention. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:
[0033] Figure 1 A block diagram of a quantum attack-resistant national encryption SSL communication system provided for one embodiment of the present invention.
[0034] Figure 2 A block diagram of a quantum attack-resistant national encryption SSL communication system provided in accordance with another embodiment of the present invention.
[0035] Figure 3 An interactive schematic diagram of the quantum attack-resistant national secret SSL communication method provided in an embodiment of the present invention.
[0036] Figure 4 An interactive flow chart of the quantum attack-resistant national encryption SSL communication method provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0037] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0038] The general idea of the present invention is: for traditional SSL clients that cannot be upgraded to quantum-resistant cryptographic algorithms for various reasons, the purpose of supporting quantum-resistant cryptographic algorithms for SSL clients is indirectly achieved by incrementally deploying quantum-resistant SSL client proxies with quantum-resistant cryptographic algorithm technology. The traditional SSL client is combined with the quantum-resistant SSL client proxies to form a virtual SSL client that supports quantum-resistant cryptographic algorithms, which has no impact on existing SSL clients or systems and has low transformation costs.
[0039] The embodiments of the present invention are further described in detail below in conjunction with the accompanying drawings of the specification. It should be understood that the embodiments described herein are only used to illustrate and explain the present invention, and are not used to limit the present invention.
[0040] like Figure 1 As shown, an embodiment of the present invention provides a national secret SSL communication system that is resistant to quantum attacks. The system includes a traditional SSL client, a quantum-resistant SSL client agent, and a hybrid SSL server.
[0041] The traditional SSL client is a national secret SSL client that does not support quantum-resistant cryptographic algorithms. The traditional SSL client includes browsers, email clients, mobile applications, enterprise-level applications, security devices (firewalls, intrusion detection systems), etc.
[0042] The hybrid SSL server has both traditional national secret encryption technology and anti-quantum encryption technology. In the embodiment of the present invention, "hybrid" means integrating traditional national secret encryption technology with anti-quantum encryption technology, so that the system has the ability to resist quantum attacks while maintaining the security of the original national secret algorithm.
[0043] The quantum-resistant SSL client agent and the traditional SSL client are deployed on the same device or on different devices in the same local area network. The traditional SSL client establishes a connection with the quantum-resistant SSL client agent through the IP address and port number of the quantum-resistant SSL client agent.
[0044] The traditional SSL client communicates with the hybrid SSL server through the quantum-resistant SSL client agent; the quantum-resistant SSL client agent performs quantum-resistant cryptographic algorithm transformation on the message sent by the traditional SSL client before sending it to the hybrid SSL server, and performs inverse quantum-resistant cryptographic algorithm transformation on the message sent by the hybrid SSL server before sending it to the traditional SSL client. The quantum-resistant cryptographic algorithm transformation refers to performing quantum-resistant transformation on the message sent by the traditional SSL client, converting the message sent by the traditional SSL client into a corresponding message sent by an SSL client with quantum-resistant cryptographic technology, and the transformation includes adding a quantum-resistant cryptographic algorithm suite, encrypting the message content using a quantum-resistant cryptographic algorithm, etc. The inverse quantum-resistant cryptographic algorithm transformation refers to performing quantum-resistant inverse transformation on the message sent by the SSL client, converting the message sent by the hybrid SSL server into a message that can be processed by the traditional SSL client, and the transformation includes replacing the quantum-resistant cryptographic algorithm suite with a cryptographic algorithm suite supported by the traditional SSL client, etc.
[0045] The traditional SSL client, the anti-quantum SSL client agent, and the hybrid SSL server interact with each other through messages to complete the national secret SSL handshake process that combines traditional cryptographic technology with anti-quantum cryptographic technology.
[0046] In an embodiment of the present invention, the quantum-resistant SSL client agent establishes a quantum-resistant hybrid connection with a hybrid SSL server, and establishes a standard SSL connection with a traditional SSL client. During the national secret SSL handshake phase, the quantum-resistant SSL client agent parses and modifies the messages from the traditional SSL client and the hybrid SSL server, removes the quantum-resistant part of the hybrid SSL server message, and then forwards it to the traditional SSL client; adds quantum-resistant support to the traditional SSL client message, and then forwards it to the hybrid SSL server. In the subsequent ciphertext transmission phase, the quantum-resistant SSL client agent is only responsible for forwarding messages, while the encryption and decryption of messages are completed by the traditional SSL client and the hybrid SSL server. This approach has minimal impact on existing national secret SSL clients, making the quantum-resistant SSL client agent more lightweight, with low transformation costs and short transformation cycles.
[0047] like Figure 2As shown, in some embodiments of the present invention, the quantum-resistant SSL client agent supports establishing connections with multiple traditional SSL clients at the same time. Furthermore, the quantum-resistant SSL client agent distinguishes multiple sessions established between multiple traditional SSL clients and the hybrid SSL server according to IP addresses, port numbers and session IDs. Each session has its own status and parameters, and multiple sessions can exist at the same time. In environments such as enterprises and schools, there are a large number of SSL clients, and the quantum-resistant SSL client agent needs to establish connections with multiple traditional SSL clients. In order to meet different needs, multiple quantum-resistant SSL client agents can be deployed in a local area network, which are jointly responsible for the external connections of all traditional SSL clients in the local area network. This can improve the connection efficiency and ensure the security and reliability of network communications.
[0048] like Figure 3-Figure 4 As shown, an embodiment of the present invention further provides a quantum attack-resistant national secret SSL communication method, which is applied to the quantum attack-resistant national secret SSL communication system as described above, and the method comprises the following steps:
[0049] Step S1: A traditional SSL client sends a client Hello message to a quantum-resistant SSL client agent, wherein the Hello message includes a first client random number ClientRandom and a cryptographic algorithm suite list Cipher Suites.
[0050] In the embodiment of the present invention, the content of the client Hello message in step S1 is exactly the same as that in the SSL handshake process in the prior art, except that the recipient of the client Hello message is a quantum-resistant SSL client proxy instead of a hybrid SSL server. In addition to the first client random number ClientRandom and the cipher suite list Cipher Suites, the client Hello message also includes the SSL protocol version number, compression algorithm list, and extension field supported by the traditional SSL client. The cipher suite list Cipher Suites only includes the traditional national secret cipher suite.
[0051] The following is an example of the main fields in the client Hello message structure. Version indicates the SSL protocol version number supported by the traditional SSL client, Random indicates the first client random number, and Cipher Suites indicates the list of cipher suites, which only includes the national secret cipher suite ECC_SM4_CBC_SM3. The overall process of ECC_SM4_CBC_SM3 is as follows: the client and the server negotiate to use the ECC_SM4_CBC_SM3 cipher suite during the handshake phase; both parties exchange keys through the ECC algorithm to generate a shared key; use the SM4 algorithm to encrypt and decrypt the transmitted data in CBC mode; use the SM3 algorithm to perform digest calculations on the transmitted data to ensure the integrity and authenticity of the data. The ECC_SM4_CBC_SM3 cipher suite combines the advantages of the three algorithms, ECC, SM4, and SM3, and has high security and efficiency.
[0052] Version:0x0101
[0053] Random:45fd90072e52e0c9cc7194f04191aba18eee1ad54961d6637eaf517dfc361874
[0054] Cipher Suites:ECC_SM4_CBC_SM3
[0055] It should be noted that in the above example, the cryptographic algorithm suite list includes only one cryptographic algorithm suite. In actual applications, the cryptographic algorithm suite list may also include multiple cryptographic algorithm suites.
[0056] Step S2, the quantum-resistant SSL client agent attaches a hybrid quantum-resistant cryptographic algorithm suite to the client Hello message, and then sends the modified client Hello message to the hybrid SSL server.
[0057] In an embodiment of the present invention, after receiving the client Hello message, the quantum-resistant SSL client agent adds a quantum-resistant cryptographic algorithm suite to the cryptographic algorithm suite list Cipher Suites, and then sends it to the hybrid SSL server. The example after adding the quantum-resistant cryptographic algorithm suite to the client Hello message after step S1 is shown below. The quantum-resistant SSL client agent adds ECC_MLDSA65_MLKEM768_SM4_CBC_SM3 to the cryptographic algorithm suite list Cipher Suites. ECC_MLDSA65_MLKEM768_SM4_CBC_SM3 is a composite cryptographic algorithm suite that combines a variety of cryptographic technologies, including elliptic curve cryptography (ECC), multi-layer digital signature algorithm (MLDSA), multi-layer key encapsulation mechanism (MLKEM), symmetric encryption algorithm (SM4) and hash algorithm (SM3). Its workflow is as follows: use ECC and ML DSA for key exchange and digital signature; use MLKEM for key encapsulation; use SM4_CBC mode for data encryption and decryption; use SM3 hash algorithm for data integrity verification. ECC_MLDSA65_MLKEM768_SM4_CBC_SM3 combines multiple cryptographic technologies to provide multi-level security that can resist multiple attacks, including quantum computing attacks.
[0058] Version:0x0101
[0059] Random:45fd90072e52e0c9cc7194f04191aba18eee1ad54961d6637eaf517dfc361874
[0060] Cipher Suites:ECC_SM4_CBC_SM3 ECC_MLDSA65_MLKEM768_SM4_CBC_SM3
[0061] It should be noted that in the above example, the quantum-resistant SSL client agent only adds one quantum-resistant cryptographic algorithm suite to the cryptographic algorithm suite list. In actual applications, multiple suites may also be added.
[0062] Step S3, the hybrid SSL server selects a hybrid anti-quantum cryptographic algorithm suite according to the security policy configuration, constructs a server-side Hello message, a certificate message, and a server-side hybrid key exchange message and sends them to the anti-quantum SSL client agent; the certificate includes a hybrid signature certificate and a hybrid encryption certificate, the hybrid signature certificate includes the server-side traditional signature algorithm public key and the server-side anti-quantum signature algorithm public key, the hybrid encryption certificate includes the server-side traditional encryption algorithm public key and the server-side anti-quantum encryption algorithm public key; the server-side hybrid key message includes traditional key exchange parameters TKEX, traditional key exchange parameter signature TS, anti-quantum key exchange parameters PKEX and anti-quantum key exchange parameter signature PS.
[0063] The content of the server Hello message is the same as the national secret SSL handshake process, including the server SSL version number, the server random number ServerRandom, the cipher suite selected by the server, and the session ID. The server Hello message example is as follows, Random is the server random number, Cipher Suite is the cipher suite selected by the server. In the following example, the server selects the quantum-resistant cipher suite ECC_MLDSA65_MLKEM768_SM4_CBC_SM3 added by the quantum-resistant SSL client agent.
[0064] Version:0x0101
[0065] Random:1fa43d761820e309c01a87182ed550792bb173c09ad78e76c90ffab2d72edabd
[0066] Session ID:78849b4eb1f9d679ca3d697fb28b9a4fa33fed59d65a117445abe2b51298d360
[0067] Cipher Suite:ECC_MLDSA65_MLKEM768_SM4_CBC_SM3
[0068] The certificate message sent by the hybrid SSL server includes a hybrid signature certificate and a hybrid encryption certificate. The hybrid signature certificate includes the server's traditional signature algorithm public key, the first traditional certificate signature, the server's anti-quantum signature algorithm public key, and the first anti-quantum certificate signature. The hybrid encryption certificate includes the server's traditional encryption algorithm public key, the second traditional certificate signature, the server's anti-quantum encryption algorithm public key, and the second anti-quantum certificate signature. When the server generates the server's traditional signature algorithm public key and the server's anti-quantum signature algorithm public key, it also generates the server's traditional signature algorithm private key and the server's anti-quantum signature algorithm private key corresponding to the two. When the server generates the server's traditional encryption algorithm public key and the server's anti-quantum encryption algorithm public key, it also generates the server's traditional encryption algorithm private key and the server's anti-quantum encryption algorithm private key corresponding to the two. The first traditional certificate signature, the first anti-quantum certificate signature, the second traditional certificate signature, and the second anti-quantum certificate signature are used to verify the legitimacy of the certificate.
[0069] In the server-side hybrid key exchange message, the traditional key exchange parameter TKEX and the quantum-resistant key exchange parameter PKEX can be empty. If the quantum-resistant key exchange parameter PKEX is not empty, it is the temporary quantum-resistant public key generated by the hybrid SSL server. The traditional key exchange parameter signature TS=Asymmetric_Sign(ClientRandom|ServerRandom|TKEX,pri_sig_s), Asymmetric_Sign is the traditional asymmetric algorithm signature algorithm, ClientRandom is the first client random number, ServerRandom is the server random number, pri_sig_s is the server-side traditional signature algorithm private key, | indicates the connection operation. The quantum-resistant key exchange parameter signature PS=PQC_Sign(ClientRandom|ServerRandom|TKEX|PKEX,pqc_pri_sig_s), PQC_Sign is the quantum-resistant signature algorithm, and pqc_pri_sig_s is the server-side quantum-resistant signature algorithm private key. After the hybrid SSL server calculates the traditional key exchange parameter signature TS and the quantum-resistant key exchange parameter signature PS, it constructs the server hybrid key exchange message MIXSKEX=TKEX|TS|PKEX|PS, and then sends the server Hello message, certificate message, and server hybrid key exchange message to the quantum-resistant SSL client agent. An example of the server hybrid key message is as follows, where Signature represents the traditional key exchange parameter signature and PQC Signature represents the quantum-resistant key exchange parameter signature.
[0070] Version:0x0101
[0071] Signature:304502204e4a83d03bc946e06078c85cec45e8c4e160366a70282f79202f7eb2ee 280437022100b1cd77d3fa7a855305a6d8cd5d7cb07012edb818d058f3aaafc9bec61da0e856
[0072] PQC Signature:cfb6799571891ba3d1496e179cc49470aa759b09e8beee4d9979c7bd812018d8......
[0073] Step S4, the quantum-resistant SSL client agent replaces the hybrid quantum-resistant cryptographic algorithm suite in the server-side Hello message with the traditional cryptographic algorithm suite supported by the SSL client; caches the quantum-resistant key exchange parameter PKEX and the session ID locally; modifies the server-side hybrid key exchange message, removes the quantum-resistant key exchange parameter PKEX and the quantum-resistant key exchange parameter signature PS, and forms a server-side traditional key exchange message; and then sends the modified server-side Hello message, certificate message, and server-side traditional key exchange message to the traditional SSL client.
[0074] In the embodiment of the present invention, before step S4, the following steps are further included:
[0075] The quantum-resistant SSL client agent parses the server-side hybrid key exchange message and verifies the quantum-resistant key exchange parameter signature PS. If the verification fails, the handshake protocol is interrupted. Specifically, the quantum-resistant SSL client agent verifies the quantum-resistant key exchange parameter signature PS through the server-side quantum-resistant signature algorithm public key contained in the hybrid signature certificate sent by the server.
[0076] In an embodiment of the present invention, the quantum-resistant SSL client agent replaces the hybrid quantum-resistant cryptographic algorithm suite in the server-side Hello message with the traditional cryptographic algorithm suite, for example, replaces the quantum-resistant cryptographic algorithm suite Cipher Suite from ECC_MLDSA65_MLKEM768_SM4_CBC_SM3 back to ECC_SM4_CBC_SM3 supported by the SSL client. At the same time, the quantum-resistant key exchange parameter PKEX and the quantum-resistant signature PS in the server-side hybrid key exchange message are removed. The quantum-resistant SSL client agent caches the quantum-resistant key exchange parameter PKEX and the session ID locally for encryption of the key exchange parameters sent by the traditional SSL client in the subsequent handshake process.
[0077] Corresponding to the message example in step S4, the message example in step S5 is as follows.
[0078] Example of a modified server Hello message, where the Cipher Suite is replaced.
[0079] Version:0x0101
[0080] Random:1fa43d761820e309c01a87182ed550792bb173c09ad78e76c90ffab2d72edabd
[0081] Session ID:78849b4eb1f9d679ca3d697fb28b9a4fa33fed59d65a117445abe2b51298d360
[0082] Cipher Suite:ECC_SM4_CBC_SM3
[0083] An example of a modified server key exchange message, where the PQC Signature is removed.
[0084] Version:0x0101
[0085] Signature:304502204e4a83d03bc946e06078c85cec45e8c4e160366a70282f79202f7eb2ee 280437022100b1cd77d3fa7a855305a6d8cd5d7cb07012edb818d058f3aaafc9bec61da0e856
[0086] Step S5, the traditional SSL client generates a pre-master key PMS and a traditional client key exchange parameter CKEX according to a traditional key exchange algorithm, constructs a client key exchange message according to the traditional client key exchange parameter CKEX, and sends the client key exchange message to the quantum-resistant SSL client agent; the traditional client key exchange parameter CKEX includes a second client random number used to generate the pre-master key PMS.
[0087] In the embodiment of the present invention, before step S5, the following steps are further included:
[0088] The traditional SSL client parses the traditional key exchange message of the server and verifies the traditional key exchange parameter signature TS. If the verification fails, the handshake protocol is interrupted. Specifically, the SSL client verifies the traditional key exchange parameter signature TS through the traditional signature algorithm public key of the server included in the hybrid signature certificate sent by the server.
[0089] In an embodiment of the present invention, the traditional SSL client generates a pre-master key PMS and a traditional client key exchange parameter CKEX according to the traditional key exchange algorithm in accordance with the existing national encryption SSL specification GMT 0024-2023. The traditional client key exchange parameter CKEX includes a second client random number ClientRandom1 generated by the SSL client for generating the pre-master key PMS, and the pre-master key PMS is calculated by the first client random number ClientRandom, the server random number ServerRandom and the second client random number ClientRandom1. The traditional SSL client encrypts the second client random number using the public key of the server's traditional encryption algorithm, and then sends it to the quantum-resistant SSL client agent.
[0090] Step S6, the quantum-resistant SSL client agent searches for the server-side quantum-resistant key exchange parameters PKEX and the hybrid quantum-resistant cryptographic algorithm suite corresponding to the session ID, performs quantum-resistant encryption on the traditional client key exchange parameters CKEX to form hybrid client key exchange parameters MIXCKEX, and then sends the hybrid client key exchange parameters MIXCKEX to the hybrid SSL server.
[0091] In the embodiment of the present invention, after receiving the client key exchange message sent by the traditional SSL client, the quantum-resistant SSL client agent performs quantum-resistant encryption on the traditional client key exchange parameter CKEX and then sends it to the hybrid SSL server. The specific method of performing quantum-resistant encryption on the traditional client key exchange parameter CKEX to form the hybrid client key exchange parameter MIXCKEX is:
[0092] If the quantum-resistant cryptographic algorithm in the hybrid cryptographic algorithm suite is a public key encryption algorithm, the traditional client key exchange parameter CKEX is encrypted using the quantum-resistant public key encryption algorithm, the ciphertext ECKEX is output, and the hybrid client key exchange parameter MIXCKEX=ECKEX is generated; if the quantum-resistant cryptographic algorithm in the hybrid cryptographic algorithm suite is a quantum-resistant key encapsulation algorithm, the shared key plaintext SS and ciphertext ESS are generated using the quantum-resistant key encapsulation algorithm and the quantum-resistant public key, the traditional client key exchange parameter CKEX is symmetrically encrypted using the plaintext SS, the ciphertext ECKEX is output, and the hybrid client key exchange parameter MIXCKEX=ESS|ECKEX is generated. The quantum-resistant public key may be a temporary quantum-resistant public key sent by the hybrid SSL server through the server key exchange message, or it may be the server quantum-resistant encryption algorithm public key in the server hybrid encryption certificate, depending on the type of key exchange algorithm.
[0093] Step S7, the hybrid SSL server parses the client's hybrid key exchange message MIXCKEX, decrypts and generates a pre-master key PMS.
[0094] In the embodiment of the present invention, in step S7, the specific method of decrypting and generating the pre-master key PMS is:
[0095] If the quantum-resistant cryptographic algorithm in the hybrid cryptographic algorithm suite is a public key encryption algorithm, use the quantum-resistant private key to decrypt ECKEX and output the traditional client key exchange parameter CKEX; if the quantum-resistant cryptographic algorithm in the hybrid cryptographic algorithm suite is a quantum-resistant key encapsulation algorithm, use the quantum-resistant private key to decapsulate ESS to generate the shared key plaintext SS, and then use SS to symmetric-decrypt ECKEX to output the traditional client key exchange parameter CKEX; finally, generate the pre-master key PMS according to the traditional client key exchange parameter CKEX. Corresponding to the quantum-resistant public key, the quantum-resistant private key may be the private key corresponding to the temporary quantum-resistant public key of the hybrid SSL server, or it may be the private key corresponding to the public key of the server-side quantum-resistant encryption algorithm in the server-side hybrid encryption certificate, depending on the type of key exchange algorithm.
[0096] Step S8, the hybrid SSL server and the traditional SSL client each use the pre-master key PMS to calculate the working key and perform ciphertext communication according to the existing national encryption SSL specification.
[0097] The working key and subsequent processes follow the GMT 0024-2023 specification and will not be described in detail here.
[0098] It should be noted that when the existing national secret SSL client is transformed into an anti-quantum client, it is necessary to evaluate the transformation cycle, transformation cost, and transformation risk of each SSL client separately. After the evaluation, the SSL client can be quickly upgraded and can directly communicate with the hybrid SSL server in the solution of the present invention after the upgrade is completed. For SSL clients that are temporarily inconvenient to upgrade or have a long upgrade cycle, it is necessary to communicate with the hybrid SSL server through the anti-quantum SSL client agent to obtain anti-quantum capabilities.
[0099] The present invention has the following beneficial effects: the quantum attack-resistant national secret SSL communication system provided by the present solution includes a traditional SSL client, a quantum-resistant SSL client agent, and a hybrid SSL server. The traditional SSL client is a national secret SSL client that does not support quantum-resistant cryptographic algorithms, and the hybrid SSL server has both traditional cryptographic technology and quantum-resistant cryptographic technology. The traditional SSL client communicates with the hybrid SSL server through the quantum-resistant SSL client agent. The quantum-resistant SSL client agent transforms the message sent by the traditional SSL client with the quantum-resistant cryptographic algorithm before sending it to the hybrid SSL server, and inversely transforms the message sent by the hybrid SSL server with the quantum-resistant cryptographic algorithm before sending it to the traditional SSL client. The traditional SSL client, the quantum-resistant SSL client agent, and the hybrid SSL server interact with each other through messages to complete the national secret SSL handshake process of mixing traditional cryptographic technology and quantum-resistant cryptographic technology. The present solution improves the system's ability to resist quantum attacks by incrementally deploying quantum-resistant SSL client agents on the SSL client, without affecting the existing SSL client or system, with a short transformation cycle and low transformation cost.
[0100] The solution of the present invention effectively integrates quantum-resistant cryptographic algorithms, ensures the security and compatibility of existing national secret SSL clients / systems, and achieves smooth transition and upgrade. This not only helps protect existing investments, but also improves the overall security of the system to cope with future quantum computing threats.
[0101] The above are only specific implementations of the present invention, which cannot be used to limit the scope of the present invention. Equivalent changes made by ordinary technicians in this technical field based on this creation, as well as changes known to technicians in this field, should still fall within the scope of the present invention.
Claims
1. A quantum-resistant SSL communication system, characterized in that: The system includes a traditional SSL client, a quantum-resistant SSL client proxy, and a hybrid SSL server; The traditional SSL client is a national secret SSL client that does not support anti-quantum cryptographic algorithms; The hybrid SSL server has both traditional national secret encryption technology and anti-quantum encryption technology; The quantum-resistant SSL client agent and the traditional SSL client are deployed on the same device or on different devices in the same local area network; The traditional SSL client communicates with the hybrid SSL server through the quantum-resistant SSL client proxy; the quantum-resistant SSL client proxy transforms the message sent by the traditional SSL client with a quantum-resistant cryptographic algorithm before sending it to the hybrid SSL server, and inversely transforms the message sent by the hybrid SSL server with a quantum-resistant cryptographic algorithm before sending it to the traditional SSL client; The traditional SSL client, the anti-quantum SSL client agent, and the hybrid SSL server interact with each other through messages to complete the national secret SSL handshake process that combines traditional cryptographic technology with anti-quantum cryptographic technology.
2. According to the quantum attack-resistant national secret SSL communication system of claim 1, it is characterized in that: The quantum-resistant SSL client agent supports establishing connections with multiple traditional SSL clients at the same time.
3. The quantum attack-resistant national secret SSL communication system according to claim 2 is characterized in that: The quantum-resistant SSL client agent distinguishes multiple sessions established between multiple traditional SSL clients and the hybrid SSL server based on IP addresses, port numbers and session IDs.
4. A quantum attack-resistant national secret SSL communication method, characterized in that: Applied to the quantum attack-resistant national secret SSL communication system as claimed in any one of claims 1 to 3, the method comprises the following steps: Step S1, a traditional SSL client sends a client Hello message to a quantum-resistant SSL client agent, wherein the Hello message includes a first client random number ClientRandom and a cryptographic algorithm suite list Cipher Suites; Step S2, the quantum-resistant SSL client agent adds a hybrid quantum-resistant cryptographic algorithm suite to the client Hello message, and then sends the modified client Hello message to the hybrid SSL server; Step S3, the hybrid SSL server selects a hybrid anti-quantum cryptographic algorithm suite according to the security policy configuration, constructs a server-side Hello message, a certificate message, and a server-side hybrid key exchange message and sends them to the anti-quantum SSL client agent; the certificate includes a hybrid signature certificate and a hybrid encryption certificate, the hybrid signature certificate includes a server-side traditional signature algorithm public key and a server-side anti-quantum signature algorithm public key, the hybrid encryption certificate includes a server-side traditional encryption algorithm public key and a server-side anti-quantum encryption algorithm public key; the server-side hybrid key message includes a traditional key exchange parameter TKEX, a traditional key exchange parameter signature TS, an anti-quantum key exchange parameter PKEX, and an anti-quantum key exchange parameter signature PS; Step S4, the quantum-resistant SSL client agent replaces the hybrid quantum-resistant cryptographic algorithm suite in the server-side Hello message with the traditional cryptographic algorithm suite supported by the SSL client; caches the quantum-resistant key exchange parameter PKEX and the session ID locally; modifies the server-side hybrid key exchange message, removes the quantum-resistant key exchange parameter PKEX and the quantum-resistant key exchange parameter signature PS, and forms a server-side traditional key exchange message; then sends the modified server-side Hello message, certificate message, and server-side traditional key exchange message to the traditional SSL client; Step S5, the traditional SSL client generates a pre-master key PMS and a traditional client key exchange parameter CKEX according to a traditional key exchange algorithm, constructs a client key exchange message according to the traditional client key exchange parameter CKEX, and sends the client key exchange message to the quantum-resistant SSL client agent; the traditional client key exchange parameter CKEX includes a second client random number used to generate the pre-master key PMS; Step S6, the quantum-resistant SSL client agent searches for the server-side quantum-resistant key exchange parameter PKEX and the hybrid quantum-resistant cryptographic algorithm suite corresponding to the session ID, performs quantum-resistant encryption on the traditional client key exchange parameter CKEX to form a hybrid client key exchange parameter MIXCKEX, and then sends the hybrid client key exchange parameter MIXCKEX to the hybrid SSL server; Step S7, the hybrid SSL server parses the client's hybrid key exchange message MIXCKEX, decrypts and generates a pre-master key PMS; Step S8, the hybrid SSL server and the traditional SSL client each use the pre-master key PMS to calculate the working key and perform ciphertext communication according to the existing national encryption SSL specification.
5. According to the quantum attack-resistant national secret SSL communication method of claim 4, it is characterized in that: Before step S4, the following steps are also included: The quantum-resistant SSL client agent parses the server-side hybrid key exchange message and verifies the quantum-resistant key exchange parameter signature PS. If the verification fails, the handshake protocol is interrupted.
6. The quantum attack-resistant SSL communication method according to claim 4 is characterized in that: Before step S5, the following steps are also included: The traditional SSL client parses the traditional key exchange message of the server, verifies the traditional key exchange parameter signature TS, and terminates the handshake protocol if the verification fails.
7. The quantum attack-resistant SSL communication method according to claim 4 is characterized in that: In step S6, the specific method of performing quantum-resistant encryption on the traditional client key exchange parameter CKEX to form a hybrid client key exchange parameter MIXCKEX is: If the quantum-resistant cryptographic algorithm in the hybrid cryptographic algorithm suite is a public key encryption algorithm, the quantum-resistant public key encryption algorithm is used to encrypt the traditional client key exchange parameter CKEX, the ciphertext ECKEX is output, and the hybrid client key exchange parameter MIXCKEX=ECKEX is generated; if the quantum-resistant cryptographic algorithm in the hybrid cryptographic algorithm suite is a quantum-resistant key encapsulation algorithm, the quantum-resistant key encapsulation algorithm and the quantum-resistant public key are used to generate a shared key plaintext SS and a ciphertext ESS, the plaintext SS is used to symmetric encrypt the traditional client key exchange parameter CKEX, the ciphertext ECKEX is output, and the hybrid client key exchange parameter MIXCKEX=ESS|ECKEX is generated.
8. The quantum attack-resistant SSL communication method according to claim 7 is characterized in that: In step S7, the specific method of decrypting and generating the pre-master key PMS is: If the quantum-resistant cryptographic algorithm in the hybrid cryptographic algorithm suite is a public key encryption algorithm, use the quantum-resistant private key to decrypt ECKEX and output the traditional client key exchange parameter CKEX; if the quantum-resistant cryptographic algorithm in the hybrid cryptographic algorithm suite is a quantum-resistant key encapsulation algorithm, use the quantum-resistant private key to decapsulate ESS to generate the shared key plaintext SS, and then use SS to symmetric-decrypt ECKEX to output the traditional client key exchange parameter CKEX; finally, generate the pre-master key PMS based on the traditional client key exchange parameter CKEX.
Citation Information
Patent Citations
Quantum security encryption application system, method and access device
CN115549941A
Network communication method and device, computer equipment and storage medium
CN118827070A
Post-quantum and national secret hybrid dual-certificate SSL handshake method and device
CN119071075A
Adaptive qubit-based threshold handshaking for quantum safe protocols
US20240195612A1
Cited By
Anti-quantum tunnel communication security enhancement method and system based on software definition
CN120434048A
Control method of multi-protocol switching anti-quantum security gateway
CN121530577A
A control method of a multi-protocol switching quantum security-resistant gateway
CN121530577B