CN116566594A - Equipment control method, equipment and distributed digital key system - Google Patents
Equipment control method, equipment and distributed digital key system Download PDFInfo
- Publication number
- CN116566594A CN116566594A CN202210114846.2A CN202210114846A CN116566594A CN 116566594 A CN116566594 A CN 116566594A CN 202210114846 A CN202210114846 A CN 202210114846A CN 116566594 A CN116566594 A CN 116566594A
- Authority
- CN
- China
- Prior art keywords
- information
- key
- application
- related information
- key related
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 101
- 238000000586 desensitisation Methods 0.000 claims abstract description 142
- 238000004891 communication Methods 0.000 claims abstract description 57
- 238000012795 verification Methods 0.000 claims description 56
- 230000004044 response Effects 0.000 claims description 41
- 238000005516 engineering process Methods 0.000 claims description 16
- 238000004590 computer program Methods 0.000 claims description 9
- 238000012546 transfer Methods 0.000 claims description 9
- 230000008569 process Effects 0.000 description 24
- 238000004422 calculation algorithm Methods 0.000 description 23
- 238000010586 diagram Methods 0.000 description 7
- 230000003993 interaction Effects 0.000 description 7
- 150000003839 salts Chemical class 0.000 description 6
- 230000006870 function Effects 0.000 description 5
- 239000006185 dispersion Substances 0.000 description 4
- 238000001994 activation Methods 0.000 description 3
- 238000012545 processing Methods 0.000 description 3
- 230000003068 static effect Effects 0.000 description 3
- 230000004913 activation Effects 0.000 description 2
- 230000003190 augmentative effect Effects 0.000 description 2
- 230000008901 benefit Effects 0.000 description 2
- 238000011161 development Methods 0.000 description 2
- 230000018109 developmental process Effects 0.000 description 2
- 238000011156 evaluation Methods 0.000 description 2
- 230000000977 initiatory effect Effects 0.000 description 2
- 230000008520 organization Effects 0.000 description 2
- 230000001360 synchronised effect Effects 0.000 description 2
- 102000003712 Complement factor B Human genes 0.000 description 1
- 108090000056 Complement factor B Proteins 0.000 description 1
- 230000032683 aging Effects 0.000 description 1
- 238000004458 analytical method Methods 0.000 description 1
- 238000003491 array Methods 0.000 description 1
- 230000005540 biological transmission Effects 0.000 description 1
- 238000004364 calculation method Methods 0.000 description 1
- 230000001413 cellular effect Effects 0.000 description 1
- 230000001419 dependent effect Effects 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 230000002427 irreversible effect Effects 0.000 description 1
- 238000013507 mapping Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000012954 risk control Methods 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/08—Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
- H04L9/0894—Escrow, recovery or storing of secret information, e.g. secret key escrow or cryptographic key storage
-
- G—PHYSICS
- G07—CHECKING-DEVICES
- G07C—TIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
- G07C9/00—Individual registration on entry or exit
-
- G—PHYSICS
- G07—CHECKING-DEVICES
- G07C—TIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
- G07C9/00—Individual registration on entry or exit
- G07C9/00174—Electronically operated locks; Circuits therefor; Nonmechanical keys therefor, e.g. passive or active electrical keys or other data carriers without mechanical keys
- G07C9/00896—Electronically operated locks; Circuits therefor; Nonmechanical keys therefor, e.g. passive or active electrical keys or other data carriers without mechanical keys specially adapted for particular uses
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/08—Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/32—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L9/00—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
- H04L9/32—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials
- H04L9/3271—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials using challenge-response
- H04L9/3273—Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols including means for verifying the identity or authority of a user of the system or for message authentication, e.g. authorization, entity authentication, data integrity or data verification, non-repudiation, key authentication or verification of credentials using challenge-response for mutual authentication
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W4/00—Services specially adapted for wireless communication networks; Facilities therefor
- H04W4/30—Services specially adapted for particular environments, situations or purposes
- H04W4/40—Services specially adapted for particular environments, situations or purposes for vehicles, e.g. vehicle-to-pedestrians [V2P]
Landscapes
- Engineering & Computer Science (AREA)
- Computer Security & Cryptography (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Lock And Its Accessories (AREA)
Abstract
The embodiment of the application provides a device control method, device and distributed digital key system, and relates to the technical field of communication. The method is applied to a first device and a second device, wherein the first device stores desensitization information in the related information of a first secret key; sensitive information in the first key related information and the second key related information are stored in a secure element of the second device. The method comprises the following steps: the first device sends desensitization information to the second device; the second device combines the desensitized information and the sensitive information into first key related information; the second device performs mutual authentication of the first device and the second device according to the first key related information and the second key related information; and the second equipment executes a preset instruction according to the authentication result. The technical scheme provided by the embodiment of the application can improve the compatibility and the safety of the terminal equipment.
Description
Technical Field
The present disclosure relates to the field of communications technologies, and in particular, to a device control method, a device, and a distributed digital key system.
Background
A Digital Key (DK) is a "virtual key" built in a terminal device such as a mobile phone, and with development of computer technology, the digital key is increasingly used in fields such as automobiles and intelligent door locks. Taking the application in the automobile field as an example, a user can conveniently control the locking, unlocking and starting of the automobile door through the digital key, and can conveniently carry out driving approval, transfer of the automobile use right and the like.
In order to Secure digital key services against malicious resolution attacks by other applications, in current digital key systems, digital keys are typically stored in respective Security Elements (SE) of terminal devices and target devices (e.g. car machines), and the security elements are typically required to reach at least the security level of the evaluation assurance level 4+ (the evaluation assurance level 4+, EAL 4+). However, at present, a few terminal devices are not configured with SE meeting the requirement, or the digital key service provider does not have permission to use the SE although the SE meeting the requirement is configured, which results in that the terminal devices cannot unlock and start the target device by using the digital key meeting the security level. In other words, current digital key systems suffer from poor security either because of SE-free storage and protection of key information or poor compatibility because of SE rights settings and access mode closure.
Disclosure of Invention
The application provides a device control method, device and distributed digital key system, which are used for improving the compatibility and safety of the digital key system to terminal devices.
In order to achieve the above purpose, the present application adopts the following technical scheme:
In a first aspect, an embodiment of the present application provides a device control method, which is applied to a first device and a second device, where desensitization information in first key related information is stored in the first device; sensitive information in the first key related information and the second key related information are stored in a secure element of the second device. The method comprises the following steps: the first device sends the desensitization information to the second device; the second device combines the desensitization information and the sensitive information into first key related information; the second device performs mutual authentication of the first device and the second device according to the first key related information and the second key related information; and the second equipment executes a preset instruction according to the authentication result.
The first device may be a terminal device (e.g., a mobile phone, a smart watch, etc.), and the second device may be a target device controlled by the terminal device (e.g., a car machine, a smart door lock, etc.).
In the method provided in this embodiment, the first key related information of the terminal device is divided into two parts, namely, desensitization information and sensitive information, and the desensitization information is stored in the terminal device, and the sensitive information is stored in the secure element of the target device. Since the method does not require the use of a secure element of the terminal device, it is possible to be compatible with a terminal device that does not have a secure element or that does not have access to a secure element when controlling the target device, i.e. to have a better compatibility with the terminal device. In addition, since the sensitive information of the first key related information is stored in the secure element of the target device, the method can also ensure the security of the information.
In some embodiments, a second digital key application and a server application are disposed within the secure element of the second device, the server application having the sensitive information stored therein, the second digital key application having second key-related information stored therein; the second device performs mutual authentication of the first device and the second device according to the first key related information and the second key related information, and the second device executes a preset instruction according to an authentication result, including:
the server application sends card authentication information in the first key related information to the second digital key application, wherein the card authentication information is all or part of the first key related information.
The second digital key application generates a verification request ciphertext according to the card authentication information and the second key related information, and sends the verification request ciphertext to the server application.
The server application authenticates the second device according to the authentication request ciphertext; and after passing the authentication of the second device, sending a response ciphertext to the second digital key application.
The second digital key application authenticates the first device based on the reply ciphertext; and after passing the authentication of the first device, controlling the second device to execute the preset instruction.
In this embodiment, the server application of the second device takes the role of the terminal device, the second digital key application takes the role of the target device, and the mutual authentication of the terminal device and the target device is performed by using the first key related information and the second key related information, so that the transmission of sensitive information between the terminal device and the target device is avoided in the authentication process, and the security of the authentication process can be ensured.
In some embodiments, the method further comprises: the second device updates the first key related information and transmits desensitization information in the updated first key related information to the first device.
In some embodiments, before the first device transmits the desensitization information to the second device, the method further comprises: the first equipment sends first identity verification information of the first equipment to the second equipment; the second device verifies whether the identity of the first device is legal or not according to the first identity verification information; if the identity of the first device is legal, the second device sends second identity verification information of the second device to the first device; and the first equipment verifies whether the identity of the second equipment is legal or not according to the second identity verification information.
In some embodiments, before the first device transmits the desensitization information to the second device, the method further comprises: the first equipment sends registration information to a second server through a first server; the second server generates first key related information according to the registration information, sends the desensitization information in the first key related information to the first device, and sends the sensitive information in the first key related information to the second device.
In some embodiments, the first device transmitting the desensitization information to the second device comprises: the first device transmits the desensitization information to the second device after detecting the first preset condition. The first preset condition is that the distance between the first equipment and the second equipment is within a preset range; or the first device acquires a second user operation, and the second user operation is used for controlling the second device to execute the preset instruction.
In some embodiments, where the first device and the second device communicate using bluetooth low energy BLE technology, the first device and the second device interact with information based on the hypertext transfer security protocol HTTPS.
In some embodiments, the first key related information is stored within the first digital key application; the first digital key application is an application program carried in a software installation package, or a nested applet of an application platform, or a web page application program. This convenient user option benefits from the fact that the first digital key application is no longer dependent on the secure element enclosed by the first device.
In some embodiments, the sensitive information and the second key related information are located within a secure element of the second device and on both sides of a firewall within the secure element.
In a second aspect, an embodiment of the present application provides a device control method, which is applied to a first device, where desensitization information in first key related information is stored in the first device; the sensitive information in the first key related information and the second key related information are stored in a secure element of the second device. The method comprises the following steps: the desensitization information is sent to the second device. The desensitization information is used for combining with sensitive information in the second equipment to obtain first key related information; the first key related information and the second key related information are used for mutual authentication of the first device and the second device by the second device, and the second device is controlled to execute a preset instruction according to an authentication result.
In some embodiments, transmitting the desensitization information to the second device includes: mutually checking whether the identity of the opposite party is legal or not with the second equipment; and if the identities of the first equipment and the second equipment are legal, transmitting the desensitization information to the second equipment.
In some embodiments, transmitting the desensitization information to the second device includes: after detecting the first preset condition, desensitization information is sent to the second device. The first preset condition is that the distance between the first equipment and the second equipment is within a preset range; or the first device acquires a second user operation, and the second user operation is used for controlling the second device to execute the preset instruction.
In some embodiments, before sending the desensitization information to the second device, the method further comprises: transmitting registration information to a second server through a first server; receiving, by the first server, the desensitization information sent by the second server, where first key related information corresponding to the desensitization information is generated by the second server according to registration information; desensitization information is stored.
In some embodiments, where the first device and the second device communicate using bluetooth low energy BLE technology, the first device and the second device interact with information based on the hypertext transfer security protocol HTTPS.
In some embodiments, the first key related information is stored within the first digital key application; the first digital key application is an application program carried in a software installation package, or a nested applet of an application platform, or a web page application program.
In a third aspect, an embodiment of the present application provides a device control method, applied to a second device, where a security element of the second device stores sensitive information in first key related information and second key related information; desensitization information in the first key related information is stored in the first device.
The method comprises the following steps: receiving the desensitization information sent by the first equipment; combining the desensitization information and the sensitive information into first key related information; performing mutual authentication of the first device and the second device according to the first key related information and the second key related information; and controlling the second equipment to execute a preset instruction according to the authentication result.
In some embodiments, a second digital key application and a server application are disposed within the secure element of the second device, the server application having the sensitive information stored therein, the second digital key application having second key-related information stored therein; performing mutual authentication of the first device and the second device according to the first key related information and the second key related information, and controlling the second device to execute a preset instruction according to an authentication result, including:
the server application sends card authentication information in the first key related information to the second digital key application, wherein the card authentication information is all or part of the first key related information.
The second digital key application generates a verification request ciphertext according to the card authentication information and the second key related information, and sends the verification request ciphertext to the server application.
The server application authenticates the second device according to the authentication request ciphertext; and after passing the authentication of the second device, sending a response ciphertext to the second DK application.
The second digital key application authenticates the first device based on the reply ciphertext; and after passing the authentication of the first device, controlling the second device to execute the preset instruction.
In some embodiments, the method further comprises: updating the first key related information and transmitting desensitization information in the updated first key related information to the first device.
In some embodiments, prior to receiving the desensitization information sent by the first device, the method further comprises: mutually checking whether the identity of the opposite party is legal or not with the first equipment; after determining that the identities of the first device and the second device are both legal, the desensitization information sent by the first device is received.
In some embodiments, the sensitive information and the second key related information are located within a secure element of the second device and on both sides of a firewall within the secure element.
In a fourth aspect, an embodiment of the present application provides a distributed digital key system, including a first device and a second device, where desensitization information in first key related information is stored in the first device; the security element of the second device stores sensitive information and second key related information in the first key related information; the first device and the second device cooperate with each other to implement the device control method shown in the first aspect.
In a fifth aspect, embodiments of the present application provide a first device, where desensitization information in first key related information is stored in the first device; the sensitive information in the first key related information is stored in a secure element of the second device, the first device being configured to perform the device control method as shown in the second aspect described above.
In a sixth aspect, embodiments of the present application provide a second device, where the second device has sensitive information and second key related information in the first key related information stored in a secure element of the second device, and the second device is configured to perform the device control method as shown in the third aspect.
In a seventh aspect, embodiments of the present application provide a computer-readable storage medium storing a computer program that, when executed by a processor, implements the apparatus control method as shown in the second aspect described above.
In an eighth aspect, embodiments of the present application provide a computer-readable storage medium storing a computer program which, when executed by a processor, implements the apparatus control method as shown in the above third aspect.
In a ninth aspect, embodiments of the present application provide a computer program product which, when run on a first device, causes the first device to implement a method as shown in the second aspect.
In a tenth aspect, embodiments of the present application provide a computer program product which, when run on a second device, causes the second device to implement the method as shown in the third aspect.
It will be appreciated that the advantages of the second to tenth aspects may be found in the relevant description of the first aspect and are not described here again.
Drawings
FIG. 1 is a schematic architecture diagram of a digital key system provided in one embodiment of the present application;
FIG. 2 is a schematic architectural diagram of a digital key system provided in accordance with another embodiment of the present application;
FIG. 3 is a schematic flow chart of a digital key service registration and provisioning process provided by an embodiment of the present application;
fig. 4 is a schematic diagram of an opening interface of a digital key service at a terminal device side according to an embodiment of the present application;
fig. 5 is a schematic diagram of an opening interface of a digital key service at a target device side according to an embodiment of the present application;
FIG. 6 is a schematic flow chart diagram of target device unlocking provided by one embodiment of the present application;
fig. 7 is a schematic flow chart of unlocking a target device according to another embodiment of the present application.
Detailed Description
The following describes the technical scheme provided by the embodiment of the application with reference to the accompanying drawings.
It should be understood that in the description of the embodiments of the present application, unless otherwise indicated, "/" means or, for example, a/B may represent a or B; "and/or" herein is merely an association relationship describing an association object, and means that three relationships may exist, for example, a and/or B may mean: a exists alone, A and B exist together, and B exists alone.
In this embodiment, the terms "first", "second" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defining "a first" or "a second" may explicitly or implicitly include one or more such feature. In the description of the present embodiment, unless otherwise specified, the meaning of "plurality" is two or more.
A Digital Key (DK) is a "virtual key" built in a terminal device such as a mobile phone, and with development of computer technology, the digital key is increasingly used in fields such as automobiles and intelligent door locks. By taking the application in the automobile field as an example, a user can intelligently unlock the lock, remotely start the automobile, remotely switch the air conditioner of the automobile, can conveniently drive and approve the automobile, and can transfer the automobile right of use by sharing the digital key, and the like, so that better automobile control experience is brought to the user.
FIG. 1 is a schematic architecture diagram of a digital key system provided in one embodiment of the present application. Referring to fig. 1, the digital key system includes a terminal device (may also be referred to as a first device), a terminal device server (may also be referred to as a first server), a target device server (may also be referred to as a second server), and a target device (may also be referred to as a second device). This will be described below.
(1) Terminal equipment
In various embodiments of the present application, the terminal device may be a mobile phone (mobile phone), a tablet (Pad), a wearable device (e.g., a smart watch), a computer with wireless transceiver function, an augmented reality (augmented reality, AR)/Virtual Reality (VR) device, an ultra-mobile personal computer (UMPC), a netbook, a personal digital assistant (personal digital assistant, PDA), etc. The type of the terminal device is not particularly limited in the embodiment of the present application.
In this embodiment, the terminal device is provided with a first DK application, a first SE, and a first communication unit.
In the system shown in fig. 1, the first DK application is typically an application program carried in an Android Package (APK). After receiving the digital key service enabling instruction of the user, the first DK application may interact with the terminal device server to obtain key related information (referred to as first key related information in this embodiment) of the terminal device side for controlling the target device (for example, unlocking the target device). In this embodiment, the first DK application includes a first part and a second part that cooperate with each other, where the first part is deployed in a memory of a terminal device and is mainly used for configuring and maintaining the first DK application. The second part is deployed in the first SE and is used for storing the first key related information and authenticating with target equipment (such as a vehicle machine).
The first SE is used for storing key data in the terminal equipment, and the first SE usually exists in the terminal equipment in a chip form, and prevents malicious analysis attacks of other applications on the data in the SE through an encryption/decryption logic circuit, so that the data security is protected. It should be noted that, only an application program having a use right can store the key data in the first SE. Taking the first DK application as an example, if the first DK application has the authority to use the first SE, the first DK application may store the first key related information in the first SE.
The first communication unit may provide the wireless communication solution on the terminal device to an application (e.g., a first DK application). The first communication unit may be a Radio Frequency (RF) unit or other wireless communication units. The terminal device can communicate with the terminal device server and the target device via the first communication unit.
(2) Terminal equipment server
The terminal equipment server can provide digital key service registration and opening service for the terminal equipment, and can perform operations such as data sharing and information interaction with the target equipment server after the trusted link is established.
Because the information related to the terminal device side (such as user account and password information, token, etc.) in the first key related information is maintained by the terminal device server, while the information related to the target device (such as card key (CardSecret), the extension field (carduthrfu) of the card for the authentication stage, etc.) is maintained by the target device server, when the terminal device interacts with the target device server, the terminal device server needs to make a transfer of the request and the response. That is, the terminal device server is a bridge for information interaction between the terminal device and the target device server. In particular, the terminal device server is responsible for digital key lifecycle (e.g., registration, provisioning, updating, deregistration, synchronization, and usage, etc.) management. Therefore, the terminal device server can synchronize the related information on the terminal device side to the target device server.
(3) Target device
The target device is provided with a second DK application, a second SE and a second communication unit.
In this embodiment, the second DK application includes a first part and a second part that cooperate with each other, where the first part is deployed in the memory of the target device and is mainly used for configuring and maintaining the second DK application. The second portion is disposed in the second SE, and is configured to store key related information of the target device (referred to as second key related information in this embodiment), perform authentication with the terminal device (such as a mobile phone), and control the target device to execute a preset instruction (for example, control the vehicle to unlock, start the engine, etc.).
The second DK application is capable of interacting with the target device server, receiving instructions, notifications, or information from the target device server, and performing the corresponding operations. For example, the target device application may obtain the second key related information according to the notification of the target device server in combination with the user operation to open the digital key service on the target device side.
The second SE is configured to store key data (e.g., second key related information) in the target device, where the key data is usually stored in a chip, and the encryption/decryption logic circuit is configured to prevent malicious parsing attacks on the data in the SE by other applications, so as to protect data security.
The second communication unit may provide the wireless communication solution on the target device to an application (e.g., a second DK application). The second communication unit may be a radio frequency unit or other wireless communication units. The target device may communicate with the target device server and the terminal device through the second communication unit.
(4) Target equipment server
The target equipment server can provide digital key service registration and opening service for the target equipment, and can perform operations such as data sharing and information interaction with the terminal equipment server after the trusted link is established.
After the terminal device and the target device both open the digital key service, if the user brings the terminal device close to the target device, or the terminal device receives the control operation of the user on the target device, the terminal device and the target device mutually check through the first key related information and the second key related information, and after the check is successful, the target device is controlled to execute a preset instruction (for example, the target device is controlled to unlock). Taking the example that the target device is a car machine, after the target device is unlocked, a user can open a car door or start a car machine engine.
In order to ensure the security of the digital key, in the digital key system provided in the embodiment, both the first SE and the second SE at least need to reach the security level of EAL 4+. However, some terminal devices (such as some low-end mobile phones, tablet computers, wearable devices and the like) are not configured with SE meeting requirements at present; in addition, some terminal devices are configured with SE meeting the requirement, but due to the authority problem, the first DK application cannot use SE of the terminal devices, which results in that the terminal devices cannot form the digital key system with the target device and the like, so that the target device cannot be unlocked or cannot be unlocked safely. That is, the current digital key system has poor compatibility with terminal devices and poor security.
Therefore, the embodiment of the application also provides a distributed digital key system which has stronger compatibility to various terminal devices and can ensure the safety of the digital key.
Fig. 2 is a schematic architecture diagram of a digital key system provided in another embodiment of the present application. Referring to fig. 2, the system includes: a terminal device (may also be referred to as a first device), a terminal device server (may also be referred to as a first server), a target device (may also be referred to as a second device), and a target device server (may also be referred to as a second server). This will be described below.
(1) Terminal equipment
In this embodiment, the terminal device is provided with a first DK application and a first communication unit.
In the system shown in fig. 2, the first DK application may be an application program carried in the APK. In particular, the first DK application may also be a program running in a web page of a uniform resource locator (Uniform Resource Locator, URL), or an Applet (Applet) nested in some application platforms (e.g. WeChat, payment device), which is a convenient user option thanks to the fact that the first DK application no longer relies on closed SE hardware, but is based on the idea of a distributed system design. The present embodiment is not limited to the specific form of the first DK application.
The first DK application typically stores application information and application state information. The application information includes, among other things, the version of the application, the issuing service, the signing certificate, the account and password involved in the registration and login phases, biometric information, etc. The application state information includes a validity period of token information, and the like. In addition, after the first DK application opens the digital key service according to the user instruction, the first DK application also stores the desensitization information in the first key related information.
In one example, the desensitization information in the first key related information includes all or part of the information shown in table 1, and may further include other related information not shown, which is not limited in this embodiment.
When the terminal device controls the target device by the digital key service, the terminal device corresponds to a Card (Card), and the target device corresponds to a Reader (Reader). Therefore, the key related information (i.e., the first key related information) on the terminal device side may also be referred to as card key related information, and the key related information (i.e., the second key related information) on the target device side may also be referred to as card reader key related information.
TABLE 1 desensitization information in first key related information
In table 1, the terminal device system includes a terminal device and a terminal device server, and the target device system includes a target device and a target device server.
The token information is generated by combining the user account number, the password and other related information according to a calculation rule such as hash (hash) or key related hash operation (hash-based message authentication code, HMAC). When the terminal equipment logs in the terminal equipment server, identity authentication can be carried out by carrying token information in the access request without carrying an account and a password, so that the account and the password are prevented from being spread in the air when logging in each time, and other programs can be prevented from being attacked maliciously. the token information includes an access token and a refresh token, and the access message generally carries the access token, but each token has an aging device (i.e. an expiration date), so after the access token is invalid, the terminal device server reports an error to the terminal device to notify that the access token is invalid, and in addition, sends the refresh token to the terminal device. Based on the method, the first DK application automatically carries the refresh token to initiate the access request to the terminal equipment server again, and the processes of acquiring the account and the password again, and transmitting the account and the password in the air are avoided while the user is kept free from feeling.
It should be understood that, for a target device, there may be a plurality of terminal devices each capable of unlocking the target device, so each terminal device corresponds to one piece of first key related information, and the first key related information is different from each other. Since the desensitization information and the sensitive information are part of the first key related information, the desensitization information of each terminal device is different, and the sensitive information of each terminal device is also different.
The first communication unit may provide the wireless communication solution on the terminal device to an application (e.g., a first DK application). The first communication unit may be a radio frequency unit or other communication units. By way of example, the wireless communication solution may include a near field wireless communication technology (near field communication, NFC), ultra Wide Band (UWB), bluetooth (BT), bluetooth low energy (bluetooth low energy, BLE), frequency modulation (frequency modulation, FM), infrared technology (IR), wireless local area network (wireless local area networks, WLAN), cellular Network (CN), etc., which the present embodiment is not limited to.
(2) Terminal equipment server
The terminal equipment server can provide digital key service registration and opening service for the terminal equipment, and can perform operations such as data sharing and information interaction with the target equipment server after the trusted link is established. With reference to the foregoing descriptions, the present embodiment is not described herein.
(3) Target device
As shown in fig. 2, the target device is provided with a second DK application, SE, and a second communication unit.
In this embodiment, the second DK application includes a first part and a second part that are mutually matched, where the first part is disposed in a memory of the target device and is mainly used for configuring and maintaining the second DK application, for example, according to a notification of a server of the target device, in combination with a user operation to open a digital key service on the side of the target device, to obtain sensitive information in the first key related information and the second key related information. The second portion is disposed in the second SE and is configured to store information related to a second key, authenticate with a terminal device (such as a mobile phone), and control the target device to execute a preset instruction (for example, controlling the vehicle to unlock, start the engine, etc.).
In some embodiments, the sensitive information in the first key related information is part or all of the information shown in table 2, and may further include other related information not shown, which is not limited in this embodiment.
TABLE 2 sensitive information in first Key related information
In this embodiment, the card issuing stage may be understood as a stage in which the terminal device opens the digital key service using the first DK application. The authentication phase may be understood as an identity authentication phase when the terminal device performs a preset operation (e.g., unlocking) at the control target device.
It should be noted that the desensitization information and the sensitive information in the first key related information may include some identical contents. For example, taking the desensitization information shown in table 1 and the sensitive information shown in table 2 as examples, the same contents included in the desensitization information and the sensitive information may be: card SE unique identification (CardSEID), card unique identification (CardID), etc.
In some embodiments, the second key related information is part or all of the information shown in table 3, and may further include other related information not shown, which is not limited in this embodiment. It should be appreciated that a target device typically has only a set of second key related information.
TABLE 3 second Key related information
After the target device side opens the digital key service, the SE of the target device includes a firewall, a second portion of a second DK application, and a server application.
Wherein the firewall in the SE is capable of physically isolating the applications, e.g., the server application and the second portion of the second DK application, located on both sides of the firewall from any access to each other's data. In this embodiment, however, the second portions of the server application and the second DK application may have specific access to each other through the firewall (e.g., access to each other during mutual authentication) based on specific protocols or specifications (e.g., specifications of a JAVA CARD-side operating system (JAVA CARD OS) or multiple operating system (MULTI OS) platform, etc.). Note that, the type of the firewall is not particularly limited in this embodiment.
The second part of the second DK application is located on one side of a firewall in the SE and is used as a card Reader (Reader) to actively initiate a command or a request to the first DK application of the terminal device, and the second part of the second DK application stores second key related information. The server application is located on the other side of the firewall within the SE, and the server application includes a Web server application and a DK server application. The DK server application stores sensitive information in the first key related information. The Web server application is a public infrastructure in the SE, and in this embodiment, the Web server application may be used as a server to answer a request from the first DK application, actively push related status information, and assume a risk control task whether the first DK application accesses reasonably and legally. In some embodiments, the Web server application may employ a universal hypertext transfer security protocol (hyper text transfer protocol secure, HTTPS) for certificate mutual authentication, or the like.
In this embodiment, the SE usually exists in the form of a chip, which can prevent malicious parsing attacks on SE data by other applications through an encryption/decryption logic circuit, so as to protect data security. In one example, the SE may be an embedded secure element (embedded secure element, eSE), which is fixed on the motherboard of the terminal device and cannot be removed from the motherboard, and is therefore also referred to as an embedded SE. In this embodiment, the SE is connected to an NFC unit, BLE, or other element, and it uses the NFC unit or BLE, or other element, as a gateway to the outside of the target device.
The second communication unit may provide the wireless communication solution on the target device to an application (e.g., a second DK application, a Web server application, a DK server application, etc.). The target device may communicate with the target device server and the terminal device through the second communication unit. The second communication unit may be a radio frequency unit or other wireless communication units. Illustratively, the wireless communication solution may include NFC, UWB, BT, BLE, FM, IR, WLAN, CN, etc.
After the terminal device and the target device both open the digital key service, if the user brings the terminal device close to the target device, or after the terminal device receives the control operation of the user on the target device, the terminal device can send the desensitization information in the first key related information to the server application of the target device through the wireless short-distance communication technologies such as NFC, BLE and the like, or the long-distance communication technologies such as WLAN, CN and the like. The terminal device sends the desensitization information in the first key related information to a server application of the target device. The server application combines the desensitized information with locally stored sensitive information to form first key related information. Then, the server application replaces the first DK application to function as a Card (Card), and the second part of the second DK application functions as a Reader (Reader), mutually authenticating by the first key-related information and the second key-related information. And if the authentication is successful, the second part of the second DK application controls the target equipment to execute the preset instruction. Taking the example that the target device is a vehicle machine, after the terminal device and the vehicle machine are successfully authenticated, the second part of the second DK application may control the vehicle machine to unlock. After the vehicle is unlocked, the user may open the door or start the vehicle engine.
In summary, in the digital key system provided in the embodiment of the present application, the first key related information is divided into two parts, namely, desensitization information and sensitive information, where the desensitization information is stored in the first DK application of the terminal device, and the sensitive information is stored in the server application of the target device. Since the digital key system does not need to use the SE of the terminal device when providing the digital key server, the digital key system can be compatible with the terminal device without SE or without the right of the first DK application to use the SE, i.e. has better compatibility with the terminal device. In addition, since the sensitive information of the first key related information is stored in the SE of the target device, the system can also ensure the security of the digital key system.
The registration and activation process of the terminal device side and the target device side digital key service will be exemplarily described based on the digital key system shown in fig. 2.
Fig. 3 is a schematic flowchart of a digital key service registration and activation procedure provided in an embodiment of the present application. Referring to fig. 3, the flow includes the following steps S301 to S316.
S301, the terminal equipment receives a first user operation.
When the terminal device opens and registers the digital key service, it first needs to download and install the APK of the first DK application or call the applet or the web page program of the first DK application. And then, the terminal equipment logs in a first DK application and acquires a first user operation, wherein the first user operation is used for indicating the terminal equipment to open the digital key service.
Taking a digital key of a terminal device car opener as an example, after the first DK application is successfully logged in, a digital key opening interface can be displayed according to a user instruction, and the interface comprises a first control for controlling opening of a digital key service. Taking the digital key activation interface shown in fig. 4 as an example, the first control is a "create digital key" control. After detecting the operation of the first control by the user, the terminal equipment considers that the first user operation is received.
S302, after receiving the first user operation, the terminal equipment sends a digital key opening request to a terminal equipment server.
After receiving the first user operation, the terminal device needs to execute the following operations (1) - (3) through the first DK application, and the embodiment does not limit the sequence of executing (1) and (2).
(1) The first DK application obtains user basic information and target device basic information. Taking a digital key of a car opener as an example, the basic information of a user comprises a car owner name, a car owner certificate number (such as an identity card number), a telephone number, a mailbox and the like, and the basic information of target equipment comprises a car machine model, a car machine identification two-dimensional code, a car machine identification code (vehicle identification number, VIN) and the like. The user basic information and the target device basic information may be input by the user on the terminal device during the process of opening the digital key service, or may be obtained by the terminal device from the target device server through the terminal device server, which is not specifically limited in this embodiment.
(2) The first DK application generates the following: a card service public-private key pair A1 (short for public-private key pair A1), a card self-signed service certificate A1 (short for service certificate A1), a card identity public-private key pair B1 (short for public-private key pair B1) and a card self-signed identity certificate B1 (short for identity certificate B1).
The card service public and private key pair A1 is used for encrypting/decrypting service related data by the terminal equipment or the terminal equipment server.
The card self-signing service certificate A1 is used for verifying the validity of the certificate and recovering the public key of the card service.
The card identity public-private key pair B1 is used for encrypting/decrypting the data related to the identity by the terminal equipment or the terminal equipment server.
The card self-signed identity certificate B1 is used for verifying the identity of the terminal equipment and recovering the card identity public key.
Alternatively, on the terminal device side, the generation and storage of public-private key pairs and certificates may be performed in a dedicated key store, such as an android key store (android key).
(3) The first DK application sends a digital key opening request to a terminal equipment server.
Alternatively, the first DK application may send a digital key provisioning request to the terminal device server based on HTTPS. The digital key opening request carries information such as a public key in the public and private key pair A1, a public key in the public and private key pair B1, a card self-signing service certificate A1, a card self-signing identity certificate B1, user basic information, target equipment basic information and the like.
S303, the terminal equipment server sends a first response message to the terminal equipment according to the digital key opening request.
After receiving the digital key opening request, the terminal equipment server verifies the self-signed identity certificate B1 of the card carried in the prior card, and adds a verification mark in the self-signed identity certificate B1 after verification is passed, so as to generate a terminal equipment system authentication certificate B1_1 (called card identity authentication certificate B1_1 for short or authentication certificate B1_1 for short). The card identity authentication certificate B1_1 is used for indicating that the identity of the terminal equipment is authenticated by the terminal equipment server. Subsequently, the terminal device server sends a first response message to the first DK application of the terminal device, where the first response message includes the card identity authentication certificate b1_1. The first response message is used for indicating that the terminal equipment server receives and processes the digital key opening request, and the identity of the terminal equipment is authenticated by the terminal equipment server.
S304, the terminal equipment server sends registration information to the target equipment server according to the digital key opening request.
In the present embodiment, the registration information includes card identification certificate b1_1, token, user basic information, target device basic information, and the like. The authentication certificate b1_1 can be referred to for description of S303. The Token is a field which is generated by the terminal equipment server according to the information such as the account number and the password of the user and is used for subsequent authentication of reasonable and legal conversation at the time of user registration or first login stage. The user basic information and the target device basic information can be referred to the related description of S302.
S305, the target device server determines first key related information according to the registration information.
After receiving the registration information, the target device server needs to determine the first key related information according to some or all of the three pieces of information. The first part of information is information locally generated by the target equipment server, the second part of information is information received by the target equipment server from the terminal equipment server, and the third part of information is static information called by the target equipment server from a local secret key pool. This will be specifically described below.
(1) First part of information
The target device server needs to generate the first partial information locally after receiving the registration information, including but not limited to: card service public and private key pair A2 (short for public and private key pair A2), card service certificate A2 (short for service certificate A2), card reader identity public and private key pair B2 (short for public and private key pair B2), card reader identity certificate B2 (short for identity certificate B2), card identity certificate B1_2, random salt value A, random salt value B, card counter (CardATC), card transaction authentication random number (CardRnd) and the like. The embodiment does not limit the specific content of the first part of information and the sequence of generating each piece of information in the first part of information.
The public and private key pair A2 of card business is used for encrypting/decrypting data related to business by the target equipment server.
The card service certificate A2 is used for verifying the validity of the service certificate and recovering the card service public key A2.
The public and private key pair B2 of the card reader identity is used for encrypting/decrypting the data related to the identity of the target device or the target device server.
The card reader identity certificate B2 is used for verifying the identity of the target equipment and recovering the card reader identity public key.
The card identity authentication certificate b1_2 is generated by the signature after the target device server recovers the card identity public key from the card identity authentication certificate b1_1 after checking the card identity authentication certificate b1_1. It will be appreciated that the identity certificate b1_2 is obtained after the card has been double authenticated from the signed identity certificate B1 via the terminal device server and the target device server, and represents that the identity of the terminal device has been double approved by the terminal device server and the target device server.
Random salt value a and random salt value B for encrypting/decrypting desensitized data.
The card counter (card TC) is increased by N after each authentication, wherein N is more than or equal to 1 and is an integer.
Card transaction authentication random number (CardRnd) for participating in encryption/decryption in the authentication of the terminal device and the target device.
(2) Second part of information
The second part of information is information received by the target equipment server from the terminal equipment server, and comprises the following components: card identity authentication certificate B1_1, token, user basic information, target device basic information, and the like. The specific content of each information is referred to the foregoing description, and this embodiment is not repeated here.
(3) Third part of information
The third part of information is static information called by the target equipment server from the key pool according to parameters such as Token, card unique identification (card ID) and the like of the terminal equipment. It should be understood that the target device server may serve multiple target devices at the same time, and for each target device, the terminal device may have stored therein information (i.e., the third portion of information) for enabling the car key service. Therefore, the target device server needs to call the corresponding third part of information from the key pool according to parameters such as Token, card unique identification (CardID) and the like.
Illustratively, in this embodiment, the third portion of information includes at least one of:
card SE unique identification (CardSEID) for uniquely identifying the SE of the terminal device.
Card unique identification (CardID) for uniquely identifying the terminal device.
The card is used in the extension field (carduthrfu) of the authentication phase, including some additional authentication information, such as the phone number, the location of the residence, etc.
A card key (CardSecret) for encryption/decryption in the authentication process.
Optionally, card private information (card private Info) may include some user related information.
The target device service generates first key related information according to part or all of the first part information, the second part information and the third part information. For example, the first key related information may be part or all of the combined information shown in table 1 and table 2, and may further include other related information not shown, which is not limited in this embodiment.
And S306, the target equipment server sends the desensitization information in the first key related information to the terminal equipment server.
In one example, the desensitization information in the first key related information may be part or all of the information shown in table 3, and may further include other related information not shown, which is not limited in this embodiment. The target device server needs to encrypt the desensitization information when transmitting the desensitization information to the terminal device server.
When the target device server sends the desensitization information to the terminal device server by encryption, in one example, the target device server may sequentially encrypt the desensitization information a first time and a second time. In the first encryption process, the target device server encrypts the desensitized data with the public key in A2 using the card service public-private key. In the second encryption process, the target equipment server firstly searches a master personalized protection key mkey from a key pool according to preset searching version, batch and index information; subsequently, using Token as a dispersion factor, dispersing a dispersion personalized protection key skey from the master personalized protection key mkey; finally, the desensitization information is encrypted using skey.
It should be noted that, the master personalization protection key mkey and the decentralized personalization protection key skey are both used to encrypt/decrypt the first key related information, where mkey is a root key and skey is a subkey.
S307, the terminal equipment server encrypts the desensitization data in the first key related information and then sends the desensitization data to the terminal equipment.
When the terminal equipment server transmits the desensitization information to the terminal equipment, the desensitization information needs to be encrypted. Illustratively, on the basis that the desensitization information has been encrypted twice (see, for details, the description related to S306), the terminal device server may encrypt the desensitization information a third time using the card self-signed service certificate A1, and transmit the desensitized data encrypted three times to the terminal device.
S308, the terminal device stores desensitization information in the first key related information.
In some embodiments, the terminal device may store the desensitization information in the first key related information in a lightweight database (SQlite) of the first DK application, which may have a storage path of "/data/data/< package name >/database/. Db").
Since one terminal device can turn on the digital key service for a plurality of target devices, one terminal device may correspond to a plurality of first key related information. It will be appreciated that one terminal device may correspond to desensitization information among a plurality of first key related information. Therefore, when the terminal stores the desensitization information in the first key related information, a mapping relation between the desensitization information and the unique identification (Reader ID) of the Reader and the Type (Reader Type) of the Reader needs to be established so as to be called when the target device is controlled later.
S309, the terminal equipment sends a first opening success notification to the target equipment server through the terminal equipment server.
The first opening success notification is used for indicating that the digital key service of the terminal equipment side is successfully opened.
Through the above steps S301 to S309, after the terminal device acquires and stores the desensitization data from the target device server, the digital key service on the terminal device side is successfully opened.
The following describes in detail a procedure for opening a digital key service to a target device. In some embodiments, the target device server instructs the vehicle to turn on the digital key service after receiving the first turn-on success notification sent by the terminal device (i.e., after S309). In other embodiments, the target device server, after obtaining the first key-related information (i.e., after S305), instructs the vehicle to turn on the digital key service. The process specifically includes the following steps S310 to S316.
And S310, the target device installs a second part of a second DK application on one side of the firewall in the SE according to the user instruction.
In this embodiment, the target device and the terminal device need to log in the same account (for example, the account, the mobile phone number, the mailbox address, etc.) to share the data. Since the first key related information has been generated in the target device server (see S305), after the target device logs in the account same as the terminal device, the target device may obtain the first key related information shown in the foregoing from the target device server, and instruct the first part preset in the second DK application to prompt and guide the user to open the digital key service on the target device side (see fig. 5).
After receiving the digital key on command input by the user, the target device opens a secure channel for transmitting data with the target device server, installs an auxiliary security domain (supplementary security domain, SSD) through the secure channel, and downloads and installs a second portion of the second DK application in the SSD through the secure channel. The target device sends a second response message to the target device server after the second portion of the second DK application is installed successfully to notify the target device server that the second portion of the second DK application has been installed successfully.
S311, the target device server sends the main digital key and the second key related information to the target device.
In this embodiment, the target device server presets corresponding second key related information in the key pool for each target device. Based on this, the target device server, after detecting that the second portion of the second DK application is installed successfully, first, the target device server obtains the second key related information from the key pool according to the reader identification (ReaderID). And then, the target equipment server searches the master digital keys mkey 1-mkey 3 from the key pool according to the preset searching version, batch and index information. And finally, the target equipment server encrypts the related information of the main digital keys mkey 1-mkey 3 and the second key and sends the encrypted related information to the target equipment through a secure channel.
In an example, the second key related information may be part or all of the information shown in table 2, and may further include other related information not shown, which is not limited in this embodiment.
In addition, in mkey 1-mkey 3, mkey1 is an authentication key used when the target device authenticates the terminal device, mkey2 is an encryption key used when the target device locally updates data, and mkey3 is an authentication key used when the target device locally updates data.
S312, the target device stores the primary digital key and the second key related information in the second DK application.
Specifically, after receiving and decrypting the second key related information and the master digital keys mkey 1-mkey 3, the target device stores the second key related information and the master digital keys mkey 1-mkey 3 in the second portion of the second DK application.
S313, the target device installs the server application on the other side of the firewall within the SE.
Server applications include DK server applications and Web server applications. In this embodiment, the target device may download and install the DK server application through a secure channel. In addition, the Web server application is a public base device in the SE, which may be preloaded by the target device when leaving the factory, or may be installed and updated according to a user instruction after leaving the factory.
S314, the target device server sends the sensitive information and the first information in the first key related information to the target device.
In this embodiment, the sensitive information in the first key related information may be part or all of the information shown in table 2, and may further include other related information not shown, which is not limited in this embodiment.
In this embodiment, the first information includes information such as a card service public and private key pair A2, a card service certificate A2, a card reader identity public and private key pair B2, a card reader identity certificate B2, a card counter (cardtc), a card transaction authentication random number (CardRnd), a random salt value a, a random salt value B, token, a distributed personalized protection key skey, and distributed digital keys skey1 to skey3. Based on the foregoing description, the card service public and private key pair A2, the card service certificate A2, the card reader identity public and private key pair B2, the card reader identity certificate B2, the encryption factor a and the transaction factor B are information existing in the target device server. And the information of the scattered personalized protection keys skey, the scattered digital keys skey1 to skey3 and the like needs to be determined by the target device server.
The target device server may determine the master personalized protection key mkey and the master digital keys mkey1 to mkey3 from the key pool according to the preset search version, batch and index information, and may use the Token as a dispersion factor to disperse the dispersed personalized protection keys skey from the master personalized protection key mkey, and use the Token as a dispersion factor to disperse the dispersed digital keys skey1 to skey3 from the master digital keys mkey1 to mkey 3.
When the target device server sends the sensitive information in the first key related information to the target device, the sensitive information needs to be encrypted and sent through a secure channel.
Finally, the target device server transmits the desensitization information and the first information in the first key related information to the target device.
S315, the target device stores the sensitive information in the first key related information and the first information in the server application.
Specifically, the target device may store the sensitive information in the first key related information and the first information in the DK server application and or the Web server application.
S316, the target device sends a second opening success notification to the target device server.
The second successful opening notification is used for indicating that the digital key service of the target equipment side is successfully opened.
In summary, through the steps S310 to S316, the target device downloads and installs the second portion of the second DK application from the target device server, writes the second key related information in the second portion of the second DK application, downloads and installs the DK server application from the target device server, writes the sensitive information and the first information in the first key related information in the DK server application, and then the digital key service on the target device side is successfully opened.
After the terminal device and the target device both turn on the digital key service, the terminal device may communicate with the target device through a communication technology such as NFC, BLE, UWB, WLAN or NC, so as to control the target device to execute a preset instruction, for example, to control the vehicle to unlock. This is illustrated below in connection with NFC, BLE.
Unlocking a target device based on NFC communication technology
Fig. 6 is a schematic flow chart of target device unlocking provided in an embodiment of the present application, involving a process of communicating between a terminal device and a target device through NFC technology to control the target device. The process specifically includes the following steps S600 to S618.
S600, establishing an underlying wireless connection between the first communication unit of the terminal device and the second communication unit of the target device.
In some embodiments, the first communication unit of the terminal device and the second communication unit of the target device may establish an underlying wireless connection through an ISO14443 protocol customized by the international organization for standardization (international organization for standardization, ISO), i.e., a contactless IC card standard (Contactless card standards) protocol. The specific process of this embodiment will not be described in detail.
S601, after the first preset condition is met, the second communication unit sends an information acquisition command to the second DK application, wherein the information acquisition command is used for acquiring second identity verification information of the target device.
In some embodiments, the second communication unit sends an information acquisition command to the second DK application after detecting that the first preset condition is met (e.g., detecting that the distance between the terminal device and the target device is within a preset range), so as to notify the second DK application to send the second identity verification information to the second communication unit.
In this embodiment, the first preset condition is that the distance between the terminal device and the target device is within a preset range. Or the terminal device acquires a second user operation, wherein the second user operation is used for controlling the target device to execute a preset instruction, such as unlocking, turning on an air conditioner of the vehicle, and the like.
In some embodiments, the information retrieval command may also be referred to as a Get Process Data (GPD) command, or a GPD assembly command. The information obtaining command is used for obtaining second identity verification information of the target device, where the second identity verification information of the target device may be part of the second key related information, and may be, for example, a card reader type (ReaderType), a target device identifier (ReaderID), a card reader identity certificate (ReaderCertificate), and so on.
S602, the second DK application sends the second identity verification information of the target device to the second communication unit.
The second identity verification information is a parameter preset in the second DK application, and after the second DK application receives the information acquisition command, the second identity verification information is sent to the second communication unit.
S603, the second communication unit sends second identity verification information of the target device to the first DK application.
Specifically, the second communication unit may send the second identity verification information of the target device to the first DK application through the first communication unit.
S604, the first DK application verifies whether the identity of the target device is legal or not according to the second identity verification information of the target device.
In some embodiments, since the terminal device may have opened a plurality of digital key services, the terminal device needs to retrieve, from the terminal device, a key for invoking certificate identity verification and subsequently transmitted desensitization information according to information such as a card reader type (ReaderType), a card reader identification (ReaderID), and the like. The first DK application may use the key to verify whether the card reader identity certificate (reader certificate) is legitimate. If the card reader identity certificate (reader certificate) is illegal, the unlocking of the target equipment fails. If the card reader identity certificate (reader certificate) is legal, the identity of the target device is considered legal, and the subsequent steps are continued to be executed.
S605, if the identity of the target device is legal, the first DK application sends first identity verification information of the terminal device and desensitization information in the first key related information to the second DK application.
Illustratively, the desensitization information in the first key related information may be shown in part or whole of table 1, and may further include other information as shown, which is not limited in this embodiment.
For example, the first identity verification information of the terminal device may include parameters such as card identity certificate b1_2 (Card CertificateB1 _2), token, biometric information, and card unique identification (CardID). The biometric information includes fingerprint information, face information, voiceprint information, iris information, etc. of the user.
The first DK application needs to encrypt the first identity verification information of the terminal device and the desensitization information in the first key related information when sending them to the second DK application, which is not limited in this embodiment.
When the first DK application sends the desensitization information to the terminal device in an encrypted manner, optionally, before the first DK application sends the desensitization information to the second DK application, the first DK application may negotiate a session key and encrypt the desensitization information using the session key. Illustratively, first, the first DK application negotiates a first session key based on a card self-signed identity certificate B1 (carddocument B1) using a key negotiation algorithm, the first session key being used to encrypt desensitization information stored in the first DK application. Then, since the desensitization information stored in the first DK application sequentially encrypts the public key A2, the skey and the card self-signed service certificate A1 in the A2 three times by using the public and private keys of the card service, the first DK application needs to remove the encryption key of the outermost layer of the desensitization data (i.e. remove the third encryption) first, and then encrypt the desensitization data by using the first session key. It will be appreciated that the first DK application may still have three layers of encryption keys after encrypting the desensitized information using the first session key.
Alternatively, in the present embodiment, the key negotiation algorithm may be any one of Diffie-Hellman (Diffie-Hellman) key negotiation algorithm, elliptic Curve DH (ECDH) key negotiation algorithm, temporary DH key negotiation algorithm (DH ephemeral), and temporary Elliptic Curve DH (ECDHE).
S606, the second DK application transmits the desensitization information in the first key related information and the first identity verification information of the terminal equipment to the server application through the firewall in the SE.
In some embodiments, the second DK application transmits the desensitization information in the first key related information and the first identity verification information of the terminal device to the server application through the firewall in the SE under the access rule specified by the JAVA CARD OS or the MULTI OS.
S607, the server application verifies whether the identity of the terminal equipment is legal or not according to the first identity verification information of the terminal equipment.
For example, the server application may verify, based on a card identity certificate (cardauthentication b1_2), whether the identity of the terminal device is legitimate; and/or checking whether the user is a vehicle owner according to the hash value corresponding to the biological identification information in the first identity checking information; and/or verifying whether the digital key service is expired based on time stamp information (Timestamp), access frequency, and validity/expiration of the information. If the user is not the vehicle owner, or the identity certificate of the terminal equipment fails to check, or the digital key service is out of date, the identity of the terminal equipment is considered to be illegal.
In some embodiments, if the server application receives the digital key information of the terminal device frequently, the unlocking is considered to be a risk accident, so the server application may also determine that the first identity verification information of the terminal device is illegal, and determine that the unlocking fails.
After determining that the identity of the terminal device is legal, the server application may send a third response message to the first DK application through the second DK application, where the third response message is used to notify the first DK application that the identity verification of the terminal device has passed. Illustratively, the third response message may be an application protocol data unit (application protocol Data Unit, APDU) grant message, abbreviated authapdu.
In the SE of the target device, since a firewall is provided between the second portion of the second DK application and the server application, the server application needs to pass through the firewall under the condition that the access rule specified by JAVA CARD OS or multiple is satisfied, and send the third response message to the first DK application through the second DK application.
In addition, after receiving the third response information, the first DK application of the terminal device needs to send the second information to the server application sequentially through the first communication unit, the second communication unit, and the second DK application. Illustratively, the second information includes: the first DK application receives the timestamp of the third response message, generates a card service random number (cardonce), locally takes a prestored Token and a card unique identifier (CardID), etc.
In this embodiment, after sending the third response message to the first DK application, the server application may obtain a card service random number (cardonce) from the first DK application through the second information. In the subsequent process (see S609), the server application uses the locally generated card transaction authentication random number (CardRnd) and the random number (cardonce) obtained from the first DK application, and the newly generated random number is used for mutual authentication of the terminal device and the device according to the exclusive-or operation or other algorithm rules, so that the reliability of authentication can be ensured.
The first DK application may or may not encrypt the second information when sending the second information to the server application, which is not limited in this embodiment.
And S608, if the identity of the terminal equipment is legal, the server application combines the locally stored sensitive information and the received desensitization information into first key related information.
Because the target device has already stored the sensitive information locally during the process of opening the digital key service (see S315), the server application may combine the desensitized information with the sensitive information stored this time after decrypting the desensitized information to obtain the first key related information.
In some embodiments, if the identity of the terminal device is legal, the server application may, after sending the third response information to the terminal device and receiving the second information returned by the first DK application, combine the locally stored sensitive information with the received desensitized information to obtain the first key related information.
In other embodiments, if the identity of the terminal device is legal, the server application may also combine the locally stored sensitive information with the received desensitized information to obtain the first key related information before sending the third response information to the terminal device and receiving the second information returned by the first DK application.
Since the desensitization information received by the server application is encryption information, the server application can combine the desensitization information with the sensitive information after decrypting the desensitization information to obtain the first key related information.
In one example, if the server application sequentially encrypts the public key A2, the decentralized personalized protection key skey and the first session key in A2 through the card service public and private key in sequence, respectively, the server application needs to sequentially decrypt the desensitized data by sequentially using the first session key, the decentralized personalized protection key skey and the card service public and private key in sequence.
Specifically, first, the server application negotiates a first session key using the same key negotiation algorithm as the terminal device, and decrypts the desensitized information for the first time using the first session key. Second, the server application looks up the decentralized personalized protection key skey from Token and uses skey to decrypt the desensitized information a second time. And finally, the server application searches the card service public and private key pair A2 according to the Token, and uses the card service public and private key to decrypt the desensitization information of the A2 for the third time to obtain the plaintext of the desensitization information.
It should be noted that, during the process of the target device opening the digital key application, the personalized protection key skey and the public and private key pair A2 of the card service are already stored in the server application (see S315). Therefore, in the decryption process, the server application can directly search locally according to Token.
Since a plurality of different terminal devices can all open the digital key service for the same target device, it can be understood that the target device may store sensitive information of a plurality of different corresponding terminal devices. Based on this, the server application, after decrypting the desensitized information, needs to retrieve and obtain the corresponding sensitive information from the local according to Token, and/or the unique card/reader identifier (ReaderID, readerType, cardID, cardSEID), so as to combine the desensitized information and the sensitive information to obtain the first key related information. It should be understood that the desensitization information stored in the device terminal is not unique and may correspond to a plurality of target devices; similarly, the sensitive information stored by the server application in the target device is not unique and may correspond to a plurality of terminal devices. The first key related information needs to be properly searched and paired when combined.
Based on the above S601 to S608, the application server on the target device side obtains the complete first key related information. That is, after S608, the first key related information is stored in the server application and the second key related information is stored in the second part of the second DK application on both sides of the firewall in the target device SE. Based on the above, the server application can replace the role of the terminal device, the second DK application can replace the role of the target device, and mutual authentication is performed on the terminal device and the target device through interaction between the server application and the second DK application. This will be specifically described with reference to S609 to S618.
S609, the server application sends the card authentication information in the first key related information to the second DK application.
In one example, the server application may send card authentication information to the second DK application by:
first, the server application determines card authentication information from the first key related information. In one example, the card authentication information may include all or part of the first key related information. For example, the card authentication information may include a new card transaction authentication random number (cardrnd_new), a card counter (cardtc), and the like. The new card transaction authentication random number (cardrnd_new) is a random number which is newly generated by the server application according to exclusive or operation or other algorithm rules by using the card transaction authentication random number (CardRnd) generated locally and a random number (cardonce) sent by the first DK application of the terminal equipment.
Secondly, the server application retrieves digital key keys skey1 to skey3 from the local according to Token or card Reader Type (Reader Type), and disperses skey1 to skey3 by using Token to obtain a second session key.
Finally, the server application encrypts the card authentication information using the second session key to form an encrypted field, and sends the encrypted card authentication information to the second DK application. It should be understood that the encrypted field carries card authentication information.
And S610, the second DK application generates a verification request ciphertext according to the card authentication information and the second key related information.
Because the card authentication information received by the second DK application is encrypted by the second session key in the server application, the second DK application needs to first generate the same second session key and decrypt the card authentication information using the second session key before generating the verification request ciphertext according to the card authentication information and the second key related information.
In one example, the second DK application may generate the second session key by the following operations (1) - (3).
(1) The second DK application finds corresponding second key related information according to the card SE unique identifier (CardSEID) and determines the root key (RootSecret) from the second key related information.
(2) The second DK application distributes the Card key (Card Secret) from the root key (RootSecret) based on the Card SE unique identification (CardSEID) and the like carried in the Card authentication information and the extension field (CardAuthRFU) for the authentication phase. The Card key (Card Secret) is identical to the Card key (Card Secret) in the first key-related information.
(3) The second DK application generates the second session key from the subkey Card Secret.
The second DK application decrypts the received encrypted card authentication information using the second session key after generating the second session key to obtain the plaintext card authentication information, for example, card transaction authentication random number (CardRnd), card counter (cardtc), etc.
Finally, the second DK application generates the authentication request ciphertext according to the encryption algorithm (e.g., AES128_cbc algorithm) using the second session key to encrypt the information such as the Card counter (Card ATC) and the Card random number (Card rnd). The authentication request ciphertext is used to request authentication of the terminal device.
Optionally, the server application may further add a card reader random number (ReaderRnd) to the card authentication information and send the card reader random number (ReaderRnd) to the second DK application. The second DK application decrypts the encrypted field to obtain the reader random number (ReaderRnd). If the card reader random number (ReaderRnd) carried in the first authentication information is the same as the card reader random number (ReaderRnd) stored in the second DK application, the second DK application executes the operation of generating the verification request ciphertext. If the card reader random number (ReaderRnd) carried in the first authentication information is different from the card reader random number (ReaderRnd) stored in the second DK application, the verification of the terminal equipment by the second DK application fails, the control of the target equipment by the terminal equipment also fails, and the target equipment does not execute the subsequent control flow.
S611, the second DK application sends the authentication request ciphertext to the server application through the firewall in SE.
In some embodiments, the second DK application sends the authentication request ciphertext to the DK server application through the firewall within the SE under satisfaction of the access rules specified by the JAVA CARD OS or multiple.
S612, the server application authenticates the target device according to the verification request ciphertext.
After receiving the verification request ciphertext, the server application authenticates the target device according to the verification request ciphertext.
In one example, the server application may decrypt the authentication request ciphertext using the previously determined second Session key to obtain the authentication request plaintext, where the authentication request plaintext includes information such as a Session initiation vector (Session IV), a Card counter (Card ATC), an extension field (ReaderAuthRFU) for the authentication phase, and a Card random number (Card rnd).
If the card random number (CardRnd) in the authentication request specification is the same as the card random number (CardRnd) in the server application, the server application considers that the target device authentication is passed. If the card random number (CardRnd) in the verification request text is different from the card random number (CardRnd) in the server application, the server application considers that the authentication of the target equipment fails, and the control of the terminal equipment on the target equipment is ended.
S613, if the target device passes the authentication, the server application transmits a response ciphertext to the second DK application through the firewall in the SE.
After the target device is authenticated, the server application needs to generate an encryption algorithm of the verification request ciphertext according to the second DK application, generate a response ciphertext, and add N to a card counter (cardtc). The response ciphertext is used for authenticating the terminal device by the second DK application.
In one example, the server application may encrypt the Session initiation vector (Session IV) using the second Session key according to an encryption algorithm (e.g., AES128_cbc algorithm), and encrypt information such as an extension field (carduthrfu) of a card for an authentication phase, an extension field (ReaderAuthRFU) of a card reader for an authentication phase, a card reader random number (ReaderRnd) of a card previously encrypted by an algorithm (e.g., SHA256 algorithm), and the like, to generate the response ciphertext. It will be appreciated that in one example CardAuthRFU, readerAuthRFU and ReaderRnd are encrypted twice by the SHA256 algorithm and the AES128 CBC algorithm.
S614, the second DK application authenticates the terminal device based on the reply ciphertext.
In one example, since the SHA256 algorithm is irreversible, which results in the second DK application not being able to decrypt the received response ciphertext (which may be referred to as response ciphertext 1), the second DK application, after receiving the response ciphertext, may generate a local response ciphertext (response ciphertext 2) in the same way as the server application and compare whether the response ciphertext 1 and the response ciphertext 2 are the same. If the response ciphertext 1 and the response ciphertext 2 are the same, the terminal equipment authentication is passed. If the response ciphertext 1 and the response ciphertext 2 are different, the terminal equipment authentication failure is indicated, and the terminal equipment fails to control the target equipment.
S615, if the terminal device authentication passes, the second DK application sends the desensitization information (updated desensitization information for short) in the updated first key related information to the first DK application.
After the second DK application and the server application complete mutual authentication of the terminal device and the target device through interaction, parameters such as a card transaction authentication random number (CardRnd), a card transaction authentication counter (cardtc) and the like are updated in the desensitization information of the first key related information. Thus, the second DK application needs to send updated desensitization information to the first DK application.
In one example, the second DK application, after determining the updated desensitization information, controls the server application to: firstly, the server application negotiates a third session key according to a key negotiation algorithm, and searches a scattered personalized protection key skey and a card service public and private key pair A2 according to Token. Then, the server application encrypts the updated desensitized data for the first time by using the public key in A2 and the public key of the card service, encrypts the desensitized data for the second time by using the scattered personalized protection key skey and encrypts the desensitized data for the third time by using the third session key. And finally, the server application sends the desensitized information after three times of encryption to a second DK application. The second DK application sends updated desensitization information to the DK server application through the firewall in the SE.
Alternatively, the key negotiation algorithm may be any one of DH, ECDH, DHE or ECDHE, which is not limited in this embodiment.
S616, the first DK application stores the updated desensitization information.
After decrypting the updated desensitization information, the first DK application stores the updated desensitization information.
In some embodiments, after receiving the updated desensitization information, the first DK application first negotiates a third session key according to the same key negotiation algorithm as in S614 and removes the third layer encryption key of the updated desensitization information according to the third session key. The first DK application then re-encrypts the updated desensitized information using the key of the android key layer. Finally, the first DK application stores the updated desensitization information. In some embodiments, the terminal device may store the updated desensitization information in a lightweight database (SQlite) whose storage path may be "/data/data/< package name >/database/. Db.
S617, the first DK application sends a fourth response message to the second DK application, where the fourth response message is used to indicate the updated desensitization information to store the completion.
S618, the second DK application controls the target device to execute the preset instruction.
It should be noted that, in the present embodiment, after S614, S615 to S617 may be executed first and then S618 may be executed (i.e. the desensitization information is updated first and then the target device is controlled to execute the preset instruction), or S618 may be executed first and then S615 to S617 may be executed (i.e. the target device is controlled to execute the preset instruction and then the desensitization information is updated first), which is not limited in this embodiment.
Taking the example that the target equipment is a car machine, after the target equipment is unlocked, the target equipment can open a car door or start a car machine engine according to the operation of a user.
(II) unlocking target equipment based on BLE communication technology
Fig. 7 is a schematic flow chart of unlocking a target device according to another embodiment of the present application, which relates to a process of communicating between a terminal device and the target device through BLE technology to unlock the target device. In fig. 7, the terminal device includes a first DK application and a first communication unit, the target device includes a second communication unit and a SE, and the SE includes a second DK application and a server application. The process specifically includes the following steps S700 to S716.
S700, the first communication unit and the second communication unit establish BLE connection, and establish a personal area network (personal area network, PAN) of the terminal device and the target device.
After the first communication unit and the second communication unit establish a BLE connection, an HTTPS-based PAN of the terminal device and the target device may be established via a BLE generic attribute specification (BLE generic attribute profile, BLE GATT) protocol. Based on this, the first DK application described below uses HTTPS protocol to carry the message content when sending a message to a target device. This will allow the first DK application to directly access the server application in the target device without the need for a relay of the second DK application.
And S701, after the first preset condition is met, the first DK application sends first identity verification information of the terminal equipment to the server application.
In this embodiment, the first preset condition is that the distance between the terminal device and the target device is within a preset range. Or the terminal device acquires a second user operation, wherein the second user operation is used for controlling the target device to execute a preset instruction, such as unlocking, turning on an air conditioner of the vehicle, and the like.
For example, the first identity verification information of the terminal device may include parameters such as card identity certificate b1_2 (Card CertificateB1 _2), token, biometric information, and card unique identification (CardID). The biometric information includes fingerprint information, face information, voiceprint information, iris information, etc. of the user.
S702, the server application verifies whether the identity of the terminal equipment is legal or not according to the first identity verification information. S702 can be seen in S607, and this embodiment is not described herein.
S703, if the identity of the terminal equipment is legal, the server application sends second identity verification information of the target equipment to the first DK application.
The second identity verification information may be a reader type (reader type), a reader identification (reader id), or a reader identity certificate (reader certificate), for example.
And S704, the first DK application verifies whether the identity of the target device is legal or not according to the second identity verification information of the target device.
In this embodiment, the specific content of S704 is shown in S604, and the description of this embodiment is omitted here.
Optionally, after determining that the identity of the target device is legal, the first DK application sends a verification success notification to the second DK application of the target device.
It should be noted that, in this embodiment, the order of checking the identities of the terminal device and the target device is not limited. For example, as shown in S701 to S704, the identity of the terminal device is checked first, and then the identity of the target device is checked. Or, the identity of the target device may be checked first, and then the identity of the terminal device may be checked.
It should be noted that, if the identity of the target device is checked first, after the identity of the target device passes the identity check, the terminal device may send the desensitization information in the first key related information and the identity check information of the terminal device to the target device together, so as to reduce an interaction flow between the terminal device and the target device.
Through the steps S701 to S704, the terminal device and the target device can mutually verify whether the identity of the other party is legal. If both the identities are legal, continuing to execute the subsequent steps.
S705, if the identity of the target device is legal, the first DK application sends the desensitization information in the first key related information to the server application.
In one example, if the identity of the target device is legal, after receiving the verification success notification sent by the first DK application, the second DK application sends a GPD packet to the server application, where the GPD packet carries information such as a card reader type (ReaderType), a card reader identifier (ReaderID), an extension field (ReaderSessionRFU) used by the card reader to generate a session key, and a card reader random number (ReaderRnd). The server application packs the GPD message according to the HTTPS protocol and sends the GPD message to the first DK application.
The first DK application invokes corresponding desensitization information from the first DK application according to information such as card reader type (ReaderType), card reader identification (ReaderID) and the like. In addition, the first DK application needs to use a preset key negotiation algorithm to negotiate a fourth session key according to information such as an extension field (ReaderSessionRFU) of the card reader for generating the session key, a random number (ReaderRnd) of the card reader, and so on. The preset key agreement algorithm may be either DH, ECDH, DHE or ECDHE.
Based on the foregoing description, the desensitization information is sequentially encrypted three times by the card service public key A2, the scattered personalized protection key skey and the card self-signed service certificate A1, so that the first DK application needs to use the card self-signed service certificate A1 to remove the encryption key of the outermost layer of the desensitization data by using the first session key, that is, remove the third encryption and then encrypt the desensitization data by using the fourth session key. It will be appreciated that the first DK application may still have three layers of encryption keys after encrypting the desensitized information using the fourth session key. Finally, the first DK application sends the desensitization information to the server application.
S706, the server application combines the locally stored sensitive information with the received desensitization information to obtain first key related information.
S707, the server application sends the card authentication information in the first key related information to the second DK application.
S708, the second DK application generates a verification request ciphertext from the card authentication information and the second key related information.
S709, the second DK application sends the authentication request ciphertext to the server application through the firewall in SE.
S710, the server application authenticates the target device according to the verification request ciphertext.
S711, if the target device authentication passes, the server application transmits the response ciphertext to the second DK application through the firewall in the SE.
S712, the second DK application authenticates the terminal device based on the reply ciphertext.
S713, if the terminal device authentication passes, the second DK application sends the updated desensitization information to the first DK application.
S714, the first DK application stores the updated desensitization information.
S715, the first DK application sends a fourth response message to the second DK application, where the fourth response message is used to indicate the updated desensitization information to store the completion.
S716, the second DK application controls the target device to unlock. After the target device is unlocked, the target device can open the vehicle door or start the engine of the vehicle according to the operation of the user.
In this embodiment, the specific implementation process of steps S706 to S716 is referred to the related content recorded in steps S608 to S618, and the description of this embodiment is omitted here. In addition, unlike S608 to S618, in S706 to S716, communication is performed between the terminal device and the target device by HTTPS protocol.
Based on the above description, according to the device control method provided by the embodiment of the present application, when the terminal device unlocks the target device, the terminal device sends the desensitization information in the first key related information stored in the terminal device to the target device, the target device combines the desensitization information with the local sensitive information to obtain complete first key related information, and authenticates the terminal device and the target device according to the first key related information and the second key related information, thereby controlling the target device. It follows that a digital key based on such a terminal device may still securely control the target device (e.g. unlock and start the target device) without the terminal device using SE to store and protect key information.
It should be understood that the sequence number of each step in the foregoing embodiment does not mean that the execution sequence of each process should be determined by the function and the internal logic of each process, and should not limit the implementation process of the embodiment of the present application in any way.
Based on the device control method provided in each embodiment, the embodiments of the present application further provide the following.
The embodiment of the application provides a terminal device, wherein desensitization information in first key related information is stored in the terminal device; sensitive information in the first key related information is stored in the target device, and the terminal device is configured to execute the device control method executed by the terminal device in the above embodiments.
The embodiment of the application provides a target device, in which sensitive information and second key related information in first key related information are stored, and the target device is configured to execute the device control method executed by the target device in each embodiment.
The present embodiment provides a computer-readable storage medium storing a computer program which, when executed by a processor, implements the device control method performed by the terminal device in the above embodiments.
The present embodiment provides a computer-readable storage medium storing a computer program which, when executed by a processor, implements the device control method performed by the target device in the above-described respective embodiments.
The embodiments of the present application provide a computer program product which, when run on a terminal device, causes the terminal device to implement the above-described device control method as performed by the terminal device in the respective embodiments.
Embodiments of the present application provide a computer program product which, when run on a target device, causes the target device to implement the device control method as described above as being performed by the target device in the respective embodiments.
It should be appreciated that the processors referred to in the embodiments of the present application may be central processing units (central processing unit, CPU), but may also be other general purpose processors, digital signal processors (digital signal processor, DSP), application specific integrated circuits (application specific integrated circuit, ASIC), off-the-shelf programmable gate arrays (field programmable gate array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or the like. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
It should also be understood that the memory referred to in the embodiments of the present application may be volatile memory or nonvolatile memory, or may include both volatile and nonvolatile memory. The nonvolatile memory may be a read-only memory (ROM), a Programmable ROM (PROM), an Erasable PROM (EPROM), an electrically Erasable EPROM (EEPROM), or a flash memory. The volatile memory may be random access memory (random access memory, RAM) which acts as an external cache. By way of example, and not limitation, many forms of RAM are available, such as Static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronous DRAM (SLDRAM), and direct memory bus RAM (DR RAM).
In the embodiments provided in this application, the division of each frame or module is merely a logic function division, and there may be another division manner when actually implemented, for example, multiple frames or modules may be combined or may be integrated into another system, or some features may be omitted or not performed.
In addition, each functional module in each embodiment of the present application may be integrated into one processing module, or each module may exist alone physically, or two or more modules may be integrated into one module. The integrated modules may be implemented in hardware or in software functional modules.
It will be clear to those skilled in the art that, for convenience and brevity of description, specific working procedures of the above-described systems, apparatuses and units may refer to corresponding procedures in the foregoing method embodiments, and are not repeated herein.
Reference in the specification to "one embodiment" or "some embodiments" or the like means that a particular feature, structure, or characteristic described in connection with the embodiment is included in one or more embodiments of the application. Thus, appearances of the phrases "in one embodiment," "in some embodiments," "in other embodiments," and the like in the specification are not necessarily all referring to the same embodiment, but mean "one or more but not all embodiments" unless expressly specified otherwise. The terms "comprising," "including," "having," and variations thereof mean "including but not limited to," unless expressly specified otherwise.
The above embodiments are only for illustrating the technical solution of the present application, and are not limiting; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present application, and are intended to be included in the scope of the present application.
Claims (24)
1. A device control method, characterized in that it is applied to a first device and a second device, where the first device stores desensitization information in first key related information; sensitive information and second key related information in the first key related information are stored in a secure element of the second device; the method comprises the following steps:
the first device sends the desensitization information to the second device;
the second device combines the desensitization information and the sensitive information into the first key related information;
the second device performs mutual authentication of the first device and the second device according to the first key related information and the second key related information;
And the second equipment executes a preset instruction according to the authentication result.
2. The method of claim 1, wherein a second digital key application and a server application are disposed within the secure element of the second device, the server application having the sensitive information stored therein, the second digital key application having the second key-related information stored therein; the second device performs mutual authentication of the first device and the second device according to the first key related information and the second key related information, and the second device executes a preset instruction according to an authentication result, including:
the server application sends card authentication information in the first key related information to the second digital key application, wherein the card authentication information is all or part of the first key related information;
the second digital key application generates a verification request ciphertext according to the card authentication information and the second key related information, and sends the verification request ciphertext to the server application;
the server application authenticates the second device according to the authentication request ciphertext; and after passing the authentication of the second device, sending a response ciphertext to the second digital key application;
The second digital key application authenticates the first device according to the response ciphertext; and after passing the authentication of the first device, controlling the second device to execute the preset instruction.
3. The method according to claim 1 or 2, characterized in that the method further comprises:
the second device updates the first key related information and sends desensitization information in the updated first key related information to the first device.
4. A method according to any one of claims 1 to 3, wherein before the first device transmits the desensitisation information to the second device, the method further comprises:
the first device sends first identity verification information of the first device to the second device;
the second device verifies whether the identity of the first device is legal or not according to the first identity verification information; if the identity of the first device is legal, second identity verification information of the second device is sent to the first device;
and the first equipment verifies whether the identity of the second equipment is legal or not according to the second identity verification information.
5. The method of any of claims 1-4, wherein prior to the first device sending the desensitization information to the second device, the method further comprises:
The first equipment sends registration information to a second server through a first server;
the second server generates the first key related information according to the registration information, and sends the desensitization information in the first key related information to the first device through the first server, and sends the sensitive information in the first key related information to the second device.
6. The method of any of claims 1-5, wherein the first device transmitting the desensitization information to the second device comprises:
the first device sends the desensitization information to the second device after detecting a first preset condition;
wherein the first preset condition is that,
the distance between the first equipment and the second equipment is within a preset range; or,
the first device obtains a second user operation, and the second user operation is used for controlling the second device to execute the preset instruction.
7. The method according to any of claims 1-6, wherein the first device and the second device interact information based on hypertext transfer security protocol HTTPS, in case of communication between the first device and the second device using bluetooth BLE low energy technology.
8. The method of any one of claims 1-7, wherein the first key related information is stored within a first digital key application; the first digital key application is an application program carried in a software installation package, or a nested applet of an application platform, or a web page application program.
9. The method of any of claims 1-8, wherein the sensitive information and the second key related information are located within a secure element of the second device and on both sides of a firewall within the secure element.
10. The device control method is applied to first devices, and is characterized in that desensitization information in first key related information is stored in the first devices; the sensitive information and the second key related information in the first key related information are stored in a secure element of the second device, the method comprising:
transmitting the desensitization information to the second device;
the desensitization information is used for being combined with the sensitive information in the second equipment to obtain the first key related information; the first key related information and the second key related information are used for mutual authentication of the first device and the second device by the second device, and a preset instruction is executed according to an authentication result.
11. The method of claim 10, wherein transmitting the desensitization information to the second device comprises:
mutually checking whether the identity of the opposite party is legal or not with the second equipment;
and if the identities of the first equipment and the second equipment are legal, transmitting the desensitization information to the second equipment.
12. The method according to claim 10 or 11, wherein said transmitting said desensitization information to said second device comprises:
after a first preset condition is detected, the desensitization information is sent to the second equipment;
wherein the first preset condition is that,
the distance between the first equipment and the second equipment is within a preset range; or,
the first device obtains a second user operation, and the second user operation is used for controlling the second device to execute the preset instruction.
13. The method according to any one of claims 10-12, wherein prior to transmitting the desensitization information to the second device, the method further comprises:
transmitting registration information to a second server through a first server;
receiving, by the first server, the desensitization information sent by the second server, where the first key related information corresponding to the desensitization information is generated by the second server according to the registration information;
The desensitization information is stored.
14. The method according to any of claims 10-13, wherein the first device and the second device interact information based on the hypertext transfer security protocol HTTPS, in case of communication between the first device and the second device using bluetooth BLE low energy technology.
15. The method of any one of claims 10 to 14, wherein the first key related information is stored within a first digital key application; the first digital key application is an application program carried in a software installation package, or a nested applet of an application platform, or a web page application program.
16. The device control method is characterized by being applied to second equipment, wherein sensitive information and second key related information in first key related information are stored in a safety element of the second equipment; the desensitization information in the first key related information is stored in the first device, the method comprising:
receiving the desensitization information sent by the first equipment;
combining the desensitization information and the sensitive information into the first key related information;
performing mutual authentication of the first device and the second device according to the first key related information and the second key related information;
And executing a preset instruction according to the authentication result.
17. The method of claim 16, wherein a second digital key application and a server application are disposed within the secure element of the second device, the server application having the sensitive information stored therein, the second digital key application having the second key-related information stored therein; the mutual authentication of the first device and the second device is performed according to the first key related information and the second key related information, and a preset instruction is executed according to an authentication result, including:
the server application sends card authentication information in the first key related information to the second digital key application, wherein the card authentication information is all or part of the first key related information;
the second digital key application generates a verification request ciphertext according to the card authentication information and the second key related information, and sends the verification request ciphertext to the server application;
the server application authenticates the second device according to the authentication request ciphertext; and after passing the authentication of the second device, sending a response ciphertext to the second digital key application;
The second digital key application authenticates the first device according to the response ciphertext; and after passing the authentication of the first device, controlling the second device to execute the preset instruction.
18. The method according to claim 16 or 17, characterized in that the method further comprises:
updating the first key related information and sending the desensitization information in the updated first key related information to the first device.
19. The method according to any one of claims 16 to 18, wherein prior to said receiving said desensitization information transmitted by said first device, said method further comprises:
mutually checking whether the identity of the opposite party is legal or not with the first equipment;
and after determining that the identities of the first device and the second device are legal, receiving the desensitization information sent by the first device.
20. A method according to any of claims 16-19, wherein the sensitive information and the second key related information are located within a secure element of the second device and on both sides of a firewall within the secure element.
21. A distributed digital key system comprising a first device and a second device, wherein the first device has stored therein desensitization information in first key related information; sensitive information and second key related information in the first key related information are stored in a secure element of the second device; the first device and the second device cooperate with each other to implement the device control method of any one of the preceding claims 1 to 9.
22. A first device, wherein the first device has stored therein desensitization information in first key related information; sensitive information in the first key related information is stored in a secure element of a second device, the first device being configured to perform the device control method of any of claims 10-15.
23. A second device, characterized in that sensitive information of the first key related information and second key related information are stored in a secure element of the second device, the second device being configured to perform the device control method according to any one of claims 16-20.
24. A computer-readable storage medium, characterized in that the computer-readable storage medium stores a computer program which, when executed by a processor, implements the method of any one of claims 10 to 15 or the device control method of any one of claims 16 to 20.
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210114846.2A CN116566594A (en) | 2022-01-30 | 2022-01-30 | Equipment control method, equipment and distributed digital key system |
PCT/CN2022/139977 WO2023142773A1 (en) | 2022-01-30 | 2022-12-19 | Device control method, device, and distributed digital key system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210114846.2A CN116566594A (en) | 2022-01-30 | 2022-01-30 | Equipment control method, equipment and distributed digital key system |
Publications (1)
Publication Number | Publication Date |
---|---|
CN116566594A true CN116566594A (en) | 2023-08-08 |
Family
ID=87470367
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202210114846.2A Pending CN116566594A (en) | 2022-01-30 | 2022-01-30 | Equipment control method, equipment and distributed digital key system |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN116566594A (en) |
WO (1) | WO2023142773A1 (en) |
Families Citing this family (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116723508B (en) * | 2023-08-04 | 2023-11-14 | 小米汽车科技有限公司 | Vehicle key creation method, device, storage medium and system |
CN117113311B (en) * | 2023-10-18 | 2024-03-01 | 紫光同芯微电子有限公司 | Method and device for terminal equipment identity verification and terminal equipment |
Family Cites Families (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR102511778B1 (en) * | 2018-03-05 | 2023-03-21 | 삼성전자주식회사 | Electronic device and method for performing digital key provision |
KR102626319B1 (en) * | 2018-05-23 | 2024-01-17 | 삼성전자주식회사 | Electronic device and method for storing digital key |
KR102545375B1 (en) * | 2018-09-14 | 2023-06-20 | 삼성전자 주식회사 | Electronic device for performing authorization using accessory and method for the same |
CN109558748B (en) * | 2018-11-23 | 2020-11-03 | 泰康保险集团股份有限公司 | Data processing method and device, electronic equipment and storage medium |
CN111835689B (en) * | 2019-04-22 | 2021-06-15 | 华为技术有限公司 | Identity authentication method of digital key, terminal device and medium |
CN110855616B (en) * | 2019-10-14 | 2021-11-23 | 中国第一汽车股份有限公司 | Digital key generation system |
CN111935672B (en) * | 2020-07-21 | 2022-10-25 | 捷德(中国)科技有限公司 | Information reading method, device, system and storage medium |
-
2022
- 2022-01-30 CN CN202210114846.2A patent/CN116566594A/en active Pending
- 2022-12-19 WO PCT/CN2022/139977 patent/WO2023142773A1/en unknown
Also Published As
Publication number | Publication date |
---|---|
WO2023142773A1 (en) | 2023-08-03 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US8064598B2 (en) | Apparatus, method and computer program product providing enforcement of operator lock | |
US10959092B2 (en) | Method and system for pairing wireless mobile device with IoT device | |
RU2518924C2 (en) | Wireless device, user access control client request method and access control client method | |
EP2630816B1 (en) | Authentication of access terminal identities in roaming networks | |
JP5031994B2 (en) | Authority delegation system, control device, and authority delegation method | |
WO2023142773A1 (en) | Device control method, device, and distributed digital key system | |
US7844834B2 (en) | Method and system for protecting data, related communication network and computer program product | |
EP3023899A1 (en) | Proximity authentication system | |
EP1873668A1 (en) | Integration of device integrity attestation into user authentication | |
US20050188219A1 (en) | Method and a system for communication between a terminal and at least one communication equipment | |
TW200531493A (en) | Method for authenticating applications | |
CN112396735B (en) | Internet automobile digital key safety authentication method and device | |
WO2002101981A1 (en) | Method and arrangement for encrypting data transfer at an interface in mobile equipment in radio network, and mobile equipment in radio network | |
WO2022017314A1 (en) | Information reading method, apparatus, system and storage medium | |
EP3376421A1 (en) | Method for authenticating a user and corresponding device, first and second servers and system | |
KR101716067B1 (en) | Method for mutual authentication between a terminal and a remote server by means of a third-party portal | |
CN109413648B (en) | Access control method, terminal, smart card, background server and storage medium | |
EP1728136A1 (en) | Method and system for the cipher key controlled exploitation of data resources, related network and computer program products | |
CN108352982B (en) | Communication device, communication method, and recording medium | |
GB2526619A (en) | Service provisioning | |
EP3732843A1 (en) | Systems and methods for providing authentication and/or authorization | |
Kasper et al. | Rights management with NFC smartphones and electronic ID cards: A proof of concept for modern car sharing | |
AU2019279983A1 (en) | Secure access to encrypted data of a user terminal | |
EP3933627B1 (en) | Authentication method | |
KR20170117682A (en) | Method and System for certificating electronic machines |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination |