V2G cross-domain identity authentication method and system based on quantum key
Through the V2G cross-domain identity authentication method based on quantum key, the use of quantum key and anonymous credentials to achieve security in V2G communication scenarios, solving the security problem of cross-domain charge and discharge communication, and enhancing the blockchain and fog server technology Data security and system performance are provided.
Patent Information
- Application Number
- CN202411448772.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-17
- Publication Date
- 2024-12-24
- Estimated Expiration
- 2044-10-17
AI Technical Summary
In V2G communication scenarios, the communication security of vehicles during cross-domain charging and discharging is difficult to guarantee, especially the problem that classic cryptographic algorithms are easily cracked after the emergence of quantum computers.
Using V2G cross-domain identity authentication method based on quantum key, the quantum key is used for message encryption and decryption transmission through the registration stage and cross-domain identity authentication stage, and combining short-term anonymous credentials and long-term anonymous credentials, blockchain and fog servers are used. Identity authentication and data storage to ensure the security of communication.
Effectively resist quantum computing attacks, ensure the privacy and security of vehicle identities during communication, solve the problem of repeated identity authentication, and improve data security and system through decentralized blockchain storage and fog server distributed services. Response speed.
Smart Images

Figure CN118972847B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of vehicle networking technology, and specifically to a V2G cross-domain identity authentication method and system based on quantum keys. Background Art
[0002] Vehicle-to-grid (V2G) technology has a significant impact on the environment and energy given the current challenges facing energy and environmental development. Electric vehicles (EVs) and the power grid achieve bidirectional energy transmission under the unified scheduling of smart grids. That is, when the grid load is low, EVs absorb electricity from the grid as energy storage units. When the grid load is high, EVs can release the stored energy back to the grid, thereby helping to balance the grid load and improve the utilization rate of grid energy.
[0003] Despite its enormous potential for energy conservation, V2G technology still faces challenges in practical application. For example, after an EV completes charging within the service range of a charging station, it must send a request for service to the cloud before proceeding to the next charging station. This process involves the transmission of a large amount of information, inevitably exposing data confidentiality, integrity, user privacy, and security attacks. In a V2G network, adversaries can maliciously tamper with transaction information or disrupt information transmission to obtain the owner's personal privacy and disrupt transactions. Therefore, secure communication between the EV and the server is crucial, and the server must provide the EV with anonymous credentials to further protect the owner's personal privacy.
[0004] Currently, when EVs establish communications with certain servers, they typically employ public-key cryptography, which relies on computationally complex techniques such as integer factorization and discrete logarithms. This means the sender encrypts a message using the receiver's public key, and the receiver decrypts it using the private key. The public key is a publicly shared secret key that anyone can obtain and use to encrypt a message, while only the corresponding private key can decrypt it. Due to the limited computing power of traditional computers, some classical cryptographic algorithms cannot be cracked. However, with the advent of quantum computers, these classical cryptographic algorithms are easily crackable, making communication security unsafe and a pressing issue. Summary of the Invention
[0005] The technical problem to be solved by the present invention is: how to improve the security of communication when vehicles are performing cross-domain charging and discharging in a V2G communication scenario.
[0006] To achieve the above object, the present invention provides the following technical solutions:
[0007] The present invention discloses a V2G cross-domain identity authentication method based on quantum key, which includes: a registration phase and a cross-domain identity authentication phase.
[0008] Registration phase: The fog server obtains its own digital certificate DC , the vehicle obtains its own short-term anonymous credentials IOD and long-term anonymous credentials ICD .
[0009] Cross-domain identity authentication stage: When a vehicle enters the domain of another fog server from the domain where one fog server is located and needs to be charged or discharged, the vehicle and the fog server exchange information through digital certificates and anonymous credentials, thereby completing the authentication between the vehicle and the other fog server; among them, in the registration stage and identity authentication stage, the vehicle and the fog server realize message encryption and decryption transmission based on the pre-charged quantum key.
[0010] As a further improvement to the above solution, an initialization phase is also included before the registration phase. The specific process is as follows:
[0011] Unique identifier for the vehicle configuration itself VID , the unique identifier of the fog server configuration itself RID .
[0012] The trusted authority generates corresponding public and private key pairs for the vehicle and fog server respectively and stores them in their respective devices.
[0013] The quantum secret service platform pre-injects several one-to-one corresponding quantum keys into the hardware security modules in the vehicle and fog server respectively. QSK and quantum key identification QSK tag Among them, the quantum secret service platform, vehicle and fog server can all find the corresponding quantum key based on the quantum key identifier.
[0014] The blockchain is set as a private chain, allowing only authorized users to access and operate on-chain data; the fog server is a blockchain node and has the authority to call smart contracts.
[0015] As a further improvement to the above solution, the registration phase includes a fog server registration phase and a vehicle registration phase; wherein the specific process of the fog server registration phase is as follows:
[0016] The fog server sends its unique identifier to the quantum server platform RID ; At the same time, the quantum secret service platform generates a digital certificate for the fog server DC , then concatenate the message body { H ( RID ), H ( DC)} and uploaded to the blockchain; among them, H (·) indicates a hash operation on ·.
[0017] The blockchain will receive the message body { H ( RID ), H ( DC )}Store and generate the corresponding unique identifier Txid1, and send Txid1 to the quantum secret service platform.
[0018] After receiving Txid1, the quantum secret service platform uses a quantum key QSKw Calculation Message Msg and message verification code Mac , send the message body to the fog server { Msg , Mac , QSK tagw , Txid1}; among them, Msg = E QSKw ( DC );
[0019] Mac = HMAC QSKw ( Msg ); E (•) represents an encryption function with · as the key; HMAC (•) represents a message authentication code generation function using · as the key generation function; tagw Quantum key QSK The corresponding quantum key identifier.
[0020] The fog server receives the message body { QSKw , Msg , Mac tagw , Txid1} and it is determined that the receiving time limit has not been exceeded, according to the received QSK tagw Find the corresponding pre-filled quantum key QSK , by calculating the message authentication code QSKw Verification Message Mac’ integrity, if the message Msg Complete use of quantum key Msg Decrypt the message to obtain the digital certificate QSKw , then the fog server calculates H ( DC )and H (Txid1) and sends the message body { H (DC ), H (Txid1)}; where, DC = Mac’ QSKw ( HMAC ).
[0021] The quantum secret service platform receives the message body { H ( Msg ), H (Txid1)} and it is determined that the receiving time limit has not been exceeded, calculate DC And the hash value of Txid1 is H’ ( DC )and H’ (Txid1); if H’ ( DC ) = H ( DC ),
[0022] H’ (Txid1) = H (Txid1), it means the fog server has successfully received DC and Txid1, and the fog server is now registered.
[0023] As a further improvement to the above solution, the specific process of the vehicle registration stage is as follows:
[0024] The vehicle generates quantum random numbers through its own quantum random number generator DC , generate its own short-term anonymous credentials QRNG , using a quantum key IOD Calculation Message QSKe ev and message verification code Msg ev , send the message body { Mac ev , Msg ev , Mac tage};in, QSK = H ( IOD , QRNG );
[0025] VID ev = E QSKe ( Msg , IOD ); QRNG ev = Mac QSKe ( HMACev ).
[0026] The quantum secret service platform receives the message body { Msg ev , Msg ev , Mac tage} and it is determined that the receiving time limit has not been exceeded, the received QSK tage Find the corresponding quantum key QSK , by calculating the message authentication code QSKe ev ’ Verification Message Mac ev integrity, if the message Msg ev Complete use Msg Decrypt the message to get QSKe , and then calculate the vehicle's long-term anonymity credentials IOD , and send the message body { H ( ICD ), H ( ICD )};
[0027] in, IOD ( ICD=H , QRNG ); IOD ev ’ = Mac QSKe ( HMAC ev ).
[0028] The blockchain will receive the message body { H ( Msg ), H ( ICD )}Store and generate the corresponding unique identifier Txid2, and send Txid2 to the quantum secret service platform.
[0029] After receiving Txid2, the quantum secret service platform uses a quantum key IOD Calculation Message QSKe’ f and message verification code Msg f , send the message body to the vehicle { Mac f , Msg f , Txid2, Mac tage’};
[0030] in, QSK f = E QSKe’ ( Msg ), ICD f = Mac QSKe’ ( HMAC f ).
[0031] The vehicle receives the message body { Msg f , Msg f , Txid2, Mac tage’} and it is determined that the receiving time limit has not been exceeded, the received QSK tage’ Find the corresponding quantum key QSK , by calculating the message authentication code QSKe’ f ’ Verification Message Mac f integrity, if the message Msg f Complete use Msg Decrypt the message to get [[ID= , and send the message body { H ( ), H (Txid2)}; where, f ’ = QSKe’ ( f ).
[0032] The quantum secret service platform receives the message body { H ( ), H (Txid2)} and it is determined that the receiving time limit has not been exceeded, calculate And the hash value of Txid2 is H’ ( )and H’ (Txid2);
[0033] like H’ ( ) = H ( ), H’ (Txid2) = H (Txid2), it means the vehicle has successfully received and Txid2, the vehicle is now registered.
[0034] As a further improvement to the above solution, an intra-domain identity authentication phase is also included. The specific process is as follows:
[0035] The fog server broadcasts its unique identification and digital certificate to the vehicles in the domain, namely { , }.
[0036] After receiving the digital certificate, the vehicle verifies the identity of the fog server and calculates the session key β , using a quantum key Calculation Message v and message verification code v , send the message body to the fog server { v , v , Txid2};
[0037] in, β=H ( , , ), is the fog server public key;
[0038] v = E QSKv ( , β , H ( )); v = QSKv ( v ).
[0039] The fog server receives the message body { v , v , Txid2} and after determining that the set receiving time limit has not been exceeded, obtain Txid2 and send a search request to the blockchain.
[0040] After receiving the search request, if the blockchain finds the corresponding H ( ), then H ( ) is fed back to the fog server.
[0041] Fog Server tagv Find the corresponding quantum key , and then calculate the message verification code v ’ Verification Message v integrity, if the message v Complete use of quantum key Decrypt and obtain and
[0042] H ( ), then verify H ( ) to confirm the legitimacy of the vehicle identity; if the vehicle identity verification is successful, the session key is used β Calculation Message u and message verification code u , send the message body to the vehicle { u , u};in, v ’ = QSKv ( v ); u = E β ( H ( ), ); u = β ( u ); is the smart contract address.
[0043] The vehicle receives the message body { u , u} and after determining that the reception time limit has not been exceeded, the message verification code is calculated u ’ Verification Message u integrity, if the message u Complete using session key βDecrypt the message and obtain the smart contract address , thus completing the vehicle domain identity authentication;
[0044] in, u ’ = β ( u ).
[0045] As a further improvement to the above solution, the specific process of the cross-domain identity authentication stage is as follows:
[0046] Vehicle Pass Session Key β Calculation Message q and message authentication codes q , send the message body to the fog server i before cross-domain { q , q}; q = E β ( , H ( )); q = β ( q ).
[0047] Fog server i receives the message body { q , q} and after determining that the reception time limit has not been exceeded, the message verification code is calculated q ’ Verification Message q integrity, if the message q Complete using session key β Decrypt the message and obtain H ( ) uploaded to the blockchain; among them, q ’ = β ( q ).
[0048] The blockchain will receive H ( ) stores and generates the corresponding unique identifier Txid3, and sends Txid3 to fog server i.
[0049] Fog server i sends the received Txid3 to the vehicle.
[0050] The vehicle uses a quantum key Calculation Message w and message verification code w , sends the first message body to the fog server j after the cross-domain; the first message body is { w , w , Txid3, H (Txid3), tagi};
[0051] w = E QSKi ( , , H ( , )); w = QSKi ( w ).
[0052] After receiving the first message body and determining that it has not exceeded the set receiving time limit, fog server j sends Txid3 in the first message body to the blockchain.
[0053] According to the received Txid3, the blockchain will store the corresponding message { H ( )} is sent to fog server j.
[0054] Fog server j receives { H ( )}, according to tagi Find the corresponding quantum key , and then use the key Calculate message authentication code w ’ To verify the message w integrity, if the message w Complete use Decrypt the message and obtain and , check its hash value H ( , )and H ( ) is correct. If the hash value is correct, the authentication between the vehicle and the fog server j is completed;
[0055] in, w ’ = QSKi ( w ).
[0056] As a further improvement to the above solution, a power review stage is also included; the specific process of the power review stage is as follows:
[0057] Fog server obtains charging information and charging information , send the message body to the power server { , , }; Among them, the fog server and the power server are connected by wire.
[0058] The power server receives the message body { , , } and after determining that the set receiving time limit has not been exceeded, obtain the charging information in the message body and charging information , and update the stored content accordingly, thereby completing the power review.
[0059] As a further improvement to the above solution, after the registration phase, a revocation phase is also included. The revocation phase is used to terminate the smart contract operation for the vehicle node information that is about to leave the fog server domain. The specific process of the revocation phase is as follows:
[0060] When a vehicle needs to leave the current fog server, it uses the session key β Generate Message x , send the message body to the fog server { x , Txid2}; where x = E β ( , H ( )).
[0061] The fog server receives the message body { x , Txid2} and after determining that the set reception time limit has not been exceeded, the session key is used β Will x Decrypt and obtain the corresponding storage information of Txid2 in the blockchain. H’ ( ),judge
[0062] H’ ( )and x in H ( ) are equal, if they are equal, the smart contract is terminated, otherwise the process ends.
[0063] As a further improvement to the above solution, the message sender sets the sending timestamp in the message body. T A ; The message receiver generates a receiving timestamp when receiving the message body T B , and judge whether it satisfies T B - T A ≤Δ T If yes, it is determined that the set receiving time limit has not been exceeded; Δ T is the preset time difference threshold.
[0064] The present invention also discloses a V2G cross-domain identity authentication system based on quantum key, including a trusted authorization agency, a power server, a quantum secret service platform, a blockchain, a fog server and a vehicle. The system applies the V2G cross-domain identity authentication method based on quantum key as described above.
[0065] Compared with the prior art, the present invention has the following beneficial effects:
[0066] 1. The present invention uses quantum keys to encrypt communications, making the overall communication resistant to quantum computing attacks. At the same time, it adopts dynamic anonymity, that is, a combination of short-term anonymous credentials and long-term anonymous credentials to ensure the privacy of vehicle identity during communication. This ensures the security of vehicle communication during cross-domain charging and discharging in V2G communication scenarios, and solves the problem of repeated identity authentication.
[0067] 2. The short-term anonymous credential of this invention is generated by the quantum random number generated by the quantum random number generator in the vehicle and the vehicle's unique identifier. Therefore, the vehicle can change its short-term anonymous credential at any time. The short-term anonymous credential is unique, making it impossible for an adversary to maliciously disguise itself as a legitimate vehicle. The long-term anonymous credential is generated by the quantum secret service platform and uploaded to the blockchain, ensuring that legitimate vehicles in the communication group can be traced at any time.
[0068] 3. The present invention uses blockchain technology to store information, and ensures the security of data by leveraging the decentralized and tamper-proof characteristics of blockchain.
[0069] 4. With the continuous increase in charging equipment, in order to reduce the computing pressure of the cloud server, the present invention uses fog servers to provide distributed services for vehicle users, edge cloud server data storage and computing, and can quickly respond to vehicle request information.
[0070] 5. The present invention also sets a timestamp in the message body, determines the reliability of the message based on the received time difference, and uses a message authentication code to verify the message integrity, thereby further improving the security of identity authentication in V2G communication scenarios. BRIEF DESCRIPTION OF THE DRAWINGS
[0071] This is a framework diagram of a quantum key-based V2G cross-domain identity authentication system in an embodiment of the present invention.
[0072] This is a signaling diagram of the fog server registration phase in an embodiment of the present invention.
[0073] This is a signaling diagram of the vehicle registration phase in an embodiment of the present invention.
[0074] This is a signaling diagram of the intra-domain identity authentication phase in an embodiment of the present invention.
[0075] This is a signaling diagram of the power review stage in an embodiment of the present invention.
[0076] This is a signaling diagram of the revocation phase in an embodiment of the present invention. DETAILED DESCRIPTION
[0077] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only 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 making creative efforts are within the scope of protection of the present invention.
[0078] See also ,This embodiment provides a V2G cross-domain identity authentication system based on quantum key, which includes a trusted authorization agency, a power server, a quantum secret service platform, a blockchain, a fog server and a vehicle.
[0079] The V2G cross-domain authentication system described above can utilize a quantum key-based V2G cross-domain authentication method. This method can include six phases: initialization, registration, intra-domain authentication, cross-domain authentication, power review, and revocation. It should be noted that the six phases are not necessarily executed in a strictly sequential order.
[0080] The definitions of symbols involved in this embodiment can be referred to in Table 1 below.
[0081] Table 1: Definition of relevant symbols
[0082] ;
[0083] The initialization stage may specifically include steps S11 to S14.
[0084] S11. Unique identifier of the vehicle configuration itself , the unique identifier of the fog server configuration itself .
[0085] S12. The trusted authority generates corresponding public and private key pairs for the vehicle and fog server respectively and stores them in their respective devices.
[0086] S13. The quantum secret service platform pre-injects several one-to-one corresponding quantum keys into the hardware security modules in the vehicle and fog server respectively. and quantum key identification tag Among them, the quantum secret service platform, vehicle and fog server can all find the corresponding quantum key based on the quantum key identifier.
[0087] S14. Set the blockchain as a private chain, allowing only authorized users to access and operate on-chain data; the fog server is a blockchain node and has the authority to call smart contracts.
[0088] Registration phase: The fog server obtains its own digital certificate , the vehicle obtains its own short-term anonymous credentials and long-term anonymous credentials In this embodiment, the registration phase may include a fog server registration phase and a vehicle registration phase.
[0089] See also ,The specific process of the registration phase of the fog server is as follows, namely steps S211 to S215.
[0090] S211. The fog server sends its unique identifier to the quantum cryptographic service platform ; At the same time, the quantum secret service platform generates a digital certificate for the fog server , then concatenate the message body { H ( ), H ( )} and uploaded to the blockchain; among them, H (·) indicates a hash operation on ·.
[0091] S212. The blockchain receives the message body { H ( ), H ( )}Store and generate the corresponding unique identifier Txid1, and send Txid1 to the quantum secret service platform.
[0092] S213. After receiving Txid1, the quantum secret service platform uses a quantum key Calculation Message and message verification code , send the message body to the fog server { , , tagw , Txid1, T 1}; among them,
[0093] = E QSKw ( ); = QSKw ( ); T 1 is the calculation of quantum secret service platform The timestamp generated when E (•) represents an encryption function with · as the key; (•) represents a message authentication code generation function using · as the key generation function; tagw Quantum key The corresponding quantum key identifier.
[0094] S214. The fog server receives the message body { , , tagw , Txid1, T 1}, determine whether it satisfies T 1’ - T 1≤Δ T If it is, it means the time difference is small and reliable. Otherwise, it means the time difference is large and the fog server will not process it further. The same applies to other subsequent timestamps. tagw Find the corresponding pre-filled quantum key , by calculating the message authentication code Verification Message integrity, if the message Complete use of quantum key Decrypt the message to obtain the digital certificate and Txid1, then the fog server calculates H ( )and H (Txid1) and sends the message body { H ( ), H (Txid1), T 2}; among them, T 1' is received by the fog server containing T 1 is the timestamp generated when the message body is generated, Δ T is the preset time difference threshold; = QSKw ( ); T 2 is fog server computing H ( )and H (Txid1) is the timestamp generated.
[0095] It should be noted that if the message verification code = , then the message Complete, the same applies to other message verification codes.
[0096] S215. The quantum secret service platform receives the message body { H ( ), H (Txid1), T 2}, determine whether it satisfies T 2'- T 2≤Δ T If so, calculate And the hash value of Txid1 is H’ ( )and H’ (Txid1); if
[0097] H’( ) = H ( ), H’ (Txid1) = H (Txid1), it means the fog server has successfully received and Txid1, and the fog server is now registered.
[0098] See also The specific process of the vehicle registration stage is as follows, namely steps S221~S226.
[0099] S221. The vehicle generates quantum random numbers through its own quantum random number generator , generate its own short-term anonymous credentials , using a quantum key Calculation Message ev and message verification code ev , send the message body { ev , ev , tage , T 3}; among them, = H ( , );
[0100] ev = E QSKe ( , ); ev = QSKe ( ev ); T 3 is to generate quantum random numbers The timestamp generated when
[0101] S222. The quantum secret service platform receives the message body { ev , ev , tage , T 3}, determine whether it satisfies T 3 ’ - T 3≤Δ T If so, then according to the received tage Find the corresponding quantum key , by calculating the message authentication code ev ’ Verification Message Msg ev integrity, if the message Msg ev Complete use QSKe Decrypt the message to get IOD , and then calculate the vehicle's long-term anonymity credentials ICD , and send the message body { H ( ICD ), H ( IOD )};in, T 3 ’ The quantum secret service platform receives T 3. The timestamp generated when the message body is generated;
[0102] ICD = H ( QRNG , IOD ); Mac ev ’ = HMAC QSKe ( Msg ev ).
[0103] S223. The blockchain receives the message body { H ( ICD ), H ( IOD )}Store and generate the corresponding unique identifier Txid2, and send Txid2 to the quantum secret service platform.
[0104] S224. After receiving Txid2, the quantum secret service platform uses a quantum key QSKe’ Calculation Message Msg f and message verification code Mac f , send the message body to the vehicle { T 4. Msg f , Mac f , Txid2, QSK tage’};in, T 4 is the quantum secret service platform computing message Msg f and message verification code Mac fThe timestamp generated when
[0105] Msg f = E QSKe’ ( ICD ), Mac f = HMAC QSKe’ ( Msg f ).
[0106] S225. The vehicle receives the message body { T 4. Msg f , Mac f , Txid2, QSK tage’}, judge whether it satisfies T 4 ’ - T 4≤Δ T If so, then according to the received QSK tage’ Find the corresponding quantum key QSKe’ , by calculating the message authentication code Mac f ’ Verification Message Msg f integrity, if the message Msg f Complete use QSKe’ Decrypt the message to get ICD , and send the message body { H ( ICD ), H (Txid2), T 5}; among them, T 4 ’ For vehicles receiving T 4. The timestamp generated when the message body is generated; T 5 for vehicle calculation H ( ICD )and H (Txid2) timestamp generated; Mac f ’ = HMAC QSKe’ ( Msg f ).
[0107] S226. The quantum secret service platform receives the message body { H ( ICD ),H (Txid2), T 5}, determine whether it satisfies T 5 ’ - T 5≤Δ T If so, calculate ICD And the hash value of Txid2 is H’ ( ICD )and H’ (Txid2); if
[0108] H’ ( ICD ) = H ( ICD ), H’ (Txid2) = H (Txid2), it means the vehicle has successfully received ICD and Txid2, the vehicle is now registered; T 5 ’ The quantum secret service platform receives T 5. The timestamp when the message body was generated.
[0109] See also Figure 4 In the intra-domain identity authentication phase, the specific process is as follows, namely steps S31 to S36.
[0110] S31. The fog server broadcasts its unique identifier and digital certificate to the vehicles in the domain, namely { RID , DC}.
[0111] S32. After receiving the digital certificate, the vehicle verifies the identity of the fog server and then generates a timestamp. T 6. Calculate the session key β , using a quantum key QSKv Calculation Message Msg v and message verification code Mac v , send the message body to the fog server { Msg v , Mac v , T 6, Txid2, QSK tagv};in, β=H ( DC , IOD , pk ), pk is the fog server public key;
[0112] Msg v =E QSKv ( IOD , β , H ( IOD )); Mac v = HMAC QSKv ( Msg v ).
[0113] S33. The fog server receives the message body { Msg v , Mac v , T 6, Txid2, QSK tagv}, judge whether it satisfies T 6 ’ - T 6≤Δ T If yes, get Txid2 and send a search request to the blockchain; T 6 ’ The fog server receives T 6 The timestamp when the message body was generated.
[0114] S34. After receiving the search request, if the blockchain finds the corresponding H ( IOD ), then H ( IOD ) is fed back to the fog server.
[0115] S35. Fog server based on QSK tagv Find the corresponding quantum key QSKv , and then calculate the message verification code Mac v ’ Verification Message Msg v integrity, if the message Msg v Complete use of quantum key QSKv Decrypt and obtain IOD and H ( IOD ), then verify H ( IOD ) to confirm the legitimacy of the vehicle identity; if the vehicle identity verification is successful, the fog server generates a timestamp T 7. Using session keys β Calculation Message Msg u and message verification codeMac u , send the message body to the vehicle { Msg u , Mac u , T 7}; among them, [[ID= v ’ = QSKv ( v );
[0116] u = E β ( H ( ), ); u = β ( u ); is the smart contract address.
[0117] S36. The vehicle receives the message body { u , u , T 7}, determine whether it satisfies T 7 ’ - T 7≤Δ T If so, then calculate the message verification code u ’ Verification Message u integrity, if the message u Complete using session key β Decrypt the message and obtain the smart contract address , thus completing the vehicle domain identity authentication; among them, T 7 ’ For vehicles receiving T 7. The timestamp generated when the message body is generated; u ’ = β ( u ).
[0118] Cross-domain identity authentication stage: When a vehicle enters the domain of another fog server from the domain where one fog server is located and needs to be charged or discharged, the vehicle and the fog server exchange information through the digital certificate and the anonymous credential, thereby completing the authentication between the vehicle and the other fog server; wherein, in the registration stage and the identity authentication stage, the vehicle and the fog server realize the encryption and decryption transmission of messages based on the pre-charged quantum key.
[0119] In this embodiment, the specific process of the cross-domain identity authentication stage is as follows, namely S41 to S48.
[0120] S41. Vehicle generates timestamp T 8. Through session key β Calculation Message q and message authentication codes q , send the message body to the fog server i before cross-domain { q , q , T 8};
[0121] q = E β ( , H ( )); q = β ( q ).
[0122] S42. Fog server i receives the message body { q , q , T 8}, determine whether it satisfies T 8 ’ - T 8≤Δ T If so, then calculate the message verification code q ’ Verification Message q integrity, if the message q Complete using session key β Decrypt the message and obtain H ( ) uploaded to the blockchain; among them,T 8 is the fog server i receives T 8. The timestamp generated when the message body is generated; q ’ = β ( q ).
[0123] S43. Blockchain will receive H ( ) stores and generates the corresponding unique identifier Txid3, and sends Txid3 to fog server i.
[0124] S44. Fog server i sends the received Txid3 to the vehicle.
[0125] S45. Vehicle generates timestamp T 9. Using a quantum key Calculation Message w and message verification code w , sends the first message body to the fog server j after the cross-domain; the first message body is { w , w , Txid3, H (Txid3), T 9, tagi}; w = E QSKi ( , , H ( , ));
[0126] w = QSKi ( w ).
[0127] S46. After receiving the first message body, fog server j determines whether T 9 ’ - T 9≤Δ T If yes, then send Txid3 in the first message body to the blockchain; T 9 ’It is the timestamp generated when the fog server receives the first message body.
[0128] S47. The blockchain stores the corresponding message { H ( )} is sent to fog server j.
[0129] S48. Fog server j receives { H ( )}, according to tagi Find the corresponding quantum key , and then use the key Calculate message authentication code w ’ To verify the message w integrity, if the message w Complete use Decrypt the message and obtain and , check its hash value H ( , )and
[0130] H ( ) is correct. If the hash value is correct, the authentication between the vehicle and the fog server j is completed; w ’ = QSKi ( w ).
[0131] In addition, the fog server needs to frequently update the charging and billing information to the power server to prevent malicious tampering after the adversary invades, so a power review phase is required.
[0132] See also The specific process of the power review stage is as follows, namely steps S51~S52.
[0133] S51. Fog server generates timestamp T 10 , get charging information and charging information , send the message body to the power server { , , , T 10}; Among them, there is a wired connection between the fog server and the power server, and this communication process is considered safe in the present invention.
[0134] S52. The power server receives the message body { , , , T 10}, judge whether it satisfies T 10 ’ - T 10 ≤Δ T If yes, get the charging information in the message body and charging information , and update the stored content accordingly, thereby completing the power review.
[0135] In a communication domain, vehicle nodes often leave, so it is necessary to terminate the smart contract operation for the vehicle node information that is about to leave the domain.
[0136] See also The specific process of the revocation stage of the present invention is as follows, namely steps S61~S62.
[0137] S61. When the vehicle needs to leave the current fog server, a timestamp is generated. T 11 , using a session key β Generate Message x , send the message body to the fog server { T 11 , x , Txid2};
[0138] in, x = E β ( , H ( ), T 11 ).
[0139] S62. The fog server receives the message body { T 11 , x , Txid2}, determine whether it satisfies T 11 ’ - T 11 ≤Δ T, then use the session key β Will x Decrypt and obtain the corresponding storage information of Txid2 in the blockchain.
[0140] H’ ( ),judge H’ ( )and x in H ( ) are equal, if they are equal, the smart contract is terminated, otherwise the process ends; T 11 ’ The fog server receives T 11 The timestamp when the message body was generated.
[0141] In summary, the vehicle in the present invention uses long-term and short-term anonymous credentials for information exchange, ensuring the security of the vehicle's own private information. At the same time, quantum random numbers are used to generate anonymous credentials, making the anonymous credentials more random and unable to be forged by the enemy. In addition, the present invention combines the use of quantum keys for encryption, ensuring that the communicating parties in the present invention can resist the attack of quantum computers during communication, thereby ensuring the security of communication. The present invention uses blockchain technology to store information, and the decentralized and tamper-proof characteristics of blockchain ensure the security of data. The present invention uses fog servers to complete intra-domain and cross-domain authentication of vehicles, reducing the computing pressure of the central cloud server.
[0142] The above description is only a preferred specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any technician familiar with the technical field, within the technical scope disclosed by the present invention, who makes equivalent replacements or changes based on the technical solution and inventive concept of the present invention, should be covered by the scope of protection of the present invention.
Claims
1. A V2G cross-domain identity authentication method based on quantum key, characterized in that: include: Registration phase: The fog server obtains its own digital certificate DC , the vehicle obtains its own short-term anonymous credentials IOD and long-term anonymous credentials ICD ; Cross-domain identity authentication stage: When a vehicle enters another fog server domain from one fog server domain and needs to be charged or discharged, the vehicle and the fog server exchange information through digital certificates and anonymous credentials to complete the authentication between the vehicle and the other fog server; in the registration stage and identity authentication stage, the vehicle and the fog server implement message encryption and decryption transmission based on the pre-charged quantum key; The specific process of the cross-domain identity authentication stage is as follows: Vehicle Pass Session Key β Calculation Message Msg q and message authentication code Mac q , send the message body to the fog server i before the cross-domain { Msg q , Mac q };in, Msg q = E β ( IOD , H ( IOD )); Mac q = HMAC β ( Msg q ); H (·) indicates hash operation on ·; E (•) represents an encryption function using · as the key; HMAC (•) represents a message authentication code generation function using · as a key generation function; When fog server i receives the message body { Msg q , Mac q } and after determining that the receiving time limit has not been exceeded, the message verification code is calculated Mac q ’ Verification Message Msg q integrity, if the message Msg q Complete using session key β Decrypt the message and obtain H ( IOD ) is uploaded to the blockchain; among them, Mac q ’ = HMAC β ( Msg q ); The blockchain will receive H ( IOD ) Store and generate the corresponding unique identifier Txid3, and send Txid3 to fog server i; Fog server i sends the received Txid3 to the vehicle; The vehicle uses a quantum key QUR Calculation Message Msg w and message verification code Mac w , sends the first message body to the fog server j after the cross-domain; the first message body is { Msg w , Mac w ,Txid3, H (Txid3), QSK tagi }; Msg w = E QSKi ( IOD , QRNG , H ( IOD , QRNG )); Mac w = HMAC QSKi ( Msg w ); QSK tagi for QUR The corresponding quantum key identifier; QRNG Quantum random numbers generated for the vehicle; After receiving the first message body and determining that it has not exceeded the set receiving time limit, fog server j sends Txid3 in the first message body to the blockchain; According to the received Txid3, the blockchain will store the corresponding message { H ( IOD )} sent to fog server j; When fog server j receives { H ( IOD )}, according to QSK tagi Find the corresponding quantum key QUR , and then use the key QUR Calculate the message verification code Mac w ’ To verify the message Msg w integrity, if the message Msg w Complete use QUR Decrypt the message and obtain IOD and QRNG , check its hash value H ( IOD , QRNG )and H ( IOD ) is correct. If the hash value is correct, the authentication between the vehicle and the fog server j is completed; Mac w ’ = HMAC QSKi ( Msg w ).
2. The V2G cross-domain identity authentication method based on quantum key according to claim 1 is characterized in that: Before the registration phase, there is also an initialization phase, the specific process is as follows: Unique identifier for the vehicle configuration itself VID , the unique identifier of the fog server configuration itself RID ; The trusted authority generates corresponding public and private key pairs for the vehicle and fog server respectively and stores them in their respective devices; The quantum secret service platform pre-injects several one-to-one corresponding quantum keys into the hardware security modules in the vehicle and fog server respectively. QSK And quantum key identification QSK tag ; Among them, the quantum secret service platform, vehicles and fog servers can all find the corresponding quantum key according to the quantum key identifier; The blockchain is set as a private chain, allowing only authorized users to access and operate the data on the chain; the fog server is a blockchain node and has the authority to call smart contracts.
3. The V2G cross-domain identity authentication method based on quantum key according to claim 2 is characterized in that: The registration phase includes the fog server registration phase and the vehicle registration phase; wherein the specific process of the fog server registration phase is as follows: The fog server sends its unique identifier to the quantum server platform RID ; At the same time, the quantum secret service platform generates a digital certificate for the fog server DC , then concatenate the message body { H ( RID ), H ( DC )} and upload it to the blockchain; The blockchain will receive the message body { H ( RID ), H ( DC )}Store and generate the corresponding unique identifier Txid1, and send Txid1 to the quantum secret service platform; After receiving Txid1, the quantum secret service platform uses a quantum key QUR Calculation Message Msg and message verification code Mac , send the message body to the fog server { Msg , Mac , QSK tagw ,Txid1}; where Msg = E QSKw ( DC ); Mac = HMAC QSKw ( Msg ); QSK tagw For quantum keys QUR The corresponding quantum key identifier; The fog server receives the message body { Msg , Mac , QSK tagw , Txid1} and it is determined that the receiving time limit has not been exceeded, according to the received QSK tagw Find the corresponding pre-filled quantum key QUR , by calculating the message verification code Mac' Verification Message Msg integrity, if the message Msg Complete use of quantum key QUR Decrypt the message to get the digital certificate DC , then the fog server calculates H ( DC )and H (Txid1) and send the message body { H ( DC ), H (Txid1)}; where Mac' = HMAC QSKw ( Msg ); The quantum secret service platform receives the message body { H ( DC ), H (Txid1)} and it is determined that the receiving time limit has not been exceeded, calculate DC And the hash value of Txid1 is H’ ( DC )and H’ (Txid1); if H’ ( DC )= H ( DC ), H’ (Txid1)= H (Txid1), it means the fog server has successfully received DC and Txid1, and the fog server has completed registration.
4. The V2G cross-domain identity authentication method based on quantum key according to claim 3 is characterized in that: The specific process of the vehicle registration stage is as follows: The vehicle generates quantum random numbers through its own quantum random number generator QRNG , generate its own short-term anonymous credentials IOD , using a quantum key QUR Calculation Message Msg ev and message verification code Mac ev , send the message body { Msg ev , Mac ev , QSK tage };in, IOD = H ( QRNG , VID ); Msg ev = E QSKe ( IOD , QRNG ); Mac ev = HMAC QSKe ( Msg ev ); The quantum secret service platform receives the message body { Msg ev , Mac ev , QSK tage } and it is determined that the receiving time limit has not been exceeded, according to the received QSK tage Find the corresponding quantum key QUR , by calculating the message verification code Mac ev ’ Verification Message Msg ev integrity, if the message Msg ev Complete use QUR Decrypt the message to get IOD , and then calculate the vehicle's long-term anonymity credentials ICD , and send the message body to the blockchain { H ( ICD ), H ( IOD )};in, ICD=H ( QRNG , IOD ); Mac ev ’ = HMAC QSKe ( Msg ev ); The blockchain will receive the message body { H ( ICD ), H ( IOD )}Store and generate the corresponding unique identifier Txid2, and send Txid2 to the quantum secret service platform; After receiving Txid2, the quantum secret service platform uses a quantum key QUR Calculation Message Msg f and message verification code Mac f , send a message body to the vehicle { Msg f , Mac f ,Txid2, QSK tage’ };in, Msg f = E QSKe’ ( ICD ), Mac f = HMAC QSKe’ ( Msg f ); The vehicle receives the message body { Msg f , Mac f ,Txid2, QSK tage’ } and it is determined that the receiving time limit has not been exceeded, according to the received QSK tage’ Find the corresponding quantum key QUR , by calculating the message verification code Mac f ’ Verification Message Msg f integrity, if the message Msg f Complete use QUR Decrypt the message to get ICD , and send the message body { H ( ICD ), H (Txid2)}; where Mac f ’ = HMAC QSKe’ ( Msg f ); The quantum secret service platform receives the message body { H ( ICD ), H (Txid2)} and it is determined that the receiving time limit has not been exceeded, calculate ICD And the hash value of Txid2 is H’ ( ICD )and H’ (Txid2); if H’ ( ICD )= H ( ICD ), H’ (Txid2)= H (Txid2), it means the vehicle has successfully received ICD and Txid2, the vehicle is now registered.
5. The V2G cross-domain identity authentication method based on quantum key according to claim 4 is characterized in that: It also includes the intra-domain identity authentication phase, the specific process is as follows: The fog server broadcasts its unique identification and digital certificate to the vehicles in the domain, that is, { RID , DC }; After receiving the digital certificate, the vehicle verifies the identity of the fog server and calculates the session key β , using a quantum key QUR Calculation Message Msg v and message verification code Mac v , send the message body to the fog server { Msg v , Mac v ,Txid2}; in, β=H ( DC , IOD , pk ), pk is the public key of the fog server; Msg v = E QSKv ( IOD , β , H ( IOD )); Mac v = HMAC QSKv ( Msg v ); The fog server receives the message body { Msg v , Mac v ,Txid2} and after determining that it has not exceeded the set receiving time limit, obtain Txid2 and send a search request to the blockchain; After receiving the search request, if the blockchain finds the corresponding H ( IOD ), then H ( IOD ) is fed back to the fog server; Fog server based QSK tagv Find the corresponding quantum key QUR , and then calculate the message verification code Mac v ’ Verification Message Msg v integrity, if the message Msg v Complete use of quantum key QUR Decryption and acquisition IOD and H ( IOD ), then verify H ( IOD ) to confirm the legitimacy of the vehicle identity; if the vehicle identity authentication is successful, the session key is used β Calculation Message Msg u and message verification code Mac u , send a message body to the vehicle { Msg u , Mac u };in, Mac v ’ = HMAC QSKv ( Msg v ); Msg u = E β ( H ( IOD ), SCA ); Mac u = HMAC β ( Msg u ); SCA is the smart contract address; The vehicle receives the message body { Msg u , Mac u } and after determining that the receiving time limit has not been exceeded, the message verification code is calculated Mac u ’ Verification Message Msg u integrity, if the message Msg u Complete using session key β Decrypt the message and obtain the smart contract address SCA , so far the vehicle domain identity authentication is completed; among them, Mac u ’ = HMAC β ( Msg u ).
6. The V2G cross-domain identity authentication method based on quantum key according to claim 5 is characterized in that: It also includes the power review stage; the specific process of the power review stage is as follows: Fog server obtains charging information Pm and charging information Cm , send the message body to the power server { Pm , Cm , RID }; Among them, the fog server and the power server are connected by wire; The power server receives the message body { Pm , Cm , RID } and after determining that the set receiving time limit has not been exceeded, obtain the charging information in the message body Pm and charging information Cm , and the stored content is updated accordingly, thereby completing the power review.
7. The V2G cross-domain identity authentication method based on quantum key according to claim 6 is characterized in that: After the registration phase, there is also a revocation phase, which is used to terminate the smart contract operation for the vehicle node information that is about to leave the domain where the fog server is located; the specific process of the revocation phase is as follows: When a vehicle needs to leave the current fog server, it uses the session key β Generate Message Msg x , send the message body to the fog server { Msg x ,Txid2}; in, Msg x = E β ( SCA , H ( IOD )); The fog server receives the message body { Msg x , Txid2} and after determining that the receiving time limit has not been exceeded, the session key is used β Will Msg x Decrypt and obtain the corresponding storage information of Txid2 in the blockchain. H’ ( IOD ),judge H’ ( IOD )and Msg x In H ( IOD ) are equal, if they are equal, the smart contract is terminated, otherwise the process ends.
8. The V2G cross-domain identity authentication method based on quantum key according to any one of claims 1 to 7, characterized in that: The message sender sets the sending timestamp in the message body. T A ; The message receiver generates a receiving timestamp when receiving the message body T B , and determine whether it satisfies T B - T A ≤∆ T If yes, it is determined that the set receiving time limit has not been exceeded; ∆ T is the preset time difference threshold.
9. A V2G cross-domain identity authentication system based on quantum key, including a trusted authorization agency, a power server, a quantum secret service platform, a blockchain, a fog server and a vehicle, characterized in that: The system applies the V2G cross-domain identity authentication method based on quantum key as described in any one of claims 1 to 8.
