Authentication interaction method of encrypted broadcast and Bluetooth broadcast authentication system

By generating authentication keys and encrypting data on the transmitting device in the Bluetooth broadcast system, and the receiving device autonomously calculating the expected key to match the connection, the problems of counterfeit risk and operational complexity in Bluetooth broadcasting are solved, and efficient and secure device connection is achieved.

CN120640285AActive Publication Date: 2025-09-12SHENZHEN FENGHEYUAN TECH
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202511140580.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-08-15
Publication Date
2025-09-12
Estimated Expiration
2045-08-15

AI Technical Summary

Technical Problem

Bluetooth broadcasting carries the risk of counterfeiting and operational complexity, especially the lack of effective encryption mechanisms in unencrypted broadcasting, resulting in low connection security and poor user experience. Encrypted broadcasting requires pairing with a mobile terminal, which is inefficient.

Method used

The transmitting device generates broadcast name information and digital code, calculates the authentication key through a preset algorithm to encrypt the data to be encrypted, and the receiving device scans the broadcast data packet and calculates the expected authentication key through the same algorithm. If they match, a Bluetooth connection is established and the broadcast information is decrypted.

Benefits of technology

It improves the matching and connection efficiency between the transmitting device and the receiving device, simplifies the operation process, reduces the risk of counterfeiting, and improves the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120640285A_ABST
    Figure CN120640285A_ABST
Patent Text Reader

Abstract

The invention discloses an authentication interaction method of encrypted broadcast and a Bluetooth broadcast authentication system, relates to the field of wireless communication, is applied to the Bluetooth broadcast authentication system, comprises a transmitting device and a receiving device, and comprises the following steps: the transmitting device generates broadcast name information and a digital code, calculates an authentication key through a preset algorithm, and sends the authentication key to the receiving device; encrypting the to-be-encrypted data according to the authentication key to obtain encrypted broadcast information; the transmitting equipment transmits a broadcast data packet containing broadcast name information, digital codes and encrypted broadcast information; a receiving device scans the broadcast data packet, and calculates through a preset algorithm to obtain an expected authentication key; and if the expected authentication key is matched with the authentication key, the receiving device establishes a Bluetooth connection with the transmitting device, and the receiving device decrypts the encrypted broadcast information. Therefore, the mode of generating the authentication key by the transmitting equipment is the same as that of generating the expected authentication key by the receiving equipment, and the receiving equipment can autonomously generate the expected authentication key so as to improve the matching connection efficiency of the two.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of wireless communications, and more specifically, to an authentication interaction method for encrypted broadcasting and a Bluetooth broadcast authentication system. Background Art

[0002] Bluetooth broadcasting is categorized as encrypted and unencrypted. Unencrypted broadcasting techniques lack effective encryption mechanisms, posing a risk of counterfeiting and reducing the security of the connection between the transmitting and receiving devices. Encrypted broadcasting techniques require a mobile terminal (e.g., a cell phone) as a transfer medium to pair the transmitting and receiving devices, resulting in low efficiency and complex operations, impacting the user experience. Summary of the Invention

[0003] In view of the above problems, this application proposes an encrypted broadcast authentication interaction method and a Bluetooth broadcast authentication system to solve the above problems.

[0004] In the first aspect, an embodiment of the present application provides an authentication interaction method for encrypted broadcast, which is applied to a Bluetooth broadcast authentication system. The Bluetooth broadcast authentication system includes a transmitting device and a receiving device. The method includes: the transmitting device generates broadcast name information and a digital code, calculates an authentication key through a preset algorithm, and encrypts the encrypted data according to the authentication key to obtain encrypted broadcast information; the transmitting device transmits a broadcast data packet containing broadcast name information, digital code and encrypted broadcast information; the receiving device scans the broadcast data packet, calculates through a preset algorithm, and obtains the expected authentication key; if the expected authentication key matches the authentication key, the receiving device establishes a Bluetooth connection with the transmitting device, and the receiving device decrypts the encrypted broadcast information.

[0005] In the second aspect, an embodiment of the present application provides a Bluetooth broadcast authentication system, which includes a transmitting device and a receiving device, wherein: the transmitting device is used to generate broadcast name information and digital code, calculate the authentication key through a preset algorithm, and encrypt the encrypted data according to the authentication key to obtain encrypted broadcast information; the transmitting device is used to transmit a broadcast data packet containing broadcast name information, digital code and encrypted broadcast information; the receiving device is used to scan the broadcast data packet, calculate through a preset algorithm, and obtain the expected authentication key; the receiving device is used to establish a Bluetooth connection with the transmitting device if the expected authentication key matches the authentication key, and the receiving device decrypts the encrypted broadcast information.

[0006] The technical solution provided by this application is applied to a Bluetooth broadcast authentication system, which includes a transmitting device and a receiving device. The method includes: the transmitting device generates broadcast name information and a digital code, calculates an authentication key through a preset algorithm, and encrypts the encrypted data according to the authentication key to obtain encrypted broadcast information; the transmitting device transmits a broadcast data packet containing the broadcast name information, the digital code, and the encrypted broadcast information; the receiving device scans the broadcast data packet and calculates the expected authentication key through a preset algorithm; if the expected authentication key matches the authentication key, the receiving device establishes a Bluetooth connection with the transmitting device, and the receiving device decrypts the encrypted broadcast information. As a result, the transmitting device generates the authentication key in the same way as the receiving device generates the expected authentication key, so that the receiving device can autonomously generate the expected authentication key, thereby improving the efficiency of the matching connection between the transmitting device and the receiving device. BRIEF DESCRIPTION OF THE DRAWINGS

[0007] In order to more clearly illustrate the technical solutions in the embodiments of this application, the following is a brief introduction to the drawings required for describing the embodiments. Obviously, the drawings described below are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments and drawings obtained by ordinary technicians in this field without creative work are within the scope of protection of this invention.

[0008] Figure 1 A schematic structural diagram of a Bluetooth broadcast authentication system provided in an embodiment of the present application is shown.

[0009] Figure 2 A flow chart of an encrypted broadcast authentication interaction method provided in an embodiment of the present application is shown.

[0010] Figure 3 A flow chart of another encrypted broadcast authentication interaction method provided in an embodiment of the present application is shown.

[0011] Figure 4 A schematic structural diagram of a computer-readable storage medium provided in an embodiment of the present application is shown. DETAILED DESCRIPTION

[0012] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application.

[0013] Bluetooth broadcasts are categorized as encrypted and unencrypted. Unencrypted broadcasting typically involves receiving devices identifying the broadcast directly based on the broadcast's corresponding identity, lacking effective encryption mechanisms and posing a risk of counterfeiting. Separate encryption can be applied to the broadcast source device, such as a speaker or a computer-connected wireless transmitter (dongle). The transmitter itself has an authentication password, which can be factory-set or user-defined. The factory-set setting is typically the default, indicated on the product itself or in the user's manual. Some products can also be customized or modified based on user preferences.

[0014] In the relevant technologies of encrypted broadcasting, a wireless transmitter can usually not only encrypt its broadcast information separately, but also has the ability to transmit the audio information of the connected speakers or computers through Bluetooth broadcasting. When mobile devices such as speakers or computers do not have Bluetooth broadcasting functions themselves, they also need to be configured with a wireless transmitter. At this time, the wireless transmitter acts as a transmitting device and only transmits broadcast signals to the outside world. The receiving device outside can scan the Bluetooth broadcast signal. After the receiving device enters the password, it can be paired with it to complete the broadcast network and transmit the broadcast signal. Since the wireless transmitter itself has no input interface and the receiving device requires password verification, the traditional wireless transmitter needs to rely on a medium for transmitting password pairing, such as a mobile phone app. After the mobile phone is connected to the receiving device by Bluetooth, it will be displayed in the app. After selecting the receiving device and entering the password, the device connected to the mobile phone can receive the broadcast of the transmitting device. This method requires the collaboration of multiple devices and is complicated to operate. In addition, the visibility of the password and the reliance on the app to transmit the password pose the risk of password leakage. In the case of multiple transmitting devices, the mobile terminal will display multiple transmitting devices. The user needs to find the target transmitting device among the multiple displayed transmitting devices and then enter the decryption authentication code corresponding to the target transmitting device, which further reduces efficiency and increases the complexity of operation, affecting the user experience.

[0015] In order to improve the above problems, the present application provides an encrypted broadcast authentication interaction method and a Bluetooth broadcast authentication system. The encrypted broadcast authentication interaction method is applied to the Bluetooth broadcast authentication system. The Bluetooth broadcast authentication system includes a transmitting device and a receiving device. The method includes: the transmitting device generates broadcast name information and a digital code, calculates an authentication key through a preset algorithm, and encrypts the encrypted data according to the authentication key to obtain encrypted broadcast information; the transmitting device transmits a broadcast data packet containing broadcast name information, digital code and encrypted broadcast information; the receiving device scans the broadcast data packet, calculates through a preset algorithm, and obtains the expected authentication key; if the expected authentication key matches the authentication key, the receiving device establishes a Bluetooth connection with the transmitting device, and the receiving device decrypts the encrypted broadcast information.

[0016] Thus, the transmitting device generates the authentication key in the same manner as the receiving device generates the expected authentication key, so that the receiving device can autonomously generate the expected authentication key, thereby improving the efficiency of the matching connection between the transmitting device and the receiving device.

[0017] See also Figure 1 , Figure 1 FIG. 1 shows a schematic diagram of the structure of a Bluetooth broadcast authentication system provided by an embodiment of the present application. Figure 1 As shown, the Bluetooth broadcast authentication system 100 includes a transmitting device 110 and a receiving device 120. The transmitting device 110 and the receiving device 120 may be connected wirelessly, for example, via Bluetooth.

[0018] In some implementations, the broadcast source device is connected to an external wireless transmitter (dongle) and transmits the broadcast via the wireless transmitter, which serves as the transmitting device 110. The broadcast source device can be a laptop, desktop computer, mobile phone, headset, or electronic game console. For example, the electronic game console can be a PS4 or PS5.

[0019] In some embodiments, the receiving device 120 may include a headset, a Bluetooth headset, a TWS headset, a Bluetooth speaker, or other Bluetooth wireless receiver.

[0020] Before the transmitting device 110 and the receiving device 120 establish a wireless connection, they need to be paired and connected. After the pairing and connection between the transmitting device 110 and the receiving device 120 are completed, the transmitting device 110 can send audio information to the receiving device 120, and the receiving device 120 can play the audio information.

[0021] The transmitting device 110 encrypts the data to be encrypted by generating a unique and unpredictable authentication key, thereby obtaining encrypted broadcast information, and then broadcasts a broadcast data packet containing the broadcast name information, digital code, and encrypted broadcast information. After scanning the broadcast data packet, the receiving device 120 generates an expected authentication key in the same manner as the transmitting device 110 generates the authentication key. When the authentication key matches the expected authentication key, the pairing connection between the transmitting device 110 and the receiving device 120 is completed. Specifically: See also Figure 2 , Figure 2 FIG. 1 shows a flow chart of an authentication interaction method for encrypted broadcasting provided by an embodiment of the present application. Figure 2 As shown, the method may include steps 210 to 240, and may be applied to the above-mentioned Bluetooth broadcast authentication system. Specifically: In step 210, the transmitting device generates broadcast name information and a digital code, calculates an authentication key using a preset algorithm, and encrypts the data to be encrypted according to the authentication key to obtain encrypted broadcast information.

[0022] In some embodiments, the broadcast name information is the broadcast name information of the transmitting device, ie, the wireless transmitter. The broadcast name information can be a string formed by concatenating the device name, device model, and the last four digits of the Bluetooth address of the wireless transmitter.

[0023] The device name can be the prefix of the transmitting device. The prefix can be customized and is generally the brand name of the transmitting device. For example, the prefix of the brand of a wireless transmitter can be "BRD", "AUD", or "DEV".

[0024] The device model may be a model of a wireless transmitter. For example, the device model may be “Speaker 1 ,” “Mic,” or “Device,” etc.

[0025] A Bluetooth address is typically a 6-byte MAC address. The format of a Bluetooth address is: "XX:XX:XX:XX:XX:XX." For example, if the Bluetooth address is "11:22:33:44:55:66," the last four digits of the Bluetooth address are "5566." This means the last four digits of the Bluetooth address are the last four characters of the Bluetooth address, excluding the colon.

[0026] In some implementations, the Bluetooth address and the device name or device model are separated by an underscore character. For example: broadcast name information = "device name" + "device model" + "_" + "the last four digits of the Bluetooth address".

[0027] The transmitting device concatenates the device name, model, and the last four digits of the Bluetooth address to create a specific broadcast name. The Bluetooth address and device name or model are separated by an underscore character. The underscore character specifies the order of concatenation, making it more difficult to construct a disguised device and improving security.

[0028] In some embodiments, all characters are encoded in ASCII. That is, all characters included in the broadcast name information are encoded in ASCII. Encoding all characters in ASCII ensures that the broadcast name information remains consistent across devices, aligns with the 32-byte limit of Bluetooth advertising packets, unifies broadcast data, and reduces broadcast latency.

[0029] After constructing the broadcast name information, the transmitting device performs corresponding processing on the length of the broadcast name information to ensure that the length of the broadcast name information is an even number, so as to facilitate subsequent calculations or processing. Specifically, in some embodiments, if the character length of the string of the generated broadcast name information is an odd number, a space character is padded at the last bit of the string of the broadcast name information to make the character length of the string of the generated broadcast name information an even number.

[0030] The space character is only filled in the last digit of the character string of the broadcast name information, which can minimize the impact on the readability of the broadcast name information.

[0031] Ensuring that the character length of the broadcast name information string is an even number can facilitate subsequent calculations or processing. For example, in embedded systems or Bluetooth protocols, data is processed in bytes, and an even length can simplify memory access, checksum calculations (for example, CRC), or data transmission alignment with the 32-byte limit of Bluetooth broadcast packets (avoiding alignment issues).

[0032] It is understandable that if the length of the string corresponding to the broadcast name information of the transmitting device is an even number, then no further processing of the length of the broadcast name information is required. In other words, the transmitting device ultimately obtains the broadcast name information with an even length and entirely in ASCII encoding.

[0033] For example, the device name is "BRD", the device model is "Mic", and the Bluetooth address is "00:1A:7D:DA:71:13". The last four digits of the Bluetooth address are "7113". Based on the above data, the concatenated string is: "BRD" + "Mic" + "_" + "7113" = "BRDMic_7113". Since the length of the concatenated string "BRDMic_7113" is an odd number (11 characters), a space is added to the concatenated string "BRDMic_7113" to obtain the final broadcast name information "BRDMic_7113" (with a space at the end, a total of 12 characters).

[0034] For example, the device name is "DEV", the device model is "Device", and the Bluetooth address is "12:34:56:78:90:AB". The last four digits of the Bluetooth address are "90AB". Based on the above data, the concatenated string is "DEVDevice_90AB". Since the length of the concatenated string "DEVDevice_90AB" is an even number (14 characters), the final broadcast name information is "DEVDevice_90AB".

[0035] The sender obtains the broadcast name by concatenating the device name, device model, and the last four digits of the Bluetooth address. The sender calculates the length of the broadcast name and determines whether spaces need to be padded to make the length of the broadcast name an even number. The sender then constructs a broadcast name with an even length and full ASCII encoding.

[0036] Furthermore, the digital code is generated by the transmitting device, i.e., the wireless transmitter itself. In some embodiments, the digital code can be a unique broadcast ID, a unique identifier customized by the transmitting device manufacturer. When the transmitting device is started for the first time, an initial code is generated based on the hardware unique ID (such as the chip serial number).

[0037] In some embodiments, the digital code is a 4-byte integer, which is represented by a 6-digit string, wherein the value range of the string is 000001 to 999999. For example, the string corresponding to the digital code is "999999". Figure 2 As shown in the figure, when the device is first started, the digital code generates a 4-byte initial value through a hash operation based on the hardware unique identifier (such as the chip serial number) and converts it into a 6-digit string. This allows different devices to have different hardware IDs, and the 4-byte integer only occupies 32 bits of memory when stored. The 6-bit string transmission can adapt to the 6-8 byte payload limit of the BLE Bluetooth broadcast packet, saving storage space resources.

[0038] It is worth noting that if the string corresponding to the digital code is less than 6 digits, you can add 0 in front of the string corresponding to the digital code to make the string corresponding to the digital code 6 digits.

[0039] In some embodiments, the data to be encrypted may be data that a transmitting device intends to send to a receiving device. The transmitting device generates a unique and unpredictable authentication key for the transmitting device based on the broadcast name information, the digital code, and a preset algorithm. The transmitting device encrypts the data to be encrypted using the authentication key, thereby obtaining encrypted broadcast information. A broadcast data packet is then formed, including the broadcast name information, the digital code, and the encrypted broadcast information. The broadcast data packet is then broadcast for scanning by the receiving device. The broadcast data includes a plaintext portion and a ciphertext portion. The ciphertext portion is data encrypted by the authentication key, i.e., data obtained by encrypting the data to be encrypted using the authentication key.

[0040] In some implementations, the preset algorithm may be a preset MD5 algorithm. It is understood that the preset algorithm may also be other encryption algorithms, and this application does not impose specific limitations on this.

[0041] The transmitting device concatenates the generated broadcast name information and digital code, and then uses the concatenated output as input to a preset algorithm to obtain a unique and unpredictable authentication key of the Bluetooth broadcast authentication system through the preset algorithm. This allows the transmitting device to encrypt the data to be encrypted based on the authentication key, and then allows the receiving device to establish a Bluetooth connection with the transmitting device based on the match between the expected authentication key generated by the receiving device and the authentication key. Specifically: In some embodiments, the encrypted broadcast authentication interaction method may also include the following steps: (1) The transmitting device concatenates the broadcast name information string and the digitally encoded 6-bit string to generate the input string.

[0042] (2) Calculate the MD5 digest based on the input string using the preset MD5 algorithm, convert the MD5 digest into a 32-bit hexadecimal string, extract the first 6 hexadecimal characters in the MD5 digest and convert them to uppercase as the authentication key.

[0043] If the digital code is not a 6-bit string, it needs to be converted into a 6-bit string first, and then the string of the broadcast name information and the 6-bit string of the digital code are concatenated. For example, assuming the digital code is "123", the 6-bit string of the digital code is "000123". In some embodiments, the digital code is updated periodically, such as once every 24 hours. This is to improve the unpredictability of the authentication key generated in subsequent steps, thereby improving the security of the encrypted broadcast data. When updating, it can be updated according to the random number of the hardware device to improve dynamic protection, introduce the current random value of the hardware device (such as the current temperature of the device, obtained by the temperature sensor), and generate a random number based on the temperature. Even if the algorithm is known, the next code cannot be predicted. Then, the updated digital code is generated in combination with the algorithm for updating the code (current code + random number), and the range is ensured to be 000001~999999.

[0044] The transmitting device concatenates the broadcast name string and the 6-digit numeric code to create the input string. The transmitting device then calculates the MD5 digest of the concatenated string (i.e., the input string). The MD5 digest is then converted to a 32-character hexadecimal string (usually lowercase, but uppercase is required, so the final conversion is done). The first 6 hexadecimal characters of the MD5 digest (uppercase) are then used as the authentication key. The authentication key is generated using a pre-set MD5 algorithm, which irreversibly protects device information. Even if the authentication key is obtained, the device name or numeric code cannot be deduced. Furthermore, the MD5 calculation requires only 512 bytes of RAM, making it fast and time-efficient, better meeting the real-time requirements of Bluetooth broadcasts.

[0045] For example, the string format of the broadcast name information is "BRDSpeaker_7113" (with a space at the end, a total of 16 characters); the string format of the digital code is "000123"; then the input string is: "BRDSpeaker_7113" + "000123" = "BRDSpeaker_7113 000123". Directly concatenating the head and tail can reduce the length of the broadcast packet. Then, the concatenated input string is converted into a byte sequence, which can be expressed as: "B:66, R:82, D:68,S:83, p:112, e:101, a:97, k:107, e:101, r:114, _:95, 7:55, 1:49, 1:49, 3:51, space:32,0:48, 0:48, 0:48, 1:49, 2:50, 3:51", and then calculate the MD5 of these bytes. Assume that the calculated MD5 hexadecimal string (32 characters) is: "1a2b3c4d5e6f78901234567890abcdef", and take its first 6 characters (uppercase): "1A2B3C", then the authentication key is "1A2B3C".

[0046] For example, the broadcast name information is represented by a string of "AUDPlayer_EEFF"; the digitally encoded six-digit string is "000001." The resulting input string is "AUDPlayer_EEFF" + "000001" = "AUDPlayer_EEFF000001." The MD5 of "AUDPlayer_EEFF000001" is calculated as "7D1D45E0D5A9A8A7C4E8E9A0D0E8E5B5." The first six digits are taken as "7D1D45," resulting in the authentication key: "7D1D45." Unified uppercase hexadecimal notation eliminates platform compatibility issues, and a fixed truncation position (the first six digits) ensures that receiving devices do not require additional signaling to synchronize key positions, reducing protocol complexity and the computational burden on embedded devices (RAM usage is less than 1KB).

[0047] After obtaining the authentication key "1A2B3C," the authentication key is used to encrypt broadcast data packets sent by the transmitting device, rendering the broadcast private. Subsequent receiving devices must obtain the authentication key to decrypt the broadcast data packets. In some embodiments, after the digital code is periodically updated, for example, when the digital code "000123" is updated to "000124," the authentication key generated for the same broadcast name changes from "1A2B3C" to "8E9F0A." This key is also updated promptly before the broadcast is retransmitted, using the new authentication key for encryption.

[0048] It can be seen that the transmitting device forms the broadcast name information through the device name, device model and Bluetooth address, and then generates the unique and unpredictable authentication key of the Bluetooth broadcast authentication system based on the broadcast name information, the unique digital code of the transmitting device and the preset algorithm. The encrypted data is encrypted according to the authentication key to obtain the encrypted broadcast information. In step 220, the transmitting device transmits a broadcast data packet including broadcast name information, digital code, and encrypted broadcast information.

[0049] After generating a unique and unpredictable authentication key for the Bluetooth broadcast authentication system, the transmitting device encrypts the encrypted data according to the authentication key to obtain encrypted broadcast information, and then generates a broadcast data packet based on the broadcast name information, digital code and encrypted broadcast information, and broadcasts the generated broadcast data packet.

[0050] The broadcast data packet includes the broadcast name information and digital code of the wireless transmitter. The receiving device generates the authentication key through the same logic. When the receiving device scans the broadcast of the transmitting device from the outside, the broadcast data includes a plaintext part and a ciphertext part. The ciphertext is the data encrypted by the authentication key. The plaintext part can be directly scanned and parsed by the outside world, such as the name of the transmitting device, the device model of the transmitting device, the Bluetooth address of the transmitting device, the digital code of the transmitting device, etc. The plaintext part is extracted from the broadcast data packet and can be used as a decryption condition parameter. The receiving device is matched with the receiving device and has the same logical algorithm as the transmitting device. It uses the same method as the transmitting device to generate the authentication key to generate the expected authentication key to decrypt the encrypted broadcast information. Specifically: In step 230, the receiving device scans the broadcast data packet and obtains the expected authentication key through calculation using a preset algorithm.

[0051] When the receiving device scans a broadcast data packet, it extracts the broadcast name information and digital code included in the broadcast data packet, and then calculates the expected authentication key based on the broadcast name information, digital code and a preset algorithm.

[0052] In a specific embodiment, when the receiving device scans a broadcast data packet, it extracts the broadcast name information and digital code included in the broadcast data packet, then concatenates the character string of the broadcast name information and the 6-digit character string of the digital code to generate an input character string, and then calculates the MD5 digest based on the input character string using a preset MD5 algorithm, converts the MD5 digest into a 32-bit hexadecimal string, extracts the first 6 hexadecimal characters in the MD5 digest and converts them into uppercase as the expected authentication key.

[0053] For example, when the receiving device scans a broadcast data packet, it extracts the broadcast name information included in the broadcast data packet, the corresponding string format of which is "BRDSpeaker_7113 " (with a space at the end, a total of 16 characters), and the digitally encoded six-digit string is: "000123", which is concatenated to obtain the input string: "BRDSpeaker_7113 "+"000123"="BRDSpeaker_7113 000123", the corresponding byte format of which is "B:66, R:82, D:68,S:83, p:112, e:101, a:97, k:107, e:101, r:114, _:95, 7:55, 1:49, 1:49, 3:51, space:32,0:48, 0:48, 0:48, 1:49, 2:50, 3:51", calculate the MD5 of these bytes. Assuming the MD5 is "1a2b3c4d5e6f78901234567890abcdef", take its first 6 characters (uppercase) "1A2B3C", and get the expected authentication key "1A2B3C". Use this key to decrypt the ciphertext of the broadcast data packet. If the verification is successful, the authentication device is legitimate and the connection is successful.

[0054] It is understandable that in an application scenario where there are multiple transmitting devices, the receiving device may scan multiple broadcast data packets sent by different transmitting devices. In order to enable the receiving device to connect to the designated transmitting device first, the connection efficiency between the receiving device and the corresponding transmitting device can be improved. Figure 3 , Figure 3 A flow chart of another encrypted broadcast authentication interaction method provided by an embodiment of the present application is shown. Figure 3 As shown, in some embodiments, the encrypted broadcast authentication interaction method may further include the following steps: (1) When the receiving device scans the broadcast data packets sent by multiple transmitting devices, it identifies the broadcast name information format in the broadcast data packets respectively.

[0055] (2) If it matches the expected format, mark it as an encrypted transmitting device and save the record.

[0056] (3) If the format does not match the expected format, filter the transmitting device.

[0057] That is, when a receiving device scans broadcast data packets sent by multiple transmitting devices and extracts broadcast name information included in the broadcast data packets, it identifies the format of the broadcast name information and compares the format of the broadcast name information with the expected format. In other words, it first filters out the transmitting devices whose broadcast name information was not extracted, and then filters out the transmitting devices whose broadcast name information format does not match the expected format. For example, after scanning multiple broadcast data packets for broadcast name information and filtering them out, only the plaintext broadcast data in the format of broadcast name information = "device name" + "device model" + "_" + "last four digits of the Bluetooth address" is retained, i.e., broadcast data packets that meet the format such as "BRDMic_7113", "BRDMic_7113", "BRDSpeaker_7113", "AUDPlayer_EEFF", etc. are recorded as encrypted transmitting devices.

[0058] The receiving device goes through multiple screenings and, in an environment with multiple transmitting devices, filters out unencrypted broadcast data packets and broadcast data packets that do not meet the automatic decryption conditions, automatically and quickly and accurately finds the corresponding transmitting device for pairing and connection, thereby improving the matching efficiency between the transmitting device and the receiving device in an environment with multiple transmitting devices. Compared with the traditional solution that requires a mobile phone app to transfer the connection, there is no need to manually search and select in the transfer device, and the transmitting device is automatically screened out, which is simpler and faster and improves the matching efficiency.

[0059] For further information, please refer to Figure 3 In some embodiments, the step of “if the format matches the expected format, mark it as an encrypted transmitting device and save the record” may further include the following steps: (1) Select a transmitting device with the same device name and model as the receiving device as the connection target.

[0060] (2) If the device models are different, select the transmitting device with the same device name as the receiving device as the connection target.

[0061] The receiving device compares the format of the broadcast name information with the expected format. If the receiving device detects that the device name and device model included in the format of the broadcast name information are the same as the specified device name and device model, the corresponding transmitting device is used as the connection object.

[0062] Alternatively, if the receiving device detects that the device model included in the format of the broadcast name information is different from the specified device model, and the device name included in the format of the broadcast name information is the same as the specified device name, the corresponding transmitting device is used as the connection target.

[0063] That is to say, when filtering connection objects, the priority is the highest for the transmitters with the same device name and device model. If they are different, the transmitters with the same device name will be selected as the connection objects.

[0064] For example, if the broadcast name information in multiple broadcast data packets is scanned and filtered out, if the expected format specified by the receiving device is "BRDMic_7113", its device name is "BRD", and the device model is "Mic", the scanned broadcast name information are: "BRDMic_7113", "BRDSpeaker_7113", and "AUDPlayer_EEFF", then "BRDMic_7113" is selected as the connection object; if the scanned broadcast name information are: "BRDSpeaker_7113", "AUDPlayer_EEFF", and there is no device with the same name and device model, then "BRD" with the same device name is selected, that is, "BRDSpeaker_7113" is selected as the connection object.

[0065] The receiving device completes a round of screening among the multiple transmitting devices corresponding to the scanned multiple broadcast data packets based on whether the broadcast name information is extracted from the scanned broadcast data packet; then the receiving device compares the device name and device model contained in the broadcast name information in the broadcast data packet with the device name and device model specified by the receiving device to complete a second round of screening among the multiple transmitting devices corresponding to the scanned multiple broadcast data packets, so that among the multiple transmitting devices, the transmitting device that meets the corresponding conditions will be used as the connection object.

[0066] It is understandable that there may be at least two transmitting devices that meet the corresponding conditions. Based on this situation, in order to improve the connection efficiency between the receiving device and the corresponding transmitting device. Figure 3 In some implementations, the encrypted broadcast authentication interaction method may further include the following steps: (1) When there are multiple transmitting devices with the same device name and device model as the receiving device, if there is a designated encrypted transmitting device that was connected last time and is scanned in this scan, the transmitting device will be selected as the connection target.

[0067] (2) If there is no designated encrypted transmitter device that was connected last time, the transmitter device with the strongest broadcast signal strength is selected as the connection target.

[0068] That is to say, in an environment with multiple transmitting devices, the receiving device gives priority to selecting the transmitting device with the same device name and device model as those specified by the receiving device as the connection object, and its corresponding connection priority is the highest; secondly, if there are multiple transmitting devices with the same device name and device model as those specified by the receiving device, the designated encrypted transmitting device that was connected last time and is scanned in this scan will be selected as the connection object; thirdly, if there is no designated encrypted transmitting device that was connected last time, the transmitting device with the strongest broadcast signal strength will be selected as the connection object; finally, if there is no transmitting device with the same device name and device model as those specified by the receiving device, and there is a transmitting device with a device model different from the device model specified by the receiving device, the receiving device will select the transmitting device with the same device name as that specified by the receiving device as the connection object.

[0069] For example, if the broadcast name information in multiple broadcast data packets is scanned and filtered out, if the expected format specified by the receiving device is "BRDMic_7113", its device name is "BRD", and the device model is "Mic", the scanned broadcast name information are: "BRDMic_7113", "BRDMic_5566", and "BRDMic_EEFF". If the last connection was "BRDMic_7113", "BRDMic_7113" is selected as the connection object; if there is no last connection, the signal strengths of these transmitting devices are obtained, which are: -70dBm, -65dBm, and -60dBm respectively, then "BRDMic_EEFF" corresponding to the -60dBm signal strength with the strongest signal strength is selected as the connection object.

[0070] Also, please continue reading Figure 3 In some implementations, the encrypted broadcast authentication interaction method may further include the following steps: (1) When selecting the designated encrypted transmitter device that was last connected, if its signal strength is lower than the threshold, it will automatically switch to the next best device and select the transmitter device with the strongest broadcast signal strength as the connection target; (2) After the connection is successful, update the priority weight W of the transmitting device: W = α * signal strength + β * number of historical connections, where α = 0.7 and β = 0.3.

[0071] That is to say, if there are multiple transmitting devices with the same device name and device model as those specified by the receiving device, the designated encrypted transmitting device that was connected last time and is scanned in this scan will be used as the connection object. If there are multiple transmitting devices that meet the conditions, the transmitting device with the strongest signal strength will be used as the connection object; if there is one transmitting device that meets the conditions and its signal strength is lower than the threshold, the transmitting device with the strongest broadcast signal strength will be used as the connection object.

[0072] For example, if the scanned broadcast name information are: "BRDMic_7113", "BRDMic_5566", and "BRDMic_EEFF", if the last connection was to "BRDMic_7113", "BRDMic_7113" is selected as the connection object; the signal strengths of these transmitting devices are obtained, which are: -70dBm, -70dBm, and -60dBm, and it is determined whether they are lower than the threshold of -65dBm. At this time, since the signal strength of "BRDMic_7113" does not meet the standard, it is automatically filtered out, and the transmitting device with the highest signal strength is selected as the connection object (that is, "BRDMic_EEFF" corresponding to the signal strength of -60dBm is selected).

[0073] In some embodiments, when there are multiple transmitting devices with the same device name and device model as the receiving device, the transmitting device with the highest priority weight value is selected as the connection object. Alternatively, when there are multiple transmitting devices with different device models from the device model specified by the receiving device but the same device name as the receiving device, the transmitting device with the highest priority weight value is selected as the connection object. Alternatively, when there are multiple transmitting devices with the same device name and device model as the receiving device, and these transmitting devices are all designated encrypted transmitting devices that were previously connected and are scanned in this scan, the transmitting device with the highest priority weight value is selected as the connection object among these transmitting devices. Alternatively, if there is no designated encrypted transmitting device that was previously connected, and there are multiple transmitting devices with the strongest broadcast signal strength, the transmitting device with the highest priority weight value is selected as the connection object.

[0074] For example, transmitting device A: device name = "BRD", device model = "Speaker", signal strength = -70dBm, number of historical connections = 5; transmitting device B: device name = "BRD", device model = "Speaker", signal strength = -60dBm, number of historical connections = 3; transmitting device C: device name = "AUD", device model = "Mic", signal strength = -50dBm (the signal is the strongest but the names do not match); Step 1: Filter devices whose formats do not match (assuming all devices match). Step 2: Select A and B (excluding C) whose device names and models match. Step 3. Select the device that has been connected in the past (assuming A has been connected last time); Step 4: Since the signal strength of channel A (-70dBm) is lower than the threshold (-65dBm), it automatically switches to the stronger signal of channel B (-60dBm); Step 5. After the connection is successful, update the weight of B: W=0.7*(-60)+0.3*3 = -42 + 0.9 = -41.1. The higher the weight, the more optimal the conditions of the transmitting device, and the more times the user connects. It can be used as the connection object of the user's preferred habits. That is, the weight of the transmitting device will be calculated for each connection. When connecting next time, if the same conditions appear, the device with the highest weight will be selected for connection first, which is in line with the user's habits. Based on the priority strategy of broadcast name format filtering, signal strength, and historical connection weights, the optimal connection in seconds can be achieved in the scenario of multiple transmitting devices.

[0075] As can be seen, the receiving device determines that there is a transmitting device whose broadcast name information format matches the expected format among the broadcast data packets sent by multiple transmitting devices, marks it as an encrypted transmitting device, and selects the transmitting device as the connecting target among the encrypted transmitting devices. However, there may be cases where the broadcast name information format in the broadcast data packets sent by multiple transmitting devices does not match the expected format. Based on this situation, in some embodiments, the encrypted broadcast authentication interaction method may further include the following steps: (1) When the receiving device scans broadcast data packets sent by multiple transmitting devices, it identifies the broadcast name information format in the broadcast data packets; (2) If there is no transmitting device with the same device name as the receiving device, the unencrypted transmitting device with the strongest broadcast signal strength will be selected as the connection target.

[0076] From this, it can be seen that when the receiving device scans multiple transmitting devices and identifies the broadcast name information format and obtains a broadcast data packet to be decrypted, it will automatically connect to the unencrypted transmitting device as the connection object. In this way, it can connect to the broadcast even in an environment without a specified encrypted broadcast data packet, and be used as a basic broadcast receiving device, such as connecting to an open public broadcast source.

[0077] After the receiving device selects and determines the transmitting device as the connection target, it obtains the broadcast name information and digital code in the broadcast data packet of the transmitting device of the connection target; concatenates the character string of the broadcast name information and the 6-digit character string of the digital code to generate an input character string; calculates the MD5 digest of the input character string using a preset MD5 algorithm, converts the MD5 digest into a 32-digit hexadecimal character string, extracts the first 6 hexadecimal characters in the MD5 digest and converts them to uppercase as the expected authentication key. Further: In step 240, if the expected authentication key matches the authentication key, the receiving device establishes a Bluetooth connection with the transmitting device, and the receiving device decrypts the encrypted broadcast information.

[0078] If the expected authentication key matches the authentication key, the receiving device establishes a Bluetooth connection with the transmitting device as the connection object, and the receiving device can decrypt the encrypted broadcast information in the broadcast data packet sent by the transmitting device as the connection object based on the expected authentication key.

[0079] The receiving device of this solution autonomously generates the expected authentication key through a preset algorithm, without relying on external devices such as mobile phone apps for transfer. The pairing delay is greatly reduced compared to traditional solutions, and efficiency is improved. Based on the priority strategy of broadcast name format filtering, signal strength, and historical connection weight, the optimal connection in seconds is achieved in multi-transmitting device scenarios. The input is generated by splicing the device name, model, and the last four digits of the Bluetooth address and the digital code. The first 6 hexadecimal digits are extracted as the key through MD5 calculation. The repetition rate is extremely low, which effectively resists counterfeit attacks. Only the broadcast name and digital code (plain text) are disclosed in the broadcast data packet, and sensitive data is encrypted and transmitted with the authentication key to prevent theft by middlemen. The broadcast protocol is implemented based on the existing Bluetooth broadcast authentication system, and no new dedicated chips or interfaces are required.

[0080] See also Figure 4 , Figure 4 A schematic diagram of the structure of a computer-readable storage medium provided in an embodiment of the present application is shown. The computer-readable storage medium 300 stores program code, which can be called by a processor to execute the encrypted broadcast authentication interaction method described in the above method embodiment.

[0081] Computer-readable storage medium 300 may be an electronic memory such as flash memory, EEPROM (Electrically Erasable Programmable Read-Only Memory), EPROM, a hard disk, or ROM. Alternatively, computer-readable storage medium 300 may include non-transitory computer-readable storage medium. Computer-readable storage medium 300 has storage space for program code 310 for executing any of the method steps described above. This program code can be read from or written to one or more computer program devices. Program code 310 may be compressed, for example, in a suitable format.

