Communication device detection method and apparatus, communication device, and storage medium
Patent Information
- Application Number
- CN202180001191.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-04-19
- Publication Date
- 2026-10-23
- Estimated Expiration
- 2041-04-19
AI Technical Summary
在蜂窝移动通信系统中,在测量之前,两个通信设备之间需要进行发现、授权等一系列过程,这些过程会消耗大量的时间和信令资源,并在系统存在大量测距需求时,给系统造成较大的压力
[0106]本公开实施例提供的通信设备检测方法、装置、通信设备以及存储介质。第一通信设备广播第一信息,其中,所述第一信息包括第二通信设备关联的第一标识ID和所述第一通信设备的公钥;接收第二信息;使用所述第一通信设备的私钥解密所述第二信息;确定解密所述第二信息成功,并且所述第二信息包括的第二ID与所述第一ID具有预定对应关系,确定检测到所述第二通信设备。如此,通过第一通信设备广播第一信息,和第二通信设备响应于第一信息中的第一ID广播的第二信息,第一通信设备实现对第二通信设备的发现。第二通信设备通过将携带于第一信息中的公钥对第二信息进行加密,提高了第一通信设备在发现第二通信设备过程中的安全性。
Smart Images

Figure CN115581125B_ABST
Abstract
Description
Technical Field
[0001] This application relates to, but is not limited to, the field of wireless communication technology, and particularly to communication equipment testing methods, apparatus, communication equipment, and storage media. Background Technology
[0002] Distance between communication devices can be measured using the time-of-flight (ToF) of signals. The measuring device sends a measurement signal to the device under test (DUT), and the DUT receives and sends a measurement signal back. The measuring device then calculates the distance between the devices based on the signal's flight time. In cellular mobile communication systems, a series of processes, including discovery and authorization, are required between the two communication devices before measurement. These processes consume significant time and signaling resources and can put considerable pressure on the system when there is a high demand for distance measurement. Summary of the Invention
[0003] In view of the above, embodiments of this disclosure provide a method, apparatus, communication device, and storage medium for detecting communication devices.
[0004] According to a first aspect of the present disclosure, a method for detecting a communication device is provided, wherein the method is performed by a first communication device, and the method includes:
[0005] Broadcast first information, wherein the first information includes a first identifier ID associated with the second communication device and the public key of the first communication device;
[0006] Receive the second message;
[0007] Decrypt the second information using the private key of the first communication device;
[0008] If the decryption of the second information is successful and the second ID included in the second information has a predetermined correspondence with the first ID, then the second communication device is detected.
[0009] In one embodiment, the first information is protected for integrity using the private key of the first communication device.
[0010] In one embodiment, the first information further includes a first random number, which is encrypted using the public key of the first communication device;
[0011] The determination that the second information has been successfully decrypted, and that the second information includes a second ID that has a predetermined correspondence with the first ID, and the determination that the second communication device has been detected, includes:
[0012] If the decryption of the second information is successful, and the second ID included in the second information has a predetermined correspondence with the first ID, and the second information includes the first random number, then the second communication device is detected.
[0013] In one embodiment, the method further includes:
[0014] If the second information does not include the first random number, discard the second information.
[0015] In one embodiment, the second information further carries a second random number;
[0016] The determination that the second information has been successfully decrypted, and that the second ID included in the second information has a predetermined correspondence with the first ID, and the determination that the second communication device has been detected, includes:
[0017] The system confirms that the second information has been successfully decrypted, and that the second ID included in the second information has a predetermined correspondence with the first ID. It also confirms that the second communication device has been detected by obtaining the second random number for the first time.
[0018] In one embodiment, the method further includes:
[0019] If it is determined that this is not the first time the second random number has been obtained, discard the second information.
[0020] In one embodiment, the method further includes,
[0021] Based on the flight time of the first information and the second information, the relative distance between the first communication device and the second communication device is determined, wherein the flight time of the first information and the second information includes the duration of propagation of the first information and the second information in the medium.
[0022] In one embodiment, the method further includes,
[0023] Based on a first time interval and a second time interval, the flight time of the first information and the second information is determined, wherein the first time interval is the duration from when the first communication device broadcasts the first information to when it receives the second information; and the second time interval is the duration from when the second communication device receives the first information to when it broadcasts the second information.
[0024] In one embodiment, the second information includes first indication information, which is used to indicate the second time interval.
[0025] In one embodiment, the method further includes:
[0026] Receive third information, wherein the third information includes second indication information, the second indication information being used to indicate the second time interval.
[0027] In one embodiment, the third information is encrypted using the public key of the first communication device;
[0028] The receipt of the third information includes:
[0029] Receive the third information;
[0030] The third information is decrypted using the private key of the first communication device.
[0031] In one embodiment, the third information further includes a third random number;
[0032] Determining the flight time of the first information and the second information based on the first time interval and the second time interval includes:
[0033] Once the third random number is received for the first time, the flight time is determined based on the first time interval and the second time interval.
[0034] In one embodiment, determining the flight time of the first information and the second information based on a first time interval and a second time interval includes:
[0035] The third information is determined to carry the second ID, and the flight time is determined based on the first time interval and the second time interval.
[0036] In one embodiment, the first information further carries an application ID, wherein the application ID is used to characterize the application that requires the relative distance.
[0037] In one embodiment, the first information further carries a command ID, wherein the command ID is used to characterize the first information;
[0038] The determination that the second information has been successfully decrypted, and that the second ID included in the second information has a predetermined correspondence with the first ID, and the determination that the second communication device has been detected, includes:
[0039] If the decryption of the second information is successful, and the second ID included in the second information has a predetermined correspondence with the first ID, and the second information includes the command ID, then the second communication device is detected.
[0040] According to a second aspect of the present disclosure, the method is provided to be performed by a second communication device, the method comprising:
[0041] Receive first information and obtain the first identifier ID and the public key of the first communication device included in the first information;
[0042] A predetermined correspondence is determined between the first ID and the second ID stored in the second communication device, and second information is broadcast, wherein the second information includes the second ID and is encrypted using the public key of the first communication device.
[0043] In one embodiment, the method further includes:
[0044] The integrity of the first information is verified using the public key of the first communication device.
[0045] In one embodiment, the first information further includes a first random number, wherein the first random number is encrypted using the public key of the first communication device;
[0046] The second information includes the first random number encrypted using the public key of the first communication device.
[0047] In one embodiment, the second information further includes: a second random number.
[0048] In one embodiment, the second information further includes first indication information, wherein the first indication information is used to indicate a second time interval, wherein the second time interval is the duration from when the second communication device receives the first information to when it broadcasts the second information.
[0049] In one embodiment, the first information also carries an application ID;
[0050] The method further includes: determining, based on the application ID, whether the first indication information is included in the second information.
[0051] In one embodiment, the method further includes,
[0052] Broadcast third information, wherein the third information carries second indication information, wherein the second indication information is used to indicate a second time interval, wherein the second time interval is the duration from when the second communication device receives the first information to when it broadcasts the second information.
[0053] In one embodiment, the third information is encrypted using the public key of the first communication device.
[0054] In one embodiment, the third information further includes a third random number.
[0055] In one embodiment, the third information further includes the second ID.
[0056] In one embodiment, the first information further includes a command ID;
[0057] The second information also includes the command ID.
[0058] According to a third aspect of the present disclosure, a communication device detection apparatus is provided, wherein the apparatus includes:
[0059] A broadcast module is used to broadcast first information, wherein the first information includes a first identifier ID associated with the second communication device and the public key of the first communication device;
[0060] The receiving module is used to receive the second information;
[0061] The decryption module is used to decrypt the second information using the private key of the first communication device;
[0062] The determination module is used to determine that the second information has been successfully decrypted, and that the second ID included in the second information has a predetermined correspondence with the first ID, and to determine that the second communication device has been detected.
[0063] In one embodiment, the first information is protected for integrity using the private key of the first communication device.
[0064] In one embodiment, the first information further includes a first random number, which is encrypted using the public key of the first communication device;
[0065] The module is specifically used for:
[0066] If the second information is successfully decrypted, and the second ID included in the second information has a predetermined correspondence with the first ID, and the second information includes the first random number, then the second communication device is detected.
[0067] In one embodiment, the receiving module is further configured to determine that the second information does not include the first random number, and discard the second information.
[0068] In one embodiment, the second information further carries a second random number;
[0069] The determining module is specifically used for:
[0070] The system confirms that the second information has been successfully decrypted, and that the second ID included in the second information has a predetermined correspondence with the first ID. It also confirms that the second communication device has been detected by obtaining the second random number for the first time.
[0071] In one embodiment, the receiving module is further configured to determine that the second random number is not being obtained for the first time, and discard the second information.
[0072] In one embodiment, the apparatus further includes:
[0073] The distance determination module is used to determine the relative distance between the first communication device and the second communication device based on the flight time of the first information and the second information, wherein the flight time of the first information and the second information includes the duration of propagation of the first information and the second information in the medium.
[0074] In one embodiment, the apparatus further includes:
[0075] The time determination module is used to determine the flight time of the first information and the second information based on a first time interval and a second time interval, wherein the first time interval is the duration from when the first communication device broadcasts the first information to when it receives the second information; and the second time interval is the duration from when the second communication device receives the first information to when it broadcasts the second information.
[0076] In one embodiment, the second information includes first indication information, which is used to indicate the second time interval.
[0077] In one embodiment, the receiving module is further configured to receive third information, wherein the third information includes second indication information, the second indication information being used to indicate the second time interval.
[0078] In one embodiment, the third information is encrypted using the public key of the first communication device;
[0079] The receiving module is further configured to decrypt the third information using the private key of the first communication device.
[0080] In one embodiment, the third information further includes a third random number;
[0081] The time determination module is specifically used to: determine the first time the third random number is received, and determine the flight time based on the first time interval and the second time interval.
[0082] In one embodiment, the time determination module is specifically used to: determine that the third information carries the second ID, and determine the flight time based on the first time interval and the second time interval.
[0083] In one embodiment, the first information further carries an application ID, wherein the application ID is used to characterize the application that requires the relative distance.
[0084] In one embodiment,
[0085] The first information also carries a command ID, wherein the command ID is used to identify the first information;
[0086] The determining module is specifically configured to: determine that the second information has been successfully decrypted, and determine that the second ID included in the second information has a predetermined correspondence with the first ID, and that the second information includes the command ID, and determine that the second communication device has been detected.
[0087] According to a fourth aspect of the present disclosure, an information transmission apparatus is provided, wherein the apparatus includes:
[0088] The receiving module is configured to receive first information and obtain the first identifier ID and the public key of the first communication device included in the first information;
[0089] The broadcast module is used to determine that the first ID and the second ID stored in the second communication device have a predetermined correspondence, and broadcast second information, wherein the second information includes the second ID, and the second information is encrypted using the public key of the first communication device.
[0090] In one embodiment, the receiving module is further configured to perform integrity verification on the first information using the public key of the first communication device.
[0091] In one embodiment, the first information includes a first random number, wherein the first random number is encrypted using the public key of the first communication device;
[0092] The second information includes the first random number encrypted using the public key of the first communication device.
[0093] In one embodiment, the second information further includes: a second random number.
[0094] In one embodiment, the second information further includes first indication information, wherein the first indication information is used for a second time interval, wherein the second time interval is the duration from when the second communication device receives the first information to when it broadcasts the second information.
[0095] In one embodiment, the first information also carries an application ID;
[0096] The device further includes:
[0097] The judgment module is used to determine, based on the application ID, whether the first indication information is included in the second information.
[0098] In one embodiment, the broadcast module is further configured to broadcast third information, wherein the third information carries second indication information, wherein the second indication information is used to indicate a second time interval, wherein the second time interval is the duration from when the second communication device receives the first information to when it broadcasts the second information.
[0099] In one embodiment, the third information is encrypted using the public key of the first communication device.
[0100] In one embodiment, the third information further includes a third random number.
[0101] In one embodiment, the third information further includes the second ID.
[0102] In one embodiment, the first information further includes a command ID;
[0103] The second information also includes the command ID.
[0104] According to a fifth aspect of the present disclosure, a communication device apparatus is provided, including a processor, a memory, and an executable program stored in the memory and executable by the processor, wherein when the processor runs the executable program, it performs steps of the communication device detection method of the first aspect or the information transmission method of the second aspect.
[0105] According to a sixth aspect of the present disclosure, a computer-readable storage medium is provided that stores instructions, when executed, to cause the method described in the first or second aspect to be implemented.
[0106] This disclosure provides a communication device detection method, apparatus, communication device, and storage medium. A first communication device broadcasts first information, wherein the first information includes a first identifier ID associated with a second communication device and the public key of the first communication device; receives second information; decrypts the second information using the private key of the first communication device; determines that the decryption of the second information was successful and that the second ID included in the second information has a predetermined correspondence with the first ID, and determines that the second communication device has been detected. Thus, by the first communication device broadcasting the first information and the second communication device broadcasting the second information in response to the first ID in the first information, the first communication device discovers the second communication device. The second communication device improves the security of the first communication device in the process of discovering the second communication device by encrypting the second information with the public key carried in the first information.
[0107] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit the embodiments of this disclosure. Attached Figure Description
[0108] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments of the invention and, together with the description, serve to explain the principles of the embodiments of the invention.
[0109] Figure 1 This is a schematic diagram illustrating the structure of a wireless communication system according to an exemplary embodiment;
[0110] Figure 2 This is a flowchart illustrating a communication device detection method according to an exemplary embodiment;
[0111] Figure 3 This is a schematic diagram of flight time according to an exemplary embodiment;
[0112] Figure 4 This is a flowchart illustrating another information transmission method according to an exemplary embodiment;
[0113] Figure 5 This is a block diagram illustrating a communication device detection apparatus according to an exemplary embodiment;
[0114] Figure 6 This is a block diagram illustrating another information transmission device according to an exemplary embodiment;
[0115] Figure 7 This is a block diagram illustrating an apparatus for detecting or transmitting information in a communication device according to an exemplary embodiment. Detailed Implementation
[0116] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numerals in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with those of the present invention. Rather, they are merely examples of apparatuses and methods consistent with some aspects of the embodiments of the present invention as detailed in the appended claims.
[0117] The terminology used in this disclosure is for the purpose of describing particular embodiments only and is not intended to be limiting of the present disclosure. The singular forms “a,” “the,” and “the” as used in this disclosure and the appended claims are also intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the term “and / or” as used herein refers to and includes any and all possible combinations of one or more of the associated listed items.
[0118] It should be understood that although the terms first, second, third, etc., may be used to describe various information in embodiments of this disclosure, such information should not be limited to these terms. These terms are only used to distinguish information of the same type from one another. For example, first information may also be referred to as second information without departing from the scope of embodiments of this disclosure, and similarly, second information may also be referred to as first information. Depending on the context, the word "if" as used herein may be interpreted as "when," "when," or "in response to a determination."
[0119] Please refer to Figure 1 This illustration shows a schematic diagram of the structure of a wireless communication system provided in an embodiment of this disclosure. Figure 1 As shown, the wireless communication system is a communication system based on cellular mobile communication technology. The wireless communication system may include: a number of terminals 11 and a number of base stations 12.
[0120] Terminal 11 can be a device that provides voice and / or data connectivity to a user. Terminal 11 can communicate with one or more core networks via a Radio Access Network (RAN). Terminal 11 can be an Internet of Things (IoT) terminal, such as a sensor device, a mobile phone (or "cellular" phone), and a computer with an IoT terminal. For example, it can be a fixed, portable, pocket-sized, handheld, computer-embedded, or vehicle-mounted device. Examples include a station (STA), subscriber unit, subscriber station, mobile station, mobile station, remote station, access point, remote terminal, access terminal, user terminal, user agent, user device, or user equipment (UE). Alternatively, terminal 11 can also be a device in an unmanned aerial vehicle (UAV). Alternatively, terminal 11 can also be a vehicle-mounted device, such as a vehicle computer with wireless communication capabilities, or a wireless communication device connected to an external vehicle computer. Alternatively, terminal 11 can also be a roadside device, such as a street light, traffic light, or other roadside device with wireless communication capabilities.
[0121] Base station 12 can be a network-side device in a wireless communication system. This wireless communication system can be a fourth-generation mobile communication (4G) system, also known as a Long Term Evolution (LTE) system; or it can be a 5G system, also known as a New Radio (NR) system or a 5G NR system. Alternatively, it can be a next-generation system after 5G. In this case, the access network in the 5G system can be called NG-RAN (New Generation-Radio Access Network). Alternatively, it can be an MTC system.
[0122] In this embodiment, base station 12 can be an evolved NB (eNB) used in a 4G system. Alternatively, base station 12 can also be a gNB (gNB) using a centralized-distributed architecture in a 5G system. When base station 12 adopts a centralized-distributed architecture, it typically includes a central unit (CU) and at least two distributed units (DU). The central unit is equipped with a protocol stack of Packet Data Convergence Protocol (PDCP), Radio Link Control (RLC), and Media Access Control (MAC) layers; the distributed units are equipped with a physical (PHY) layer protocol stack. This disclosure does not limit the specific implementation of base station 12.
[0123] Base station 12 and terminal 11 can establish a wireless connection via a wireless air interface. In different implementations, the wireless air interface is a wireless air interface based on the fourth-generation mobile communication network technology (4G) standard; or, the wireless air interface is a wireless air interface based on the fifth-generation mobile communication network technology (5G) standard, such as a new air interface; or, the wireless air interface can also be a wireless air interface based on a next-generation mobile communication network technology standard based on 5G.
[0124] In some embodiments, terminals 11 can also establish E2E (End to End) connections. Examples include V2V (vehicle to vehicle), V2I (vehicle to Infrastructure), and V2P (vehicle to pedestrian) communication scenarios in vehicle-to-everything (V2X) communication.
[0125] In some embodiments, the wireless communication system described above may further include a network management device 13.
[0126] Several base stations 12 are connected to network management device 13. Network management device 13 can be a core network device in a wireless communication system, such as a Mobility Management Entity (MME) in an Evolved Packet Core (EPC). Alternatively, it can be other core network devices, such as a Serving Gateway (SGW), a Public Data Network Gateway (PGW), a Policy and Charging Rules Function (PCRF), or a Home Subscriber Server (HSS). The implementation of network management device 13 is not limited in this embodiment.
[0127] The execution entities involved in the embodiments disclosed herein include, but are not limited to, UEs such as mobile phone terminals that support cellular mobile communication.
[0128] One application scenario of this disclosure is that when cellular mobile communication devices such as UEs (User Equipment) and base stations perform ranging, they need to go through a series of processes such as discovery and authorization, which consume a lot of time and signaling resources. How to reduce the signaling consumption and ranging time during the ranging process is an urgent problem to be solved.
[0129] like Figure 2 As shown, this exemplary embodiment provides a communication device detection method, which can be applied to a first communication device, including:
[0130] Step 201: Broadcast first information, wherein the first information includes a first ID associated with the second communication device and the public key of the first communication device;
[0131] Step 202: Receive the second message;
[0132] Step 203: Decrypt the second information using the private key of the first communication device;
[0133] Step 204: Determine that the second information has been successfully decrypted, and that the second ID included in the second information has a predetermined correspondence with the first ID, and determine that the second communication device has been detected.
[0134] The first and second communication devices can be mobile terminals, etc., that use cellular mobile communication technology for wireless communication.
[0135] The first communication device does not need to establish a communication connection with the second communication device and can directly transmit the first information via broadcast. For example, the first communication device can broadcast the first information on supported frequency domain resources. The first communication device can also transmit the first information on predetermined time-frequency resources. The frequency domain resources and / or time-frequency resources can be pre-configured or dynamically configured by the communication network.
[0136] The second communication device can receive the first information on supported frequency domain resources and / or on predetermined time-frequency resources. For example, the second communication device can receive the first information through blind detection or other methods.
[0137] After receiving the first information, the second communication device can compare the stored second ID with the first ID. The predetermined correspondence can be a unique correspondence. For example, the predetermined correspondence can be an equality relationship. The first ID and the second ID can be the same or different, and both the first ID and the second ID can have a unique association with the second communication device. For example, both the first ID and the second ID can uniquely identify the second communication device. For example, the first ID and the second ID can be the same, and both can be the International Mobile Subscriber Identity (IMSI) of the second communication device. The first ID and / or the second ID can be pre-configured or dynamically configured by applications, 3GPP networks, or configured according to agreed-upon rules.
[0138] If the second communication device determines that the second ID and the first ID have a predetermined correspondence, and can determine that the first information was sent to the second communication device, then it can broadcast the second information. The second information may carry the second ID.
[0139] In one embodiment, the first ID is an identifier of the second communication device that the first communication device expects to discover, stored locally; the second ID is an identifier stored locally by the second communication device. The first ID and the second ID have a unique pairing relationship, and a successful pairing indicates that the first communication device has successfully authenticated the second communication device.
[0140] The second communication device does not need to establish a communication connection with the first communication device and can directly transmit the second information via broadcast. For example, the second communication device can broadcast the second information on supported frequency domain resources, or it can transmit the second information on predetermined time-frequency resources. The frequency domain resources and / or time-frequency resources can be pre-configured or dynamically configured by the communication network.
[0141] The first communication device can receive the second information on supported frequency domain resources and / or on predetermined time-frequency resources. The first communication device can receive the second information through methods such as blind detection.
[0142] The first communication device can determine that the second information was sent by the second communication device based on the second ID carried in the second information, and thus determine that the second communication device has been detected.
[0143] The public key of the first communication device can be carried in the first information and sent to the second communication device. The public key of the first communication device can at least be used by the second communication device to encrypt the second information sent to the first communication device, thereby improving the security of information between the first and second communication devices.
[0144] Thus, by broadcasting first information through the first communication device and broadcasting second information in response to the first ID in the first information through the second communication device, the first communication device discovers the second communication device. The second communication device enhances the security of the first communication device in the process of discovering the second communication device by encrypting the second information with the public key carried in the first information.
[0145] In one embodiment, the first information is protected for integrity using the private key of the first communication device.
[0146] When broadcasting the first information, the first communication device can use its private key and the first information to form an integrity signature through a predetermined algorithm.
[0147] After receiving the first information, the second communication device can decrypt the integrity signature using the public key of the first communication device. The decryption result is then compared with the received first information. If the comparison results match, the first information is determined to be complete and undamaged during transmission. If the comparison results do not match, the first information is determined to be incomplete and damaged during transmission. Subsequent steps, such as sending the second information, will not be performed.
[0148] In this way, the second communication device can ensure the integrity of the first information, thereby improving the reliability of the first information transmission.
[0149] In one embodiment, the first information further includes a first random number, which is encrypted using the public key of the first communication device;
[0150] The determination that the second information has been successfully decrypted, and that the second information includes a second ID that has a predetermined correspondence with the first ID, and the determination that the second communication device has been detected, includes:
[0151] If the decryption of the second information is successful, and the second ID included in the second information has a predetermined correspondence with the first ID, and the second information includes the first random number, then the second communication device is detected.
[0152] When the first communication device sends the first information, it may carry a first random number encrypted with the public key of the first communication device in the first information; the second communication device may decrypt the first random number using the public key of the first communication device.
[0153] When the second communication device sends the second information, it may carry a first random number encrypted with the public key of the first communication device in the second information;
[0154] When the first communication device receives the second information, it can decrypt it to determine the first random number carried in the second information. The encrypted second random number can be used by the first communication device to determine whether the second information has been replayed by a third-party device. Since the third-party device cannot decrypt the first random number, the replayed second information cannot carry the first random number encrypted with the first communication device's public key; therefore, the replay of the second information by the third-party device can be recognized and discarded by the first communication device.
[0155] When the second message carries a first random number encrypted with the public key of the first communication device, it indicates that the second message was sent by the second communication device and has not been replayed. The first communication device can use the information associated with the second message for subsequent processing, such as determining whether the second communication device has been detected based on the second ID in the second message.
[0156] This improves the security of the second information transmission.
[0157] In one embodiment, the method further includes:
[0158] If the second information does not include the first random number, discard the second information.
[0159] If the second message does not contain a first random number encrypted with the public key of the first communication device, it indicates that the second message has a high probability of being replayed by a third-party device, posing a security risk. The second communication device may discard the second message.
[0160] This improves the security of the second information transmission.
[0161] In one embodiment, the second information further carries a second random number;
[0162] The determination that the second information has been successfully decrypted, and that the second ID included in the second information has a predetermined correspondence with the first ID, and the determination that the second communication device has been detected, includes:
[0163] The system confirms that the second information has been successfully decrypted, and that the second ID included in the second information has a predetermined correspondence with the first ID. It also confirms that the second communication device has been detected by obtaining the second random number for the first time.
[0164] The second random number can be generated by the second communication device and sent to the first communication device in the second information.
[0165] After receiving the second random number carried in the second information, the first communication device can compare it with multiple historical random numbers from previously received messages. If the second random number is the same as the historical random numbers, it means that the second information is not being received for the first time and can be discarded. If the second random number is different from all historical random numbers, it means that the second information is being received for the first time, and the first communication device can use the information associated with the second information for subsequent processing. For example, the first communication device can determine whether a second communication device has been detected based on the second ID in the second information.
[0166] In this way, the first communication device can determine whether the received second information is a duplicate message by using the first random number, thereby reducing the possibility of error processing caused by receiving the second information repeatedly.
[0167] In one embodiment, the method further includes:
[0168] If it is determined that this is not the first time the second random number has been obtained, discard the second information.
[0169] If the second random number is different from the historical random number, it means that the second information is not being received for the first time, and the first communication device can discard the second information.
[0170] In this way, the first communication device can determine whether the received second information is a duplicate message by using the first random number, thereby reducing the possibility of error processing caused by receiving the second information repeatedly.
[0171] In one embodiment, the method further includes,
[0172] Based on the flight time of the first information and the second information, the relative distance between the first communication device and the second communication device is determined, wherein the flight time of the first information and the second information includes the duration of propagation of the first information and the second information in the medium.
[0173] The first communication device can record the time of sending the first information and the time of receiving the second information, thereby determining the total transmission time of the first and second information. Since the second communication device experiences a certain delay between receiving the first information and broadcasting the second information, the first communication device can estimate this delay, or the second communication device can send the second information after a fixed delay. Thus, based on the total transmission time and the estimated or fixed delay, the first communication device can determine the flight time of the first and second information, and then, according to the propagation speed of electromagnetic waves in the medium, determine the relative distance between the first and second communication devices, thereby completing the ranging operation.
[0174] Thus, ranging between the first and second communication devices can be completed by sending information at least twice. In contrast to related technologies, ranging between the first and second communication devices requires steps such as discovery, authentication, authorization, and measurement. The method provided in this embodiment greatly reduces signaling interaction, reduces the time required for ranging, and improves ranging efficiency.
[0175] In one embodiment, the method further includes,
[0176] Based on a first time interval and a second time interval, the flight time of the first information and the second information is determined, wherein the first time interval is the duration from when the first communication device broadcasts the first information to when it receives the second information; and the second time interval is the duration from when the second communication device receives the first information to when it broadcasts the second information.
[0177] like Figure 3 As shown, the first communication device can record the time point when the first information is sent and the time point when the second information is received, thereby determining the total transmission time of the first and second communication devices interacting with the first and second information, i.e., the first time interval Δt1. Since the second communication device experiences a certain response delay between receiving the first information and broadcasting the second information, i.e., the second time interval Δt2.
[0178] The first communication device can determine the actual flight time Δt1-Δt2 of the first information and the second information based on the first time interval Δt1 and the second time interval Δt2.
[0179] Furthermore, the first communication device can use the expression shown in expression (1) to calculate the relative distance S between the first communication device and the second communication device.
[0180] S=(Δt1-Δt2)×c / 2 (1)
[0181] Where c represents the speed at which electromagnetic waves propagate in the medium; for example, c can be the speed of light.
[0182] In one embodiment, the second information includes first indication information, which is used to indicate the second time interval.
[0183] In response to the second communication device determining a second time interval before the second information is sent, for example, the second communication device can estimate the second time interval before sending the second information, or the second time interval is a fixed duration, etc., then the second communication device can send the first indication information indicating the second time interval to the first communication device in the second information.
[0184] After receiving the second information, the first communication device can determine the second time interval, and then determine the relative distance between the first communication device and the second communication device.
[0185] In this way, the first and second communication devices can determine the relative distance by exchanging information twice without establishing a communication connection, reducing signaling interaction, shortening the time required for ranging, and improving ranging efficiency.
[0186] In one embodiment, the method further includes:
[0187] Receive third information, wherein the third information includes second indication information, the second indication information being used to indicate the second time interval.
[0188] In response to the second communication device being unable to determine the second time interval before the second information is sent, for example, the second communication device needs to send the second information before it can determine the second time interval, the second communication device can send the second indication information indicating the second time interval in the third information to the first communication device.
[0189] The second communication device may transmit the third information directly via broadcast without establishing a communication connection with the first communication device. For example, the second communication device may broadcast the third information on supported frequency domain resources, and / or the second communication device may transmit the third information on predetermined time-frequency resources. The predetermined frequency domain resources / time-frequency resources may be pre-configured or dynamically configured by the communication network.
[0190] The first communication device can listen for and receive third information on supported frequency domain resources, and / or receive third information on predetermined time-frequency resources. The first communication device can receive third information through methods such as blind detection.
[0191] After receiving the third information, the first communication device can determine the second time interval, and then determine the relative distance between the first communication device and the second communication device.
[0192] In this way, the first and second communication devices can determine the relative distance without establishing a communication connection, reducing signaling interactions caused by establishing a communication connection, reducing the time required for distance measurement, and improving distance measurement efficiency.
[0193] In one embodiment, the third information is encrypted using the public key of the first communication device;
[0194] The receipt of the third information includes:
[0195] Receive the third information;
[0196] The third information is decrypted using the private key of the first communication device.
[0197] To improve the information security of the third message, the second communication device can encrypt the third message using the public key of the first communication device when sending it.
[0198] After receiving the third information encrypted with the public key of the first communication device, the first communication device can decrypt it with the private key of the first communication device, thereby parsing the third information and obtaining the second time interval carried by the third information.
[0199] Thus, by encrypting the third information, the security of the third information during transmission can be increased.
[0200] In one embodiment, the third information further includes a third random number;
[0201] Determining the flight time of the first information and the second information based on the first time interval and the second time interval includes:
[0202] Once the third random number is received for the first time, the flight time is determined based on the first time interval and the second time interval.
[0203] The third random number can be generated by the second communication device and sent to the first communication device in the third information.
[0204] After receiving the third random number carried in the third information, the first communication device can compare it with multiple historical random numbers from previously received messages. If the third random number is the same as the historical random numbers, it means that the third information is not being received for the first time and can be discarded. If the third random number is different from all historical random numbers, it means that the third information is being received for the first time, and the flight time can be determined using the second time interval carried in the third information, thereby determining the relative distance between the first and second communication devices.
[0205] Thus, the first communication device can determine whether the received third information is a duplicate message by using the third random number.
[0206] In one embodiment, determining the flight time of the first information and the second information based on a first time interval and a second time interval includes:
[0207] The third information is determined to carry the second ID, and the flight time is determined based on the first time interval and the second time interval.
[0208] The third piece of information may carry a second ID indicating the second communication device.
[0209] The first communication device can determine the sender of the third information based on a comparison between the second ID and the first ID stored in the first communication device. The first ID and the second ID can be used to uniquely identify the second communication device. The first ID and the second ID can have a unique correspondence; for example, the first ID can be equal to the second ID.
[0210] The first communication device can determine that the third information was sent by the second communication device based on the second ID, and the second time interval in the third information is the time interval corresponding to the second communication device, thereby determining the flight time of the first information and the second information between the first communication device and the second communication device.
[0211] Thus, when the first communication device simultaneously performs distance measurement with multiple second communication devices, it can distinguish the third information sent by different second communication devices, reduce the error in calculating the second time interval due to uncertainty about the sender of the second information, and thereby improve the accuracy of relative distance measurement.
[0212] In one embodiment, the first information further carries an application ID, wherein the application ID is used to characterize the application that requires the relative distance.
[0213] The application ID indicates the application requesting the relative distance measurement. The second communication device can determine the application requesting the relative distance measurement based on the application ID, and determine whether to perform the distance measurement based on the application's permission management. If the application is allowed to perform the distance measurement, subsequent steps are performed, such as sending second and third information. If the application is not allowed to perform the distance measurement, subsequent steps may not be performed, such as not including the indication information for the second time interval in the second information.
[0214] In one embodiment, the first information further carries a command ID, wherein the command ID is used to characterize the first information;
[0215] The determination that the second information has been successfully decrypted, and that the second ID included in the second information has a predetermined correspondence with the first ID, and the determination that the second communication device has been detected, includes:
[0216] If the decryption of the second information is successful, and the second ID included in the second information has a predetermined correspondence with the first ID, and the second information includes the command ID, then the second communication device is detected.
[0217] The first and second pieces of information can be associated using the command ID.
[0218] The first communication device carries a command ID in the first information. A second communication device can carry the command ID in its second information in response to this first information. When the first communication device receives the second information, it can determine the corresponding first information based on the command ID. During relative distance measurement, the first time interval in the first information corresponding to the second time interval in the second information can be determined.
[0219] In cases where relative distance measurements are performed between a first communication device and multiple second communication devices, the second information corresponding to different first information can be distinguished, reducing errors in relative distance measurement caused by the inability to determine the associated first and second information, and improving the accuracy of relative distance measurement.
[0220] In one embodiment, determining the flight time of the first information and the second information based on a first time interval between the first communication device broadcasting the first information and receiving the second information, and a second time interval between the second communication device receiving the first information and broadcasting the second information, includes: in response to the third information carrying the command ID, determining the flight time of the first information and the second information based on the first time interval and the second time interval.
[0221] When the first communication device receives the third information, it can determine the corresponding third information based on the command ID. During the relative distance measurement process, it can determine the first time interval in the first information that corresponds to the second time interval in the third information.
[0222] In cases where relative distance measurements are performed between a first communication device and multiple second communication devices, the third information corresponding to different first information can be distinguished, reducing errors in relative distance measurement caused by the inability to determine the associated first and third information, and improving the accuracy of relative distance measurement.
[0223] like Figure 4 As shown in the exemplary embodiment, this communication device detection method is provided. The communication device detection method can be applied to a second communication device and includes:
[0224] Step 401: Receive first information and obtain the first ID and the public key of the first communication device included in the first information;
[0225] Step 402: Determine that the first ID and the second ID stored in the second communication device have a predetermined correspondence, and broadcast the second information, wherein the second information includes the second ID, and the second information is encrypted using the public key of the first communication device.
[0226] The first and second communication devices can be mobile terminals, etc., that use cellular mobile communication technology for wireless communication.
[0227] The first communication device does not need to establish a communication connection with the second communication device and can directly transmit the first information via broadcast. For example, the first communication device can broadcast the first information on supported frequency domain resources. The first communication device can also transmit the first information on predetermined time-frequency resources. The frequency domain resources and / or time-frequency resources can be pre-configured or dynamically configured by the communication network.
[0228] The second communication device can receive the first information on supported frequency domain resources and / or on predetermined time-frequency resources. For example, the second communication device can receive the first information through blind detection or other methods.
[0229] After receiving the first information, the second communication device can compare the stored second ID with the first ID. The predetermined correspondence can be a unique correspondence. For example, the predetermined correspondence can be an equality relationship. The first ID and the second ID can be the same or different, and both the first ID and the second ID can have a unique association with the second communication device. For example, both the first ID and the second ID can uniquely identify the second communication device. For example, the first ID and the second ID can be the same, and both can be the International Mobile Subscriber Identity (IMSI) of the second communication device. The first ID and / or the second ID can be pre-configured or dynamically configured by applications, 3GPP networks, or configured according to agreed-upon rules.
[0230] If the second communication device determines that the second ID and the first ID have a predetermined correspondence, and can determine that the first information was sent to the second communication device, then it can broadcast the second information. The second information may carry the second ID.
[0231] In this embodiment, the first ID is the identifier of the second communication device that the first communication device expects to discover, stored locally; the second ID is the identifier stored locally by the second communication device. The first ID and the second ID have a unique pairing relationship, and a successful pairing indicates that the first communication device has successfully authenticated the second communication device.
[0232] The second communication device does not need to establish a communication connection with the first communication device and can directly transmit the second information via broadcast. For example, the second communication device can broadcast the second information on supported frequency domain resources, or it can transmit the second information on predetermined time-frequency resources. The frequency domain resources and / or time-frequency resources can be pre-configured or dynamically configured by the communication network.
[0233] The first communication device can receive the second information on supported frequency domain resources and / or on predetermined time-frequency resources. The first communication device can receive the second information through methods such as blind detection.
[0234] The first communication device can determine that the second information was sent by the second communication device based on the second ID carried in the second information, and thus determine that the second communication device has been detected.
[0235] The public key of the first communication device can be carried in the first information and sent to the second communication device. The public key of the first communication device can at least be used by the second communication device to encrypt the second information sent to the first communication device, thereby improving the security of information between the first and second communication devices.
[0236] Thus, by broadcasting first information through the first communication device and broadcasting second information in response to the first ID in the first information through the second communication device, the first communication device discovers the second communication device. The second communication device enhances the security of the first communication device in the process of discovering the second communication device by encrypting the second information with the public key carried in the first information.
[0237] In one embodiment, the method further includes:
[0238] The integrity of the first information is verified using the public key of the first communication device.
[0239] When broadcasting the first information, the first communication device can use its private key and the first information to form an integrity signature through a predetermined algorithm.
[0240] After receiving the first information, the second communication device can decrypt the integrity signature using the public key of the first communication device. The decryption result is then compared with the received first information. If the comparison results match, the first information is determined to be complete and undamaged during transmission. If the comparison results do not match, the first information is determined to be incomplete and damaged during transmission. Subsequent steps, such as sending the second information, will not be performed.
[0241] In this way, the second communication device can ensure the integrity of the first information, thereby improving the reliability of the first information transmission.
[0242] In one embodiment, the first information further includes a first random number, wherein the first random number is encrypted using the public key of the first communication device;
[0243] The second information includes the first random number encrypted using the public key of the first communication device.
[0244] When the first communication device sends the first information, it may carry a first random number encrypted with the public key of the first communication device in the first information; the second communication device may decrypt the first random number using the public key of the first communication device.
[0245] When the second communication device sends the second information, it may carry a first random number encrypted with the public key of the first communication device in the second information;
[0246] When the first communication device receives the second information, it can decrypt it to determine the first random number carried in the second information. The encrypted second random number can be used by the first communication device to determine whether the second information has been replayed by a third-party device. Since the third-party device cannot decrypt the first random number, the replayed second information cannot carry the first random number encrypted with the first communication device's public key; therefore, the replay of the second information by the third-party device can be recognized and discarded by the first communication device.
[0247] When the second message carries a first random number encrypted with the public key of the first communication device, it indicates that the second message was sent by the second communication device and has not been replayed. The first communication device can use the information associated with the second message for subsequent processing, such as determining whether the second communication device has been detected based on the second ID in the second message.
[0248] This improves the security of the second information transmission.
[0249] In one embodiment, the method further includes:
[0250] The first communication identifier determines that the second information does not include the first random number encrypted with the public key of the first communication device, and discards the second information.
[0251] If the second message does not contain a first random number encrypted with the public key of the first communication device, it indicates that the second message has a high probability of being replayed by a third-party device, posing a security risk. The second communication device may discard the second message.
[0252] This improves the security of the second information transmission.
[0253] In one embodiment, the second information further includes: a second random number.
[0254] The second random number can be generated by the second communication device and sent to the first communication device in the second information.
[0255] After receiving the second random number carried in the second information, the first communication device can compare it with multiple historical random numbers from previously received messages. If the second random number is the same as the historical random numbers, it means that the second information is not being received for the first time and can be discarded. If the second random number is different from all historical random numbers, it means that the second information is being received for the first time, and the first communication device can use the information associated with the second information for subsequent processing. For example, the first communication device can determine whether a second communication device has been detected based on the second ID in the second information.
[0256] In this way, the first communication device can determine whether the received second information is a duplicate message by using the first random number, thereby reducing the possibility of errors caused by receiving duplicate second information.
[0257] In one embodiment, the method further includes:
[0258] If the first communication device determines that this is not the first time it has obtained the second random number, the first communication device discards the second information.
[0259] If the second random number is different from the historical random number, it means that the second information is not being received for the first time, and the first communication device can discard the second information.
[0260] In this way, the first communication device can determine whether the received second information is a duplicate message by using the first random number, thereby reducing the possibility of errors caused by receiving duplicate second information.
[0261] In one embodiment, the method further includes,
[0262] The first communication device determines the relative distance between the first communication device and the second communication device based on the flight time of the first information and the second information.
[0263] The first communication device can record the time of sending the first information and the time of receiving the second information, thereby determining the total transmission time of the first and second information. Since the second communication device experiences a certain delay between receiving the first information and broadcasting the second information, the first communication device can estimate this delay, or the second communication device can send the second information after a fixed delay. Thus, based on the total transmission time and the estimated or fixed delay, the first communication device can determine the flight time of the first and second information, and then, according to the propagation speed of electromagnetic waves in the medium, determine the relative distance between the first and second communication devices, thereby completing the ranging operation.
[0264] Thus, ranging between the first and second communication devices can be completed by sending information at least twice. In contrast to related technologies, ranging between the first and second communication devices requires steps such as discovery, authentication, authorization, and measurement. The method provided in this embodiment greatly reduces signaling interaction, reduces the time required for ranging, and improves ranging efficiency.
[0265] In one embodiment, the method further includes,
[0266] The first communication device determines the flight time of the first information and the second information based on a first time interval between the first communication device broadcasting the first information and receiving the second information, and a second time interval between the second communication device receiving the first information and broadcasting the second information.
[0267] like Figure 3 As shown, the first communication device can record the time point when the first information is sent and the time point when the second information is received, thereby determining the total transmission time of the first and second communication devices interacting with the first and second information, i.e., the first time interval Δt1. Since the second communication device experiences a certain response delay between receiving the first information and broadcasting the second information, i.e., the second time interval Δt2.
[0268] The first communication device can determine the actual flight time Δt1-Δt2 of the first information and the second information based on the first time interval Δt1 and the second time interval Δt2.
[0269] Furthermore, the first communication device can use the expression shown in expression (1) to calculate the relative distance S between the first communication device and the second communication device.
[0270] Where c represents the speed at which electromagnetic waves propagate in the medium; for example, c can be the speed of light.
[0271] In one embodiment, the second information further includes first indication information, wherein the first indication information is used to indicate a second time interval, wherein the second time interval is the duration from when the second communication device receives the first information to when it broadcasts the second information.
[0272] In response to the second communication device determining a second time interval before the second information is sent, for example, the second communication device can estimate the second time interval before sending the second information, or the second time interval is a fixed duration, etc., then the second communication device can send the first indication information indicating the second time interval to the first communication device in the second information.
[0273] After receiving the second information, the first communication device can determine the second time interval, and then determine the relative distance between the first communication device and the second communication device.
[0274] In this way, the first and second communication devices can determine the relative distance by exchanging information twice without establishing a communication connection, reducing signaling interaction, shortening the time required for ranging, and improving ranging efficiency.
[0275] In one embodiment, the first information also carries an application ID;
[0276] The method further includes: determining, based on the application ID, whether the first indication information is included in the second information.
[0277] The application ID indicates the application requesting the relative distance measurement. The second communication device can determine the application requesting the relative distance measurement based on the application ID, and determine whether to perform the distance measurement based on the application's permission management. If the application is allowed to perform the distance measurement, subsequent steps are performed, such as sending second and third information. If the application is not allowed to perform the distance measurement, subsequent steps may not be performed, such as not including the first indication information of the second time interval in the second information.
[0278] In one embodiment, the method further includes,
[0279] Broadcast third information, wherein the third information carries second indication information, wherein the second indication information is used to indicate a second time interval, wherein the second time interval is the duration from when the second communication device receives the first information to when it broadcasts the second information.
[0280] In response to the second communication device being unable to determine the second time interval before the second information is sent, for example, the second communication device needs to send the second information before it can determine the second time interval, the second communication device can send the second indication information indicating the second time interval in the third information to the first communication device.
[0281] The second communication device may transmit the third information directly via broadcast without establishing a communication connection with the first communication device. For example, the second communication device may broadcast the third information on supported frequency domain resources, and / or the second communication device may transmit the third information on predetermined time-frequency resources. The predetermined frequency domain resources / time-frequency resources may be pre-configured or dynamically configured by the communication network.
[0282] The first communication device can listen for and receive third information on supported frequency domain resources, and / or receive third information on predetermined time-frequency resources. The first communication device can receive third information through methods such as blind detection.
[0283] After receiving the third information, the first communication device can determine the second time interval, and then determine the relative distance between the first communication device and the second communication device.
[0284] In this way, the first and second communication devices can determine the relative distance without establishing a communication connection, reducing signaling interactions caused by establishing a communication connection, reducing the time required for distance measurement, and improving distance measurement efficiency.
[0285] In one embodiment, the third information is encrypted using the public key of the first communication device.
[0286] To improve the information security of the third message, the second communication device can encrypt the third message using the public key of the first communication device when sending it.
[0287] After receiving the third information encrypted with the public key of the first communication device, the first communication device can decrypt it with the private key of the first communication device, thereby parsing the third information and obtaining the second time interval carried by the third information.
[0288] Thus, by encrypting the third information, the security of the third information during transmission can be increased.
[0289] In one embodiment, the third information further includes a third random number.
[0290] The third random number can be generated by the second communication device and sent to the first communication device in the third information.
[0291] After receiving the third random number carried in the third information, the first communication device can compare it with multiple historical random numbers from previously received messages. If the third random number is the same as the historical random numbers, it means that the third information is not being received for the first time and can be discarded. If the third random number is different from all historical random numbers, it means that the third information is being received for the first time, and the flight time can be determined using the second time interval carried in the third information, thereby determining the relative distance between the first and second communication devices.
[0292] Thus, the first communication device can determine whether the received third information is a duplicate message by using the third random number.
[0293] In one embodiment, the third information further includes the second ID.
[0294] The third piece of information may carry a second ID indicating the second communication device.
[0295] The first communication device can determine the sender of the third information based on a comparison between the second ID and the first ID stored in the first communication device. The first ID and the second ID can be used to uniquely identify the second communication device. The first ID and the second ID can have a unique correspondence; for example, the first ID can be equal to the second ID.
[0296] The first communication device can determine that the third information was sent by the second communication device based on the second ID, and the second time interval in the third information is the time interval corresponding to the second communication device, thereby determining the flight time of the first information and the second information between the first communication device and the second communication device.
[0297] Thus, when the first communication device simultaneously performs distance measurement with multiple second communication devices, it can distinguish the third information sent by different second communication devices, reduce the error in calculating the second time interval due to uncertainty about the sender of the second information, and thereby improve the accuracy of relative distance measurement.
[0298] In one embodiment, the first information further includes a command ID;
[0299] The second information also includes the command ID.
[0300] The first and second pieces of information can be associated using the command ID.
[0301] The first communication device carries a command ID in the first information. A second communication device can carry the command ID in its second information in response to this first information. When the first communication device receives the second information, it can determine the corresponding first information based on the command ID. During relative distance measurement, the first time interval in the first information corresponding to the second time interval in the second information can be determined.
[0302] In cases where relative distance measurements are performed between a first communication device and multiple second communication devices, the second information corresponding to different first information can be distinguished, reducing errors in relative distance measurement caused by the inability to determine the associated first and second information, and improving the accuracy of relative distance measurement.
[0303] In one embodiment, broadcasting the third information further includes broadcasting the third information carrying the command ID.
[0304] When the first communication device receives the third information, it can determine the corresponding third information based on the command ID. During the relative distance measurement process, it can determine the first time interval in the first information that corresponds to the second time interval in the third information.
[0305] In cases where relative distance measurements are performed between a first communication device and multiple second communication devices, the third information corresponding to different first information can be distinguished, reducing errors in relative distance measurement caused by the inability to determine the associated first and third information, and improving the accuracy of relative distance measurement.
[0306] The following provides a specific example in conjunction with any of the above embodiments:
[0307] 1. For example Figure 3 As shown, the first communication device, i.e., the discovering UE, sends a first message. This first message is used to discover other nearby UEs participating in ranging, and then perform ranging. This message includes the application ID that triggered the message, the first ID of the second communication device, i.e., the discovered UE, the public key of the discovering UE, and a random number X generated by the discovering UE, wherein the random number X is encrypted using the discovering UE's public key. If necessary, the first message may also include the message's command ID. The complete first message should be protected for integrity using the discovering UE's private key.
[0308] 2. The discovered UE uses the public key of the discovered UE to verify the integrity of the first information. The first information that fails the verification is discarded, and the second information is sent based on the first information that is successfully verified.
[0309] 2.1 If the discovered UE can confirm Δt2 before sending the second information, the second information should include the discovered UE's second ID, Δt2, the random number Y generated by the discovered UE, and the encrypted random number X. If necessary, it can include the command ID from step 1. The complete second information should be encrypted using the discovered UE's public key.
[0310] 2.2 If the UE can only confirm Δt2 after the second information is sent, the second information should include the second ID of the discovered UE, the random number Y generated by the discovered UE, and the encrypted random number X. If necessary, the command ID can be included. The complete second information should be encrypted using the public key of the discovered UE before the third information is sent.
[0311] 3. The discovered UE sends a third message, which should include the discovered UE's second ID, Δt2, and a random number Z generated by the discovered UE, and a command ID if necessary. The complete third message should be encrypted using the discovered UE's public key.
[0312] 4. The UE discovers that it has obtained the second ID of the discovered UE by decrypting the message using its private key, and performs a pairing verification between the locally stored first ID and the received second ID to confirm that the second and third messages originate from the discovered UE. Simultaneously, the discovered UE decrypts random number X using its private key to confirm whether the first message has been replayed. If the first message has been replayed, the discovered UE discards all received messages. If the first message has not been replayed, the discovered UE further checks random number Y or random number Z to confirm whether the second and third messages have been replayed.
[0313] 5. It was discovered that the UE obtained Δt2 by parsing the message with its private key.
[0314] 6. The distance between the discovered UE and the detected UE can be expressed by the expression (1) if the UE obtains Δt1 by the time the first information is sent and the time the second information arrives.
[0315] This invention also provides a communication device detection apparatus, applied in a first communication device, such as... Figure 5 As shown, the communication equipment detection device 100 includes:
[0316] Broadcast module 110 is used to broadcast first information, wherein the first information includes a first identifier ID associated with the second communication device and the public key of the first communication device;
[0317] Receiver module 120 is used to receive the second information;
[0318] Decryption module 130 is used to decrypt the second information using the private key of the first communication device;
[0319] The determination module 140 is used to determine that the second information has been successfully decrypted and that the second ID included in the second information has a predetermined correspondence with the first ID, and to determine that the second communication device has been detected.
[0320] In one embodiment, the first information is protected for integrity using the private key of the first communication device.
[0321] In one embodiment, the first information further includes a first random number, which is encrypted using the public key of the first communication device;
[0322] Module 140 is specifically used for:
[0323] If the second information is successfully decrypted, and the second ID included in the second information has a predetermined correspondence with the first ID, and the second information includes the first random number, then the second communication device is detected.
[0324] In one embodiment, the receiving module 120 is further configured to determine that the second information does not include the first random number and discard the second information.
[0325] In one embodiment, the second information further carries a second random number;
[0326] The determining module 140 is specifically used for:
[0327] The system confirms that the second information has been successfully decrypted, and that the second ID included in the second information has a predetermined correspondence with the first ID. It also confirms that the second communication device has been detected by obtaining the second random number for the first time.
[0328] In one embodiment, the receiving module 120 is further configured to determine that the second random number is not being obtained for the first time, and discard the second information.
[0329] In one embodiment, the device 100 further includes:
[0330] The distance determination module 150 is used to determine the relative distance between the first communication device and the second communication device based on the flight time of the first information and the second information, wherein the flight time of the first information and the second information includes the duration of propagation of the first information and the second information in the medium.
[0331] In one embodiment, the device 100 further includes:
[0332] The time determination module 160 is used to determine the flight time of the first information and the second information based on a first time interval and a second time interval, wherein the first time interval is the duration from when the first communication device broadcasts the first information to when it receives the second information; and the second time interval is the duration from when the second communication device receives the first information to when it broadcasts the second information.
[0333] In one embodiment, the second information includes first indication information, which is used to indicate the second time interval.
[0334] In one embodiment, the receiving module 120 is further configured to receive third information, wherein the third information includes second indication information, the second indication information being used to indicate the second time interval.
[0335] In one embodiment, the third information is encrypted using the public key of the first communication device;
[0336] The receiving module 120 is further configured to decrypt the third information using the private key of the first communication device.
[0337] In one embodiment, the third information further includes a third random number;
[0338] The time determination module 160 is specifically used to: determine the first time the third random number is received, and determine the flight time based on the first time interval and the second time interval.
[0339] In one embodiment, the time determination module 160 is specifically configured to: determine that the third information carries the second ID, and determine the flight time based on the first time interval and the second time interval.
[0340] In one embodiment, the first information further carries an application ID, wherein the application ID is used to characterize the application that requires the relative distance.
[0341] In one embodiment,
[0342] The first information also carries a command ID, wherein the command ID is used to identify the first information;
[0343] The determining module 140 is specifically used to: determine that the second information has been successfully decrypted, and determine that the second ID included in the second information has a predetermined correspondence with the first ID, and that the second information includes the command ID, and determine that the second communication device has been detected.
[0344] This invention also provides an information transmission device, applied in a second communication device, such as... Figure 6 As shown, the information transmission device 200 includes:
[0345] The receiving module 210 is configured to receive first information and obtain the first identifier ID and the public key of the first communication device included in the first information;
[0346] The broadcast module 220 is used to determine that the first ID and the second ID stored in the second communication device have a predetermined correspondence, and broadcast second information, wherein the second information includes the second ID, and the second information is encrypted using the public key of the first communication device.
[0347] In one embodiment, the receiving module 210 is further configured to perform integrity verification on the first information using the public key of the first communication device.
[0348] In one embodiment, the first information includes a first random number, wherein the first random number is encrypted using the public key of the first communication device;
[0349] The second information includes the first random number encrypted using the public key of the first communication device.
[0350] In one embodiment, the second information further includes: a second random number.
[0351] In one embodiment, the second information further includes first indication information, wherein the first indication information is used for a second time interval, wherein the second time interval is the duration from when the second communication device receives the first information to when it broadcasts the second information.
[0352] In one embodiment, the first information also carries an application ID;
[0353] The device 200 further includes:
[0354] The judgment module 230 is used to determine, based on the application ID, whether the first indication information is included in the second information.
[0355] In one embodiment, the broadcast module 220 is further configured to broadcast third information, wherein the third information carries second indication information, wherein the second indication information is used to indicate a second time interval, wherein the second time interval is the duration from when the second communication device receives the first information to when it broadcasts the second information.
[0356] In one embodiment, the third information is encrypted using the public key of the first communication device.
[0357] In one embodiment, the third information further includes a third random number.
[0358] In one embodiment, the third information further includes the second ID.
[0359] In one embodiment, the first information further includes a command ID;
[0360] The second information also includes the command ID.
[0361] In an exemplary embodiment, the broadcast module 110, receiving module 120, decryption module 130, determining module 140, distance determining module 150, time determining module 160, receiving module 210, broadcast module 220, and determining module 230 may be implemented by one or more central processing units (CPUs), graphics processing units (GPUs), baseband processors (BPs), application-specific integrated circuits (ASICs), DSPs, programmable logic devices (PLDs), complex programmable logic devices (CPLDs), field-programmable gate arrays (FPGAs), general-purpose processors, controllers, microcontrollers (MCUs), microprocessors, or other electronic components to perform the aforementioned method.
[0362] Figure 7 This is a block diagram illustrating an apparatus 3000 for detecting or transmitting information from a communication device, according to an exemplary embodiment. For example, apparatus 3000 may be a mobile phone, computer, digital broadcasting terminal, messaging device, game console, tablet device, medical device, fitness equipment, personal digital assistant, etc.
[0363] Reference Figure 7 The device 3000 may include one or more of the following components: processing component 3002, memory 3004, power supply component 3006, multimedia component 3008, audio component 3010, input / output (I / O) interface 3012, sensor component 3014, and communication component 3016.
[0364] Processing component 3002 typically controls the overall operation of device 3000, such as operations associated with display, telephone calls, data communication, camera operation, and recording operations. Processing component 3002 may include one or more processors 3020 to execute instructions to complete all or part of the steps of the methods described above. Furthermore, processing component 3002 may include one or more modules to facilitate interaction between processing component 3002 and other components. For example, processing component 3002 may include a multimedia module to facilitate interaction between multimedia component 3008 and processing component 3002.
[0365] Memory 3004 is configured to store various types of data to support the operation of device 3000. Examples of this data include instructions for any application or method operating on device 3000, contact data, phonebook data, messages, pictures, videos, etc. Memory 3004 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.
[0366] Power supply component 3006 provides power to various components of device 3000. Power supply component 3006 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to device 3000.
[0367] Multimedia component 3008 includes a screen that provides an output interface between device 3000 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touchscreen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensors may sense not only the boundaries of touch or swipe actions but also the duration and pressure associated with the touch or swipe operation. In some embodiments, multimedia component 3008 includes a front-facing camera and / or a rear-facing camera. When device 3000 is in an operating mode, such as a shooting mode or a video mode, the front-facing camera and / or rear-facing camera may receive external multimedia data. Each front-facing camera and rear-facing camera may be a fixed optical lens system or have focal length and optical zoom capabilities.
[0368] Audio component 3010 is configured to output and / or input audio signals. For example, audio component 3010 includes a microphone (MIC) configured to receive external audio signals when device 3000 is in an operating mode, such as call mode, recording mode, and voice recognition mode. The received audio signals may be further stored in memory 3004 or transmitted via communication component 3016. In some embodiments, audio component 3010 also includes a speaker for outputting audio signals.
[0369] I / O interface 3012 provides an interface between processing component 3002 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to, home buttons, volume buttons, power buttons, and lock buttons.
[0370] Sensor assembly 3014 includes one or more sensors for providing state assessment of various aspects of device 3000. For example, sensor assembly 3014 may detect the on / off state of device 3000, the relative positioning of components, such as the display and keypad of device 3000, changes in position of device 3000 or a component of device 3000, the presence or absence of user contact with device 3000, orientation or acceleration / deceleration of device 3000, and temperature changes of device 3000. Sensor assembly 3014 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. Sensor assembly 3014 may also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, sensor assembly 3014 may also include an accelerometer, gyroscope, magnetometer, pressure sensor, or temperature sensor.
[0371] Communication component 3016 is configured to facilitate wired or wireless communication between device 3000 and other devices. Device 3000 can access wireless networks based on communication standards, such as Wi-Fi, 2G, or 3G, or combinations thereof. In one exemplary embodiment, communication component 3016 receives broadcast signals or broadcast-related information from an external broadcast management system via a broadcast channel. In one exemplary embodiment, communication component 3016 also includes a near-field communication (NFC) module to facilitate short-range communication. For example, the NFC module may be implemented based on radio frequency identification (RFID) technology, Infrared Data Association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
[0372] In an exemplary embodiment, the apparatus 3000 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field-programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the methods described above.
[0373] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, such as a memory 3004 including instructions, which can be executed by a processor 3020 of the device 3000 to perform the above-described method. For example, the non-transitory computer-readable storage medium may be a ROM, random access memory (RAM), CD-ROM, magnetic tape, floppy disk, and optical data storage device, etc.
[0374] Other embodiments of the invention will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of the embodiments of the invention that follow the general principles of the embodiments of the invention and include common knowledge or customary techniques in the art not disclosed in this disclosure. The specification and embodiments are to be considered exemplary only, and the true scope and spirit of the embodiments of the invention are indicated by the following claims.
[0375] It should be understood that the embodiments of the present invention are not limited to the precise structures described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from their scope. The scope of the embodiments of the present invention is limited only by the appended claims.
Claims
1. A method for detecting communication equipment, wherein, The method is performed by a first communication device, and the method includes: Broadcast first information, wherein the first information includes a first identifier ID associated with the second communication device, the public key of the first communication device, an application ID, and a first random number; the first random number is encrypted using the public key of the first communication device; the application ID is used to represent an application that requires the relative distance between the first communication device and the second communication device; The system receives second information sent by the second communication device, wherein the first information is verified for integrity by the second communication device using the public key of the first communication device, and the second information is sent based on the successfully verified first information; the second information includes a second ID, a first random number, and a second random number. Decrypt the second information using the private key of the first communication device; If it is determined that the second information was successfully decrypted, that the second ID included in the second information has a predetermined correspondence with the first ID, and that the second information includes the first random number, then it is determined that the second communication device was detected. Based on the second random number, determine the first time to obtain the second information; Based on a first time interval and a second time interval, the flight time of the first information and the second information is determined, wherein the first time interval is the duration from when the first communication device broadcasts the first information to when it receives the second information; the second time interval is the duration from when the second communication device receives the first information to when it broadcasts the second information; the flight time of the first information and the second information includes the duration of the first information and the second information propagating in the medium; Based on the flight time of the first and second information, the relative distance between the first and second communication devices is determined.
2. The method according to claim 1, wherein, The first information is protected for integrity using the private key of the first communication device.
3. The method according to claim 1, wherein, The method further includes: If the first random number is not included in the second information, the second information is discarded.
4. The method according to claim 1, wherein, The method further includes: The system determines that the second information has been successfully decrypted, that the second ID included in the second information has a predetermined correspondence with the first ID, and that the second random number has been obtained for the first time, and that the second communication device has been detected.
5. The method according to claim 4, wherein, The method further includes: If it is determined that this is not the first time the second random number has been obtained, discard the second information.
6. The method according to claim 1, wherein, The second information includes first indication information, which is used to indicate the second time interval.
7. The method according to claim 1, wherein, The method further includes: Receive third information, wherein the third information includes second indication information, the second indication information being used to indicate the second time interval.
8. The method according to claim 7, wherein, The third information is encrypted using the public key of the first communication device; The receipt of the third information includes: Receive the third information; The third information is decrypted using the private key of the first communication device.
9. The method according to claim 7, wherein, The third information also includes a third random number; Determining the flight time of the first information and the second information based on the first time interval and the second time interval includes: Once the third random number is received for the first time, the flight time is determined based on the first time interval and the second time interval.
10. The method according to claim 7, wherein, Determining the flight time of the first information and the second information based on the first time interval and the second time interval includes: The third information is determined to carry the second ID, and the flight time is determined based on the first time interval and the second time interval.
11. The method according to any one of claims 1 to 5, wherein, The first information also carries a command ID, which is used to identify the first information; The method further includes: If it is determined that the second information was successfully decrypted, that the second ID included in the second information has a predetermined correspondence with the first ID, and that the second information includes the command ID, then it is determined that the second communication device was detected.
12. An information transmission method, wherein, The method is performed by a second communication device, and the method includes: Receive first information, wherein the first information includes a first identifier ID associated with the second communication device, a public key of the first communication device, an application ID, and a first random number; the first random number is encrypted using the public key of the first communication device; the application ID is used to characterize an application that requires the relative distance between the first communication device and the second communication device; The integrity of the first information is verified using the public key of the first communication device. A predetermined correspondence is determined between the first ID and the second ID stored in the second communication device, and second information is broadcast, wherein the second information includes the second ID, the first random number, and the second random number; the second information is encrypted using the public key of the first communication device. Wherein, the second information is decrypted by the first communication device using the private key of the first communication device; the successful decryption of the second information by the first communication device, the existence of a predetermined correspondence between the second ID included in the second information and the first ID, and the inclusion of the first random number in the second information enable the first communication device to determine that the second communication device has been detected; the second random number is used by the first communication device to determine that the second information is acquired for the first time. The first time interval and the second time interval are used by the first communication device to determine the flight time of the first information and the second information. The first time interval is the duration from when the first communication device broadcasts the first information to when it receives the second information; the second time interval is the duration from when the second communication device receives the first information to when it broadcasts the second information. The flight time of the first information and the second information includes the duration of propagation of the first information and the second information in the medium. The flight time of the first information and the second information is used by the first communication device to determine the relative distance between the first communication device and the second communication device.
13. The method according to claim 12, wherein, The first random number included in the second information is encrypted using the public key of the first communication device.
14. The method according to claim 12 or 13, wherein, The second information also includes first indication information, which is used to indicate the second time interval.
15. The method according to claim 14, wherein, The method further includes: Based on the application ID, determine whether the first indication information is included in the second information.
16. The method according to claim 12 or 13, wherein, The method also includes, Broadcast third information, wherein the third information carries second indication information, the second indication information being used to indicate the second time interval.
17. The method according to claim 16, wherein, The third information is encrypted using the public key of the first communication device.
18. The method according to claim 16, wherein, The third information also includes a third random number.
19. The method of claim 16, wherein, The third piece of information also includes the second ID.
20. The method according to claim 12 or 13, wherein, The first information also includes the command ID; The second information also includes the command ID.
21. A communication equipment testing device, wherein, The device includes: A broadcast module is used to broadcast first information, wherein the first information includes a first identifier ID associated with the second communication device, a public key of the first communication device, an application ID, and a first random number; the first random number is encrypted using the public key of the first communication device; the application ID is used to represent an application that requires the relative distance between the first communication device and the second communication device; A receiving module is configured to receive second information sent by the second communication device, wherein the first information is verified for integrity by the second communication device using the public key of the first communication device, and the second information is sent based on the successfully verified first information; the second information includes a second ID, a first random number, and a second random number; The decryption module is used to decrypt the second information using the private key of the first communication device; The determination module is used to determine that the second information has been successfully decrypted, that the second ID included in the second information has a predetermined correspondence with the first ID, and that the second information includes the first random number, and to determine that the second communication device has been detected. The determining module is used to determine, based on the second random number, the first acquisition of the second information; A time determination module is used to determine the flight time of the first information and the second information based on a first time interval and a second time interval, wherein the first time interval is the duration from when the first communication device broadcasts the first information to when it receives the second information; the second time interval is the duration from when the second communication device receives the first information to when it broadcasts the second information; the flight time of the first information and the second information includes the duration of the first information and the second information propagating in the medium; The distance determination module is used to determine the relative distance between the first communication device and the second communication device based on the flight time of the first information and the second information.
22. The apparatus according to claim 21, wherein, The first information is protected for integrity using the private key of the first communication device.
23. The apparatus according to claim 21, wherein, The receiving module is further configured to discard the second information if the first random number is not included in the second information.
24. The apparatus according to claim 21, wherein, The determining module is specifically used for: The system determines that the second information has been successfully decrypted, that the second ID included in the second information has a predetermined correspondence with the first ID, and that the second random number has been obtained for the first time, and that the second communication device has been detected.
25. The apparatus according to claim 24, wherein, The receiving module is further configured to determine that the second random number is not being obtained for the first time, and to discard the second information.
26. The apparatus according to claim 21, wherein, The second information includes first indication information, which is used to indicate the second time interval.
27. The apparatus according to claim 21, wherein, The receiving module is further configured to receive third information, wherein the third information includes second indication information, which is used to indicate the second time interval.
28. The apparatus according to claim 27, wherein, The third information is encrypted using the public key of the first communication device; The receiving module is further configured to decrypt the third information using the private key of the first communication device.
29. The apparatus according to claim 27, wherein, The third information also includes a third random number; The time determination module is specifically used to: determine the first time the third random number is received, and determine the flight time based on the first time interval and the second time interval.
30. The apparatus according to claim 27, wherein, The time determination module is specifically used to: determine that the third information carries the second ID, and determine the flight time based on the first time interval and the second time interval.
31. The apparatus according to any one of claims 21 to 25, wherein, The first information also carries a command ID, which is used to identify the first information; The determining module is specifically used to: determine that the second information has been successfully decrypted, that the second ID included in the second information has a predetermined correspondence with the first ID, and that the second information includes the command ID, and to determine that the second communication device has been detected.
32. An information transmission device, wherein, The device includes: A receiving module is configured to receive first information, wherein the first information includes a first identifier ID associated with the second communication device, a public key of the first communication device, an application ID, and a first random number; the first random number is encrypted using the public key of the first communication device; the application ID is used to characterize an application that requires the relative distance between the first communication device and the second communication device; The receiving module is further configured to perform integrity verification on the first information using the public key of the first communication device; The broadcast module is used to determine that the first ID and the second ID stored in the second communication device have a predetermined correspondence, and broadcast second information, wherein the second information includes the second ID, the first random number, and the second random number; the second information is encrypted using the public key of the first communication device. Wherein, the second information is decrypted by the first communication device using the private key of the first communication device; the successful decryption of the second information by the first communication device, the existence of a predetermined correspondence between the second ID included in the second information and the first ID, and the inclusion of the first random number in the second information enable the first communication device to determine that the second communication device has been detected; the second random number is used by the first communication device to determine that the second information is acquired for the first time. The first time interval and the second time interval are used by the first communication device to determine the flight time of the first information and the second information. The first time interval is the duration from when the first communication device broadcasts the first information to when it receives the second information; the second time interval is the duration from when the second communication device receives the first information to when it broadcasts the second information. The flight time of the first information and the second information includes the duration of propagation of the first information and the second information in the medium. The flight time of the first information and the second information is used by the first communication device to determine the relative distance between the first communication device and the second communication device.
33. The apparatus according to claim 32, wherein, The first random number included in the second information is encrypted using the public key of the first communication device.
34. The apparatus according to claim 32 or 33, wherein, The second information also includes first indication information, wherein the first indication information is used to indicate the second time interval.
35. The apparatus according to claim 34, wherein, The device further includes: The judgment module is used to determine, based on the application ID, whether the first indication information is included in the second information.
36. The apparatus according to claim 32 or 33, wherein, The broadcast module is also used to broadcast third information, which carries second indication information, and the second indication information is used to indicate a second time interval.
37. The apparatus according to claim 36, wherein, The third information is encrypted using the public key of the first communication device.
38. The apparatus according to claim 36, wherein, The third information also includes a third random number.
39. The apparatus according to claim 36, wherein, The third piece of information also includes the second ID.
40. The apparatus according to claim 32 or 33, wherein, The first information also includes the command ID; The second information also includes the command ID.
41. A communication device apparatus, comprising a processor, a memory, and an executable program stored in the memory and executable by the processor, wherein, When the processor runs the executable program, it performs the steps of the communication device detection method as described in any one of claims 1 to 11 and the information transmission method as described in any one of claims 12 to 20.
42. A computer-readable storage medium storing instructions that, when executed, cause the method as described in any one of claims 1 to 11, 12 to 20 to be implemented.
Citation Information
Patent Citations
Method for spotting equipment user, and user equipment
CN104243153A
Secure wireless network
US20070136596A1