[0082] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present application.

Claims

1. An encrypted broadcast authentication interaction method, applied to a Bluetooth broadcast authentication system, wherein the Bluetooth broadcast authentication system includes a transmitting device and a receiving device, characterized in that: The method comprises: The transmitting device generates broadcast name information and a digital code, calculates an authentication key using a preset algorithm, and encrypts the data to be encrypted according to the authentication key to obtain encrypted broadcast information; The transmitting device transmits a broadcast data packet including the broadcast name information, the digital code and the encrypted broadcast information; The receiving device scans the broadcast data packet and obtains the expected authentication key through calculation using the preset algorithm; If the expected authentication key matches the authentication key, the receiving device establishes a Bluetooth connection with the transmitting device, and the receiving device decrypts the encrypted broadcast information.

2. The encrypted broadcast authentication interaction method according to claim 1, wherein: The broadcast name information is a string of characters formed by combining the device name, device model and the last four digits of the Bluetooth address of the transmitting device; Among them, the Bluetooth address and the device name or the device model are separated by an underscore character; all characters are encoded in ASCII. If the character length of the generated string of the broadcast name information is an odd number, the last bit of the string of the broadcast name information is padded with space characters to an even number.

3. The authentication interaction method for encrypted broadcasting according to claim 2, wherein: The digital code is a 4-byte integer, expressed as a 6-digit string, wherein the value range of the digital code string is 000001~999999; The receiving device scans the broadcast data packet and obtains the expected authentication key by calculating through the preset algorithm, including: Concatenate the broadcast name information character string and the digitally encoded 6-digit character string to generate an input character string; An MD5 digest is calculated based on the input character string using a preset MD5 algorithm, the MD5 digest is converted into a 32-digit hexadecimal character string, and the first 6 hexadecimal characters in the MD5 digest are extracted and converted into uppercase form as the authentication key.

4. The encrypted broadcast authentication interaction method according to claim 3, wherein: The method further comprises: When the receiving device scans a plurality of broadcast data packets sent by the transmitting devices, the receiving device identifies the broadcast name information format in the broadcast data packets respectively; If it matches the expected format, mark it as an encrypted transmitting device and save the record; If the format does not match the expected format, the transmitting device is filtered.

5. The authentication interaction method for encrypted broadcasting according to claim 4, wherein: If the format matches the expected format, it is marked as an encrypted transmitting device and the record is saved, including: Select a transmitting device with the same device name and device model as the receiving device as the connection object; If the device models are different, the transmitting device with the same device name as that specified by the receiving device is selected as the connection object.

6. The encrypted broadcast authentication interaction method according to claim 5, wherein: The method further comprises: When there are multiple transmitting devices with the same device name and device model as the receiving device, if there is a designated encrypted transmitting device that was previously connected and is scanned in this scan, the transmitting device is selected as the connection target; If there is no designated encrypted transmitter device that was connected last time, the transmitter device with the strongest broadcast signal strength will be selected as the connection target.

7. The authentication interaction method for encrypted broadcasting according to claim 6, wherein: The method further comprises: When selecting the designated encrypted transmitter device that was connected last time, if its signal strength is lower than the threshold, it will automatically switch to the next best device and select the transmitter device with the strongest broadcast signal strength as the connection target; After the connection is successful, update the priority weight W of the transmitting device: W = α * signal strength + β * number of historical connections, where α = 0.7 and β = 0.

3.

8. The encrypted broadcast authentication interaction method according to any one of claims 5 to 7, characterized in that: The method comprises: Obtain the broadcast name information and digital code in the broadcast data packet of the transmitting device of the connected object; Concatenate the broadcast name information string and the 6-digit digitally encoded string to generate an input string; An MD5 digest is calculated based on the input character string using a preset MD5 algorithm, the MD5 digest is converted into a 32-digit hexadecimal character string, and the first 6 hexadecimal characters in the MD5 digest are extracted and converted into uppercase as the expected authentication key.

9. The authentication interaction method for encrypted broadcasting according to claim 2, wherein: The method further comprises: When the receiving device scans a plurality of broadcast data packets sent by the transmitting devices, identifying the format of the broadcast name information in the broadcast data packets; If there is no transmitting device with the same device name as the receiving device, the unencrypted transmitting device with the strongest broadcast signal strength is selected as the connection object.

10. A Bluetooth broadcast authentication system, characterized in that: It includes transmitting equipment and receiving equipment, including: The transmitting device is used to generate broadcast name information and digital code, calculate an authentication key through a preset algorithm, and encrypt the data to be encrypted according to the authentication key to obtain encrypted broadcast information; The transmitting device is used to transmit a broadcast data packet containing the broadcast name information, the digital code and the encrypted broadcast information; The receiving device is used to scan the broadcast data packet and obtain the expected authentication key through calculation using the preset algorithm; The receiving device is configured to establish a Bluetooth connection with the transmitting device if the expected authentication key matches the authentication key, and the receiving device decrypts the encrypted broadcast information.

Citation Information

Patent Citations

  • Safe connection method between low-power-consumption Bluetooth devices and data transmission method

    CN111343634A

  • Secure beacons

    CN113302961A

  • Bluetooth connection method of portable medical equipment and computer equipment

    CN116961934A

  • Digital Broadcasting Terminal With AuthenticatingDigital Broadcasting, System For Authenticating DigitalBroadcasting And Its Method

    KR1020070054352A

  • Method and apparatus for protecting contents supporting broadcast service between service provider and a plurality of mobile stations

    US20070189535A1