Secure communication method and apparatus
By sending and receiving information between the terminal device and the P-CSCF, and determining the salt value and initialization vectors using specific calculation methods, the problem of difficult to ensure uplink and downlink communication security in IMS is solved, and the communication security performance is improved.
Patent Information
- Application Number
- PCT/CN2024/091411
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2023-05-15
- Filing Date
- 2024-05-07
- Publication Date
- 2024-11-21
AI Technical Summary
In the Internet Protocol (IP) multimedia subsystem (IMS), the uplink and downlink communication security between the terminal device and the proxy call session control function (P-CSCF) is difficult to ensure, resulting in low communication security performance.
Send and receive information between the terminal device and the P-CSCF, including port number, security parameter index (SPI), Internet protocol (IP) address and security algorithm list, and use specific calculation methods to determine the salt value and initialization vector to ensure that The salt values of uplink and downlink transmissions are different, thereby improving communication security.
It effectively ensures the security of uplink and downlink communication between the terminal device and P-CSCF, avoids the problem of encryption and decryption failure, and improves communication performance.
Smart Images

Figure CN2024091411_21112024_PF_FP_ABST
Abstract
Description
Secure communication method and device
[0001] This application claims priority to the Chinese patent application filed with the State Intellectual Property Office of China on May 15, 2023, with application number 202310544449.3 and invention name “Secure Communication Method and Device”, the entire contents of which are incorporated by reference into this application. Technical Field
[0002] The present application relates to the field of wireless communications, and more particularly, to a secure communication method and apparatus. Background Art
[0003] The security of mobile communications is receiving increasing attention. In the Internet Protocol (IP) Multimedia Subsystem (IMS), security is based on a long-term security key. After the terminal device and the network device complete authentication, the terminal device and the first interaction point (e.g., the proxy call session control function (P-CSCF)) will obtain a shared key. Furthermore, an Internet Protocol Security (IPSEC) channel can be established between the terminal device and the P-CSCF based on the shared key. The IPSEC channel is used for uplink / downlink communication between the terminal device and the P-CSCF, wherein the key, salt value, and initialization vector (IV) used for uplink / downlink communication between the terminal device and the P-CSCF may be the same.
[0004] How to ensure the security of uplink and downlink communications between terminal devices and P-CSCF is a problem that needs to be solved currently.
[0005] Summary of the Invention
[0006] The present application provides a secure communication method and apparatus, which can ensure the security of uplink and downlink communications between a terminal device and a P-CSCF.
[0007] In a first aspect, a secure communication method is provided. This method can be executed by a terminal device, or by a chip or circuit configured in the terminal device; alternatively, this method can be executed by a network device, or by a chip or circuit configured in the network device, and this application does not limit this.
[0008] The method may include:
[0009] The first device sends first information of the first device to the second device via a first message, where the first message includes one or more of a first port number, a first security parameter index SPI, a first Internet Protocol IP address, a first security algorithm list, and a first random number; the first device receives a second message from the second device including second information, where the second message includes one or more of a second port number, a second security parameter index SPI, a second Internet Protocol IP address, a second security algorithm list, and a second random number; the first device determines, based on the first information and / or the second information, a first salt value for uplink transmission between the first device and the second device using a first calculation method, and / or determines, based on the second information and / or the first information, a second salt value for downlink transmission between the first device and the second device using a second calculation method.
[0010] According to the method provided in the present application, for uplink transmission between a first device and a second device, the first device can use a first calculation method to determine a first salt value based on the first information of the first device and the second information from the second device; accordingly, the second device uses a first calculation method to determine the first salt value based on the second information of the second device and the first information from the first device. It can be seen that in the uplink transmission between the first device and the second device, the first device and the second device can determine the same salt value through the same calculation method, that is, the uplink communication security between the first device and the second device can be guaranteed. For downlink transmission between the first device and the second device, the first device can use a second calculation method to determine the second salt value based on the first information of the first device and the second information from the second device; accordingly, the second device uses a second calculation method to determine the second salt value based on the second information of the second device and the first information from the first device. It can be seen that in the downlink transmission between the first device and the second device, the first device and the second device can use the same calculation method to determine the same salt value, that is, the downlink communication security between the first device and the second device can be guaranteed.
[0011] In combination with the first aspect, in some possible implementations, the first information is included in one of the first port number, the first security parameter index SPI, the first Internet Protocol IP address, the first security algorithm list, and the first random number of the first message; and / or the second information is included in one of the second port number, the second security parameter index SPI, the second Internet Protocol IP address, the second security algorithm list, and the second random number of the second message.
[0012] Based on the above technical solution, a first device sends a first message to a second device, where the first message includes one or more of a first port number, a first security parameter index SPI, a first Internet Protocol IP address, a first security algorithm list, and a first random number. The first information included in the first message can carry any one of the first port number, the first security parameter index SPI, the first Internet Protocol IP address, the first security algorithm list, and the first random number in the first message. The first device receives a second message sent from the second device, where the second message includes one or more of a second port number, a second security parameter index SPI, the second Internet Protocol IP address, the second security algorithm list, and the second random number. The second information included in the second message can carry any one of the second port number, the second security parameter index SPI, the second Internet Protocol IP address, the second security algorithm list, and the second random number in the second message.
[0013] In one possible implementation, when the first information is carried in any one of the first port number, the first security parameter index SPI, the first Internet Protocol IP address, the first security algorithm list, and the first random number, the first information can be represented in the form of bits.
[0014] In another possible implementation, when the first information is carried in any one of the first security algorithm list and the first port number, the first information may also be represented by an entry in the list, such as by adding an algorithm identifier.
[0015] In conjunction with the first aspect, in some possible implementations, determining the first salt value using the first calculation method includes:
[0016] Calculate a first salt value using the first security parameter,
[0017] The first security parameter includes one or more of the following: an uplink transmission direction identifier, an uplink transmission direction identifier, an uplink port number of the first device and / or the second device, an uplink IP address of the first device and / or the second device, an uplink SPI of the first device and / or the second device, an uplink counter of the first device and / or the second device, and a random number of the first device and / or the second device;
[0018] Determining the second salt value using the second calculation method includes: calculating the second salt value using the second safety parameter,
[0019] Among them, the second security parameter includes one or more of the following: a direction identifier of downlink transmission, a direction identifier of downlink transmission, a downlink port number of the first device and / or the second device, a downlink IP address of the first device and / or the second device, a downlink SPI of the first device and / or the second device, a downlink counter of the first device and / or the second device, and a random number of the first device and / or the second device.
[0020] It should be understood that the uplink SPI and port number of the first device, the downlink SPI and port number of the first device can all be generated locally by the first device, and the uplink SPI and port number of the second device, the downlink SPI and port number of the second device can all be generated locally by the second device.
[0021] In one possible implementation, the uplink port number of the first device, the uplink IP address of the first device, the uplink SPI of the first device, the uplink counter of the first device, and the random number of the first device can be sent to the second device via a first message, so that the second device uses the first security parameter to calculate the first salt value; the uplink port number of the second device, the uplink IP address of the second device, the uplink SPI of the second device, the uplink counter of the second device, and the random number of the second device can be sent to the first device via a second message, so that the first device uses the first security parameter to calculate the first salt value.
[0022] In another implementation method, the uplink port number of the first device, the downlink IP address of the first device, the downlink SPI of the first device, the downlink counter of the first device, and the random number of the first device can be sent to the second device via a first message, so that the second device uses the second security parameter to calculate the second salt value; the downlink port number of the second device, the downlink IP address of the second device, the downlink SPI of the second device, the downlink counter of the second device, and the random number of the second device can be sent to the first device via a second message, so that the first device uses the second security parameter to calculate the second salt value.
[0023] With reference to the first aspect, in some possible implementations, the first device uses a first security parameter to determine a first vector for uplink transmission, and / or uses a second security parameter to determine a second vector for downlink transmission;
[0024] The first device sends the first vector and / or the second vector to the second device.
[0025] Based on the above technical solution, the first device uses relevant parameters for distinguishing uplink and downlink transmissions (e.g., port number, direction indicator, direction identifier, IP address, SPI, counter, random number) to determine a first vector and / or a second vector, and sends the first vector and / or the second vector to the second device. The first vector is different from the second vector, which can further ensure that the first vector and the second vector used in the uplink and downlink between the first device and the second device are different, thereby ensuring the security of uplink and downlink communications between the first device and the second device.
[0026] In a second aspect, a secure communication method is provided. This method can be executed by a terminal device, or by a chip or circuit configured in the terminal device; or by a network device, or by a chip or circuit configured in the network device, which is not limited in this application.
[0027] The method includes:
[0028] The first device determines a first vector for uplink transmission between the first device and the second device using the first security parameter, and / or determines a second vector for downlink transmission between the first device and the second device using the second security parameter;
[0029] Among them, the first security parameter includes one or more of the following: an uplink transmission direction identifier, an uplink transmission direction identifier, an uplink port number of the first device and / or the second device, an uplink IP address of the first device and / or the second device, an uplink SPI of the first device and / or the second device, an uplink counter of the first device and / or the second device, and a random number of the first device and / or the second device; the second security parameter includes one or more of the following: a downlink transmission direction identifier, a downlink transmission direction identifier, a downlink port number of the first device and / or the second device, a downlink IP address of the first device and / or the second device, a downlink SPI of the first device and / or the second device, a downlink counter of the first device and / or the second device, and a random number of the first device and / or the second device;
[0030] The first device sends the first vector and / or the second vector to the second device.
[0031] Based on the above technical solution, the first device uses relevant parameters that distinguish uplink and downlink transmissions (e.g., port number, direction indicator, direction identifier, IP address, SPI, counter, random number) to determine a first vector and / or a second vector, and sends the first vector and / or the second vector to the second device. The first vector is determined based on a first security parameter related to uplink transmission, and the second vector is determined based on a second security parameter related to downlink transmission. That is, the first vector and the second vector used by the first device and the second device for uplink and downlink transmissions are different, thereby ensuring the security of uplink and downlink communications between the first device and the second device.
[0032] In a third aspect, a secure communication device is provided, the device being configured to execute the method provided in the first and / or second aspects above. Specifically, the device may include units and / or modules, such as a processing unit and / or a transceiver unit (or communication unit), for executing the method provided in any one of the implementations of the first and second aspects.
[0033] In one implementation, the apparatus is a communication device (e.g., a terminal device or a network device). When the apparatus is a communication device, the communication unit may be a transceiver or a transceiver unit, or an input / output interface; the processing unit may be at least one processor. Alternatively, the transceiver may be a transceiver circuit. Alternatively, the input / output interface may be an input / output circuit.
[0034] In another implementation, the device is a chip, chip system, or circuit used in a communication device (such as a terminal device or a network device). When the device is a chip, chip system, or circuit used in a communication device, the communication unit may be an input / output interface, interface circuit, output circuit, input circuit, pin, or related circuit on the chip, chip system, or circuit; and the processing unit may be at least one processor, processing circuit, or logic circuit.
[0035] In a fourth aspect, a communication device is provided, which includes: a memory for storing computer programs or instructions; and at least one processor for executing the computer programs or instructions stored in the memory to execute the method provided in any one of the implementation modes of the first and second aspects above.
[0036] In one implementation, the apparatus is a communication device (such as a terminal device or a network device).
[0037] In another implementation, the device is a chip, a chip system, or a circuit used in a communication device (such as a terminal device or a network device).
[0038] In a fifth aspect, the present application provides a processor for executing the methods provided in the above aspects.
[0039] For the operations such as sending and acquiring / receiving involved in the processor, unless otherwise specified, or if they do not conflict with their actual functions or internal logic in the relevant descriptions, they can be understood as operations such as processor output and input, or as sending and receiving operations performed by the radio frequency circuit and antenna. This application does not limit this.
[0040] In a sixth aspect, a computer-readable storage medium is provided, which stores a program code for execution by a device, and the program code includes a method for executing any one of the above-mentioned implementation methods in the first aspect and the second aspect.
[0041] In a seventh aspect, a computer program product comprising instructions is provided, which, when run on a computer, enables the computer to execute the method provided in any one of the implementations of the first and second aspects above.
[0042] In an eighth aspect, a chip is provided, which includes a processor and a communication interface. The processor reads instructions stored in a memory through the communication interface and executes the method provided by any one of the implementation methods in the first and second aspects above.
[0043] Optionally, as an implementation method, the chip also includes a memory, in which a computer program or instruction is stored, and the processor is used to execute the computer program or instruction stored in the memory. When the computer program or instruction is executed, the processor is used to execute the method provided in any one of the implementation methods of the first aspect or the second aspect above. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] FIG1 is a schematic diagram of a network architecture applicable to the method provided in an embodiment of the present application.
[0045] FIG2 is a schematic flowchart of a secure communication method provided according to an embodiment of the present application.
[0046] FIG3 is a schematic flowchart of a secure communication method provided in another embodiment of the present application.
[0047] FIG4 is a schematic diagram of a secure communication device 400 provided in an embodiment of the present application.
[0048] FIG5 is a schematic diagram of a secure communication device 500 provided in accordance with another embodiment of the present application.
[0049] FIG6 is a schematic diagram of a chip system 600 provided in an embodiment of the present application. DETAILED DESCRIPTION
[0050] The technical solution in this application will be described below with reference to the accompanying drawings.
[0051] The technical solutions of the embodiments of the present application can be applied to various communication systems, such as: Global System of Mobile communication (GSM) system, Code Division Multiple Access (CDMA) system, Wideband Code Division Multiple Access (WCDMA) system, General Packet Radio Service (GPRS), Long Term Evolution (LTE) system, LTE Frequency Division Duplex (FDD) system, LTE Time Division Duplex (TDD), Universal Mobile Telecommunication System (UMTS), Worldwide Interoperability for Microwave Access (WiMAX) communication system, fifth generation (5G) system, new radio (NR), sixth generation (6G) system or future communication systems, etc.
[0052] It should be understood that the embodiments of the present application do not specifically limit the specific structure of the execution subject of the method provided by the embodiments of the present application. As long as it is possible to communicate according to the method provided by the embodiments of the present application by running a program that records the code of the method provided by the embodiments of the present application, for example, the execution subject of the method provided by the embodiments of the present application can be a terminal side or network side device, or a functional module in the terminal side or network side device that can call and execute the program.
[0053] To facilitate understanding of the embodiment of the present application, an application scenario of the embodiment of the present application is first described in detail with reference to FIG1 .
[0054] Figure 1 is a schematic diagram of a network architecture applicable to the method provided in an embodiment of the present application. As shown in Figure 1, the network architecture may specifically include the following network elements:
[0055] 1. User equipment (UE): can be referred to as user equipment, terminal, access terminal, subscriber unit, subscriber station, mobile station, mobile station, remote station, remote terminal, mobile device, user terminal, wireless communication device, user agent, or user device. The terminal equipment may also be a cellular phone, a cordless phone, a Session Initiation Protocol (SIP) phone, a Wireless Local Loop (WLL) station, a Personal Digital Assistant (PDA), a handheld device with wireless communication capabilities, a computing device or other processing device connected to a wireless modem, an in-vehicle device, a wearable device, a terminal device in a future 5G network, or a terminal device in a future evolved Public Land Mobile Network (PLMN), etc., and the embodiments of the present application are not limited thereto.
[0056] 2. Proxy call session control function (P-CSCF): This is the unified initial entry point of the control plane of the visited domain of the IMS domain. It mainly proxies Session Initiation Protocol (SIP) messages from the visited access network to the serving call session control function (S-CSCF) or interrogating call session control function (I-CSCF) of the home access network.
[0057] The P-CSCF is also used to provide integrity and security for SIP information between the IMS and terminal devices.
[0058] 3. Inter-Call Session Control Function (I-CSCF): When a user is roaming, the I-CSCF serves as the access point for the terminal device to access the home network.
[0059] The I-CSCF interacts with the Home Subscriber Server (HSS) to obtain the address of the S-CSCF to which the user belongs. The I-CSCF can forward SIP requests and responses to the S-CSCF.
[0060] 4. Serving Call Session Control Function (S-CSCF): The S-CSCF plays a central role in session control within the entire IMS core network. It receives registration requests from IMS users in the visited network, forwarded via the P-CSCF. It works with the HSS to authenticate IMS terminals, downloads basic IMS subscription data from the HSS, and performs basic session routing for both the calling and called IMS terminals.
[0061] 5. Home Subscriber Server (HSS): The HSS is a centralized database that stores IMS user subscription information within the home network. This information includes identification, routing, and service subscription information. The HSS is located at the top layer of the IMS core network architecture.
[0062] The main information stored in the HSS includes: IMS user identity (including public and private identity), number and address information; IMS user security context: key information for user network access authentication; IMS user routing information: HSS supports user registration and stores user location information; IMS user service subscription information: including value-added service data of other application servers (AS).
[0063] 6. Application Server (AS): Provides IMS services such as SMS, ringback tone, color printing, etc. AS receives and processes SIP requests from IMS.
[0064] It should be understood that IMS is based on the concepts of a home network and a visited network. Generally, there are two scenarios depending on whether the IMS user is roaming. One scenario: the first interaction point (such as P-CSCF) for the terminal device to access the IMS is located in the home network; the other scenario: the P-CSCF is located in the visited network, which means that the terminal device is roaming in a way that the first interaction point for accessing the IMS is not in the home network. The method provided in this application can be used in any of the above two scenarios, and this application does not make specific limitations on this.
[0065] It should also be understood that the detailed process of authentication between a terminal device and a network device can be found in the prior art and will not be repeated here. After the terminal device and the network device complete authentication, the terminal device and the P-CSCF obtain a shared key, which includes an integrity key (IK) and a confidentiality key (CK). The terminal device and the P-CSCF establish an IP Security (IPSEC) channel based on the IK and CK.
[0066] The IPSEC channel can include uplink transmissions between a terminal device and a P-CSCF, as well as downlink transmissions between the terminal device and the P-CSCF. This means the IPSEC channel is bidirectional, encompassing both uplink and downlink directions. During uplink and / or downlink transmissions between a terminal device and the P-CSCF, the terminal device and the P-CSCF each need to determine a salt value specific to the uplink and / or downlink transmissions. This salt value is used to encrypt or decrypt the uplink and / or downlink information. Ensuring that the salt values determined by the terminal device and the P-CSCF are identical during uplink transmissions and that the salt values determined by the terminal device and the P-CSCF are identical during downlink transmissions is a hot topic in this field.
[0067] In order to facilitate understanding of the technical solutions provided in the embodiments of this application, the following is a brief introduction to the professional terms involved in this application:
[0068] 1. A salt value can be a random field or a value generated by an algorithm. Salts are primarily used to protect the passwords of transmitted information. By adding salt to passwords (mixing random characters into the plaintext password), the system's complexity can be increased, resulting in a stronger and more secure ciphertext digest value.
[0069] 2. The initialization vector (IV), which can be an initial variable or initial vector, is an input value of fixed length. Each encryption requires a randomly generated bit sequence as the IV; static IVs are generally not used. The IV value varies depending on the cryptographic algorithm, but uniqueness is a fundamental requirement: the same IV should not be reused for the same key. The use of the same IV in both directions of the IPSEC channel may be due to IPSEC not providing a mechanism for IV coordination, resulting in the terminal device and the P-CSCF generating identical IVs.
[0070] Currently, IPSEC channels use the same encryption keys (i.e., IK and CK), salt values, and initialization vectors (IVs) for both upstream and downstream transmissions. If the same text is transmitted in both upstream and downstream directions within an IPSEC channel, it will use the same encryption key, salt value, and initialization vector (IV). This means that the same encrypted text will be generated for both upstream and downstream transmissions, resulting in lower communication security.
[0071] Since the parameters used to generate the salt value are identical between the terminal device and the P-CSCF, the salt values for uplink and downlink transmissions in the IPSEC channel are identical. That is, the terminal device and the P-CSCF determine the salt values for uplink and downlink transmissions, respectively, to be identical. For example, for uplink transmission between the terminal device and the P-CSCF, the terminal device determines the salt value for uplink transmission to be Salt #1, and the P-CSCF determines the salt value for uplink transmission to be Salt #1'. For downlink transmission between the terminal device and the P-CSCF, the terminal device determines the salt value for downlink transmission to be Salt #2, and the P-CSCF determines the salt value for downlink transmission to be Salt #2'. Salt #1, Salt #1', Salt #2, and Salt #2' are identical.
[0072] Considering the communication security of IPSEC channel transmission, when the same keys (IK and CK) are used for uplink and downlink transmission in the IPSEC channel, it is necessary to ensure that the salt value transmitted uplink by the terminal device and the P-CSCF is different from the salt value transmitted downlink by the terminal device and the P-CSCF. To ensure that the salt value transmitted uplink by the terminal device and the P-CSCF is different from the salt value transmitted downlink by the terminal device and the P-CSCF, the security parameter index (SPI) in the security association (SA) can be added to the salt value derivation parameters of the terminal device and the P-CSCF. The SA is a unidirectional and unique SA, and the SPI is the unique identification ID of the SA. That is, the SPI corresponding to the uplink and downlink transmissions are different, thereby ensuring that the salt values used for uplink and downlink transmissions are different.
[0073] Among them, it is defined that the salt values corresponding to uplink transmission and downlink transmission are different. For example, for uplink transmission between a terminal device and a P-CSCF, the terminal device determines the salt value for uplink transmission to be salt value #1, and the P-CSCF determines the salt value for uplink transmission to be salt value #1'; for downlink transmission between a terminal device and a P-CSCF, the terminal device determines the salt value for downlink transmission to be salt value #2, and the P-CSCF determines the salt value for downlink transmission to be salt value #2'. The salt values used for uplink transmission (salt value #1 and salt value #1') are different from the salt values used for downlink transmission (salt value #2 and salt value #2'), and it does not consider whether the salt values #1 and #1' used for uplink transmission are the same, or whether the salt values #2 and #2' used for downlink transmission are the same.
[0074] The terminal device and the P-CSCF cannot guarantee that the salt values determined by the terminal device and the P-CSCF are the same during uplink transmission, or that the salt values determined by the terminal device and the P-CSCF are the same during downlink transmission. If the uplink / downlink salt values determined by the terminal device and the P-CSCF differ during uplink or downlink transmission, encryption and decryption of the transmitted information by the terminal device and the P-CSCF will fail, thereby affecting communication performance.
[0075] In response to the above-mentioned technical problems, the uplink and downlink transmission between the terminal device and the P-CSCF, how to ensure that the terminal device and the P-CSCF determine the same salt value in the uplink transmission, and the terminal device and the P-CSCF determine the same salt value in the downlink transmission is the technical problem solved by this application.
[0076] The present application provides a secure communication method that can ensure the security of uplink and downlink communications between communication devices. For example, in an uplink transmission between a first device and a second device, the salt value determined by the uplink transmission of the first device is the same as the salt value determined by the uplink transmission of the second device, thereby improving the communication security between the first device and the second device.
[0077] FIG2 is a flow chart of a secure communication method provided in an embodiment of the present application.
[0078] 210. The first device sends first information of the first device to the second device through a first message.
[0079] Correspondingly, the second device receives the first information of the first device sent by the first device through the first message.
[0080] The first information includes a salt value calculation method supported by the first device. The salt value calculation method supported by the first device can be understood as the salt value calculation capability supported by the first device, or can be understood as the algorithm supported by the first device. Both the salt value calculation method supported by the first device and the salt value calculation capability supported by the first device can be used to determine the method by which the first device calculates the salt value. The embodiments of this application are mainly described in terms of the salt value calculation method supported by the first device, but other descriptions can also be used instead, and this application does not specifically limit this.
[0081] It should be understood that the first message includes one or more of a first port number, a first security parameter index SPI, a first Internet Protocol IP address, a first security algorithm list, and a first random number.
[0082] In one possible implementation, the first device sends the first information to the second device through a first message. The first device may send the first information to the second device through a separate indication, and the first information does not need to be carried in any other signaling or algorithm list.
[0083] In another possible implementation, the first information is carried in any one of the first port number, the first security parameter index (SPI), the first Internet Protocol (IP) address, the first security algorithm list, and the first random number included in the first message, and is sent to the second device via the first message. For example, the first message includes the first port number and the first Internet Protocol (IP) address. The first port number may carry the first information, or the first IP address may carry the first information.
[0084] The first information may be represented in the form of bits.
[0085] As an example, when the first information is carried in any one of the first port number, the first security parameter index SPI, the first Internet Protocol IP address, the first security algorithm list, and the first random number in the first message, it is assumed that the first information includes a first bit, which is contained in the first port number, and the first bit is used to indicate the salt value calculation method supported by the first device.
[0086] For example, assuming that the length of the first bit is 1 bit, when the first bit is 0, it indicates that the first device supports method #1 for calculating the salt value; when the first bit is 1, it indicates that the first device supports method #2 for calculating the salt value.
[0087] It should be understood that in the future, the first device may support two or more salt value calculation methods, and the first information may represent the salt value calculation methods supported by the first device in the form of bits.
[0088] The first information may be represented in the form of an information element (IE).
[0089] As an example, when the first information is carried in the first security algorithm list in the first message, the first information may indicate the salt value calculation method supported by the first device in the form of an information element.
[0090] For example, the first information is an algorithm identifier or indication in the algorithm, and / or the first information is an algorithm identifier or indication of the encryption algorithm.
[0091] 220. The first device receives a second message containing second information from the second device.
[0092] Accordingly, the second device sends a second message including second information to the first device.
[0093] The second information includes a salt value calculation method supported by the second device. The salt value calculation method supported by the second device can be understood as the salt value calculation capability supported by the second device, or can be understood as an algorithm supported by the second device. Both the salt value calculation method supported by the second device and the salt value calculation capability supported by the second device can be used to determine the method by which the second device calculates the salt value. In the embodiments of this application, the description is mainly based on the salt value calculation method supported by the second device, but other descriptions can also be used instead, and this application does not specifically limit this.
[0094] It should be understood that the second message includes one or more items of a second port number, a second security parameter index SPI, a second Internet Protocol IP address, a second security algorithm list, and a second random number.
[0095] In one possible implementation, the second device sends the second information to the first device through a second message. The second information may be sent by the second device to the first device through a separate indication, and the second information does not need to be carried in any other signaling or algorithm list.
[0096] In another possible implementation, the second information is carried in any one of the second port number, the second security parameter index (SPI), the second Internet Protocol (IP) address, the second security algorithm list, and the second random number included in the second message, and is sent to the first device via the second message. For example, the second message includes the second port number and the second Internet Protocol (IP) address. The second port number may carry the second information, or the second IP address may carry the second information.
[0097] It should be understood that the second information may represent a salt value calculation method supported by the second device. Specifically, the second information may be represented in the form of bits or in the form of cells, which is not specifically limited in this application.
[0098] It should also be understood that the transmission method of the second information in step 220 and the specific form of expression of the second information are similar to the transmission method of the first information in step 210 and the specific form of expression of the first information. For details, please refer to the detailed examples in step 210 and will not be repeated here.
[0099] It should be noted that this application does not limit the order of steps between step 210 and step 220. Step 210 may occur before step 220, step 220 may occur before step 210, or step 210 and step 220 may occur at the same time. This application does not make specific limitations.
[0100] It should also be noted that when there is an obvious logical order between step 210 and step 220, step 210 may precede step 220. As described below:
[0101] As a possible implementation method, after the second device receives the first message including the first information sent from the first device, the second device determines that the second device supports the calculation method of the salt value of the first device. Only then will the second device execute step 220, that is, the second device sends a second message including the second information to the first device.
[0102] When the second device determines that the second device supports the calculation method of the salt value of the first device, the second device calculates the first salt value according to the calculation method of the salt value of the first device supported by the second device.
[0103] Step 230: Determine a first salt value using a first calculation method and / or determine a second salt value using a second calculation method based on the first information and / or the second information.
[0104] In which, the first device and the second device can use the first information and the second information to determine a first salt value for uplink transmission between the first device and the second device using a first calculation method, and / or use a second calculation method to determine a second salt value for downlink transmission between the first device and the second device.
[0105] In one possible implementation, after receiving the second information, the first device determines a first calculation method based on the salt value calculation method supported by the second device and the salt value calculation method supported by the first device, as included in the second information. The first device determines a first salt value for uplink transmission between the first device and the second device using the first calculation method.
[0106] Similarly, after receiving the first information, the second device determines a first calculation method based on the salt value calculation methods supported by the first device and the salt value calculation methods supported by the second device, as included in the first information. The second device determines the first salt value for uplink transmission between the first device and the second device using the first calculation method.
[0107] In another possible implementation, after receiving the second information, the first device determines a second calculation method based on the salt value calculation method supported by the second device and the salt value calculation method supported by the first device itself, as included in the second information. The first device determines the second salt value for downlink transmission between the first device and the second device using the second calculation method.
[0108] Similarly, after receiving the first information, the second device determines a second calculation method based on the salt value calculation methods supported by the first device and the salt value calculation methods supported by the second device, as included in the first information. The second device uses the second calculation method to determine the second salt value for downlink transmission between the first device and the second device.
[0109] The first device may determine the first salt value using a first calculation method according to the second information, and / or determine the second salt value using a second calculation method.
[0110] In one possible implementation, after receiving the second information, the first device may determine that the second device supports a salt value calculation method supported by the first device. The first device may determine the first calculation method and / or the second calculation method based on the second information. The first device may determine a first salt value for uplink transmission between the first device and the second device using the first calculation method; and / or determine a second salt value for downlink transmission between the first device and the second device using the second calculation method.
[0111] As an example, assume that the first device is a terminal device and the second device is a P-CSCF. After the terminal device receives the second information from the P-CSCF, the terminal device determines that the P-CSCF has received the first information from the terminal device and that the P-CSCF supports the salt value calculation method supported by the terminal device in the first information. The terminal device can determine the first calculation method and / or the second calculation method based on the second information from the P-CSCF, and determine the first salt value using the first calculation method and / or the second salt value using the second calculation method.
[0112] The first device may determine the first salt value using a first calculation method according to the first information, and / or determine the second salt value using a second calculation method.
[0113] In one possible implementation, after a first device receives the second information from a second device, the first device determines, based on the second information, that it supports a salt value calculation method supported by the second device. The first device may determine a first calculation method and / or a second calculation method based on the first information. The first device may determine, using the first calculation method, a first salt value for uplink transmission between the first device and the second device; and / or determine, using the second calculation method, a second salt value for downlink transmission between the first device and the second device.
[0114] As an example, assume that the first device is a P-CSCF and the second device is a terminal device. After the P-CSCF receives the second information from the terminal device, the P-CSCF determines the salt value calculation method supported by the terminal device based on the salt value calculation method supported by the terminal device in the second information and the salt value calculation method supported by the P-CSCF in the first information. The P-CSCF may determine the first calculation method and / or the second calculation method based on the first information, and determine the first salt value using the first calculation method and / or determine the second salt value using the second calculation method.
[0115] It should be understood that when the first device and the second device use the first calculation method and / or the second calculation method to determine the first salt value and / or the second salt value, the parameters used are different (for example, the upstream port number and the downstream port number are different), and the internal algorithms of the first calculation method and the second calculation method may be the same. That is, the first salt value and the second salt value determined by the first device and the second device are different. Under the condition that the salt values used for upstream transmission and downstream transmission between the first device and the second device are different, when the first device and the second device are transmitting upstream, the salt value determined by the first device is the same as the salt value determined by the second device; when the first device and the second device are transmitting downstream, the salt value determined by the first device is the same as the salt value determined by the second device. That is, the security of upstream and downstream communications between the first device and the second device is guaranteed, and the problem of encryption and decryption failure caused by the first device and the second device using different keys is avoided.
[0116] In one possible implementation, the first device and the second device determining the first salt value using the first calculation method may include the first device and the second device determining the first salt value using a first security parameter. The first security parameter includes one or more of the following: an uplink transmission direction identifier, an uplink transmission direction identifier, an uplink port number of the first device and / or the second device, an uplink IP address of the first device and / or the second device, an uplink SPI of the first device and / or the second device, an uplink counter of the first device and / or the second device, and a random number of the first device and / or the second device.
[0117] The first device and the second device can determine the uplink transmission direction identifier, the uplink transmission direction identifier, and the random number. The uplink transmission direction identifier and the uplink transmission direction identifier can also be agreed upon, which is not specifically limited in this application.
[0118] Among them, one or more of the uplink port number of the first device, the uplink IP address of the first device, the uplink SPI of the first device, the uplink counter of the first device, and the random number of the first device can be sent by the first device to the second device through the first message; one or more of the uplink port number of the second device, the uplink IP address of the second device, the uplink SPI of the second device, the uplink counter of the second device, and the random number of the second device can be sent by the second device to the first device through the second message.
[0119] In one possible implementation, the first device and the second device determining the second salt value using the second calculation method may include the first device and the second device determining the second salt value using a second security parameter. The second security parameter includes one or more of the following: a downlink transmission direction identifier, a downlink transmission direction identifier, a downlink port number of the first device and / or the second device, a downlink IP address of the first device and / or the second device, a downlink SPI of the first device and / or the second device, a downlink counter of the first device and / or the second device, and a random number of the first device and / or the second device.
[0120] The first device and the second device can determine the downlink transmission direction identifier, the downlink transmission direction identifier, and the random number. The downlink transmission direction identifier and the downlink transmission direction identifier can also be agreed upon, which is not specifically limited in this application.
[0121] Among them, one or more of the downstream port number of the first device, the downstream IP address of the first device, the downstream SPI of the first device, the downstream counter of the first device, and the random number of the first device can be sent by the first device to the second device through the first message; one or more of the downstream port number of the second device, the downstream IP address of the second device, the downstream SPI of the second device, the upstream counter of the second device, and the random number of the second device can be sent by the second device to the first device through the second message.
[0122] As an example, assuming that the salt value calculation methods supported by the first device include method #1 and method #2, and the salt value calculation methods supported by the second device include method #2, the first device and the second device determine that the first calculation method is method #2 based on the salt value calculation methods supported by the first device and the salt value calculation methods supported by the second device, and the first device and the second device use method #2 to determine the first salt value for the uplink transmission between the first device and the second device. The first device and the second device can respectively use the uplink transmission direction identifier, the uplink transmission direction identifier, the uplink port number of the first device, and the uplink port number of the second device to calculate the first salt value through method #2.
[0123] As another example, assuming that the salt value calculation method supported by the first device includes method #1 and the salt value calculation method supported by the second device also includes method #1, the first device and the second device determine that the second calculation method is method #1 based on the salt value calculation method supported by the first device and the salt value calculation method supported by the second device, and the first device and the second device use method #1 to determine the second salt value for downlink transmission between the first device and the second device. The first device and the second device can respectively use the downlink transmission direction identifier, the downlink SPI of the first device and the downlink SPI of the second device, and the downlink counter of the first device and the downlink counter of the second device to calculate the second salt value through method #1.
[0124] It should be understood that using the first security parameter and the second security parameter to determine the first salt value and the second salt value can distinguish uplink transmission and downlink transmission between the first device and the second device. Those skilled in the art can also use other parameters that can distinguish uplink transmission and downlink transmission between the first device and the second device to determine the first salt value and the second salt value.
[0125] It should also be understood that the first device in the present application may be a terminal device, and the second device may be a P-CSCF; or, the first device is a P-CSCF, and the second device is a terminal device.
[0126] As an example, when the first device is a terminal device and the second device is a P-CSCF, in the uplink transmission between the first device and the second device, the terminal device can act as a client and the P-CSCF can act as a server; in the downlink transmission between the first device and the second device, the terminal device can act as a server and the P-CSCF can act as a client. For example, in the uplink transmission between the first device and the second device, the value of the uplink SPI of the terminal device can be expressed as SPI_uc, where SPI_uc is used to represent the SPI value when the terminal device acts as a client; the value of the uplink SPI of the P-CSCF can be expressed as SPI_ps, where SPI_ps is used to represent the SPI value when the P-CSCF acts as a server.
[0127] According to the method shown in FIG2 above, the first device and the second device can interact with each other to support the salt value calculation method, and can use the first calculation method to determine the first salt value of the uplink transmission between the first device and the second device, and / or can use the second calculation method to determine the first salt value of the downlink transmission between the first device and the second device. In the downlink or uplink transmission between the first device and the second device, the first device and the second device can obtain the same salt value, that is, it can ensure that even if any one of the first device and the second device is upgraded or other configurations change, the first device and the second device can still determine a calculation method based on the salt value calculation method supported by both parties, and the salt value obtained by the first device and the second device through the calculation method is the same, avoiding the problem of different salt values determined by the first device and the second device in the uplink or downlink transmission between the first device and the second device, which leads to the failure of information encryption and decryption.
[0128] At the same time, the first salt value obtained by the method in the embodiment of the present application for uplink transmission between the first device and the second device is different from the second salt value used for downlink transmission between the first device and the second device, thereby improving the security performance of uplink and downlink.
[0129] As shown in FIG2 , the method further includes the following steps:
[0130] 240. The first device uses the first security parameter to determine a first vector for uplink transmission, and / or uses the second security parameter to determine a second vector for downlink transmission.
[0131] 250. The first device sends the first vector and / or the second vector to the second device.
[0132] It will be appreciated that the first vector and the second vector are different.
[0133] The first device determines a first vector for uplink transmission using a first security parameter, where the first security parameter is a parameter related to uplink transmission. The first device determines a second vector for downlink transmission using a second security parameter, where the second security parameter is a parameter related to downlink transmission. If the first security parameter and the second security parameter are different, then the first vector and the second vector are different.
[0134] It should also be understood that the above steps 240 and 250 are similar to steps 310 to 330 in FIG. 3 . Please refer to FIG. 3 for detailed description, which will not be repeated here to avoid redundancy.
[0135] FIG3 is a flow chart of another secure communication method provided in an embodiment of the present application.
[0136] 310 : The first device determines a first vector using a first security parameter, and / or the first device determines a second vector using a second security parameter.
[0137] The first vector is used for uplink transmission between the first device and the second device; the second vector is used for downlink transmission between the first device and the second device.
[0138] Among them, the first security parameter includes one or more of the following: an uplink transmission direction identifier, an uplink transmission direction identifier, an uplink port number of the first device and / or the second device, an uplink IP address of the first device and / or the second device, an uplink SPI of the first device and / or the second device, an uplink counter of the first device and / or the second device, and a random number of the first device and / or the second device; the second security parameter includes one or more of the following: a downlink transmission direction identifier, a downlink transmission direction identifier, a downlink port number of the first device and / or the second device, a downlink IP address of the first device and / or the second device, a downlink SPI of the first device and / or the second device, a downlink counter of the first device and / or the second device, and a random number of the first device and / or the second device.
[0139] It should be understood that the first security parameter and the second security parameter are parameters used to distinguish uplink and downlink transmissions between the first device and the second device. That is, the first security parameter and the second security parameter are different. For example, the uplink port number of the first device included in the first security parameter is different from the uplink port number of the first device included in the second security parameter; and the uplink counter of the first device included in the first security parameter is different from the uplink counter of the first device included in the second security parameter.
[0140] It should also be understood that if the first safety parameter used to determine the first vector and the second safety parameter used to determine the second vector are different, then the first vector and the second vector are different.
[0141] Optionally, the first vector is an initialization vector IV determined by the first device for uplink transmission, and the second vector is an initialization vector IV determined by the first device for downlink transmission.
[0142] 320. The first device sends the first vector and / or the second vector to the second device.
[0143] Specifically, after the first device determines the first vector and / or the second vector, the first device sends the first vector and / or the second vector to the second device.
[0144] Optionally, the first vector is used by the second device to decrypt an encrypted message received from the first device via an uplink communication link, and the second vector is used by the second device to encrypt a message to be sent to the first device via a downlink communication link.
[0145] It should be understood that the first vector can be transmitted to the second device in the same message as the encrypted message sent by the first device to the second device, or the first vector can also be carried in other signaling or algorithm lists and sent to the second device, or the first vector can also be sent to the second device through separate indication information, which is not specifically limited in this application.
[0146] According to the method shown in FIG3 , the first device uses parameters related to distinguishing uplink and downlink transmissions (e.g., port number, direction indicator, direction identifier, IP address, SPI, counter, random number) to determine a first vector and / or a second vector, and sends the first vector and / or the second vector to the second device. The first vector is determined based on a first security parameter related to uplink transmission, and the second vector is determined based on a second security parameter related to downlink transmission. That is, the first vector and the second vector corresponding to uplink and downlink transmissions between the first and second devices are different, thereby ensuring the security of uplink and downlink communications between the first and second devices.
[0147] It should be understood that in the various embodiments described herein, the size of the sequence number of each process does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.
[0148] The various embodiments described herein may be independent solutions or may be combined according to internal logic, and all of these solutions fall within the scope of protection of this application.
[0149] It can be understood that in the above-mentioned method embodiments, the methods and operations implemented by the terminal side can also be implemented by components (such as chips or circuits) that can be used for terminal side devices, and the methods and operations implemented by the network side can also be implemented by components (such as chips or circuits) that can be used for network side devices.
[0150] The method provided in the embodiment of the present application is described in detail above in conjunction with Figures 2 and 3. Below, the secure communication device provided in the embodiment of the present application is described in detail in conjunction with Figures 4 to 6. It should be understood that the description of the device embodiment corresponds to the description of the method embodiment. Therefore, for matters not described in detail, please refer to the method embodiment above. For the sake of brevity, it will not be repeated here.
[0151] The above mainly introduces the solution provided by the embodiment of the present application from the perspective of interaction between various devices. It is understandable that each device, such as a transmitting end device or a receiving end device, includes a hardware structure and / or software module corresponding to the execution of each function in order to implement the above functions. Those skilled in the art should be aware that, in combination with the units and algorithm steps of each example described in the embodiments disclosed herein, the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is executed in a hardware or computer software driven hardware manner depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0152] The embodiment of the present application can divide the functional modules of the first device or the second device according to the above method example. For example, each functional module can be divided according to each function, or two or more functions can be integrated into one processing module. The above integrated modules can be implemented in the form of hardware or in the form of software functional modules. It should be noted that the division of modules in the embodiment of the present application is schematic and is only a logical functional division. There may be other division methods in actual implementation. The following is an example of dividing each functional module according to each function.
[0153] Figure 4 is a schematic block diagram of a secure communication device provided in an embodiment of the present application. The device 400 includes a transceiver unit 410, which can be used to implement corresponding communication functions. The transceiver unit 410 can also be called a communication interface or a communication unit.
[0154] Optionally, the device 400 may further include a processing unit 420, which may be configured to perform data processing.
[0155] Optionally, the device 400 also includes a storage unit, which can be used to store instructions and / or data, and the processing unit 420 can read the instructions and / or data in the storage unit so that the device implements the actions of different terminal devices in the aforementioned method embodiments, for example, the actions of the first device / the actions of the second device.
[0156] The device 400 can be used to execute the actions performed by the first device or the second device in each of the method embodiments above. In this case, the device 400 can be the first device, or a component of the first device, or the second device, or a component of the second device. The transceiver unit 410 is used to execute the transceiver-related operations of the first device or the second device in the method embodiments above, and the processing unit 420 is used to execute the processing-related operations of the first device or the second device in the method embodiments above.
[0157] It should also be understood that the device 400 here is embodied in the form of a functional unit. The term "unit" here can refer to an application specific integrated circuit (ASIC), an electronic circuit, a processor (such as a shared processor, a dedicated processor or a group processor, etc.) and a memory for executing one or more software or firmware programs, a merging logic circuit and / or other suitable components that support the described functions. In an optional example, those skilled in the art will understand that the device 400 can be specifically the first device in the above-mentioned embodiment, which can be used to execute the various processes and / or steps corresponding to the first device in the above-mentioned various method embodiments, or the device 400 can be specifically the second device in the above-mentioned embodiment, which can be used to execute the various processes and / or steps corresponding to the second device in the above-mentioned various method embodiments. To avoid repetition, it will not be described here.
[0158] The apparatus 400 of each of the above-mentioned solutions has the function of implementing the corresponding steps performed by the first device in the above-mentioned method, or the apparatus 400 of each of the above-mentioned solutions has the function of implementing the corresponding steps performed by the second device in the above-mentioned method. The functions can be implemented by hardware, or the corresponding software can be implemented by hardware. The hardware or software includes one or more modules corresponding to the above-mentioned functions; for example, the transceiver unit can be replaced by a transceiver (for example, the sending unit in the transceiver unit can be replaced by a transmitter, and the receiving unit in the transceiver unit can be replaced by a receiver), and other units, such as the processing unit, can be replaced by a processor to respectively perform the sending and receiving operations and related processing operations in each method embodiment.
[0159] In addition, the transceiver unit 410 may also be a transceiver circuit (for example, may include a receiving circuit and a sending circuit), and the processing unit may be a processing circuit.
[0160] It should be noted that the apparatus in FIG4 may be a network element or device in the aforementioned embodiment, or may be a chip or chip system, such as a system on chip (SoC). The transceiver unit may be an input / output circuit or a communication interface; the processing unit may be a processor, microprocessor, or integrated circuit integrated on the chip. This is not limited here.
[0161] As shown in Figure 5, an embodiment of the present application provides another communication device 500. The device 500 includes a processor 510, which is coupled to a memory 520. The memory 520 is used to store computer programs or instructions and / or data. The processor 510 is used to execute the computer programs or instructions stored in the memory 520, or read the data stored in the memory 520, to perform the methods in the above method embodiments.
[0162] Optionally, there are one or more processors 510 .
[0163] Optionally, there are one or more memories 520 .
[0164] Optionally, the memory 520 is integrated with the processor 510 or provided separately.
[0165] Optionally, as shown in Figure 5, the apparatus 500 further includes a transceiver 530, and the transceiver 1130 is configured to receive and / or transmit signals. For example, the processor 510 is configured to control the transceiver 530 to receive and / or transmit signals.
[0166] As a solution, the apparatus 500 is used to implement the operations performed by the first device in each of the above method embodiments.
[0167] For example, the processor 510 is configured to execute computer programs or instructions stored in the memory 520 to implement the relevant operations of the first control plane device in each of the above method embodiments, for example, the first device or the second device in any one of the embodiments shown in FIG. 2 or FIG. 3 .
[0168] It should be understood that the processor mentioned in the embodiments of the present application may be a central processing unit (CPU), or may be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor, etc.
[0169] It should also be understood that the memory mentioned in the embodiments of the present application may be a volatile memory and / or a non-volatile memory. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM). For example, RAM can be used as an external cache. By way of example and not limitation, RAM includes the following forms: static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM), and direct rambus RAM (DR RAM).
[0170] It should be noted that when the processor is a general-purpose processor, DSP, ASIC, FPGA or other programmable logic device, discrete gate or transistor logic device, discrete hardware component, the memory (storage module) can be integrated into the processor.
[0171] It should also be noted that the memory described herein is intended to comprise, but not be limited to, these and any other suitable types of memory.
[0172] As shown in FIG6 , an embodiment of the present application provides a chip system 600 . The chip system 600 (or also referred to as a processing system) includes a logic circuit 610 and an input / output interface 620 .
[0173] Logic circuit 610 may be a processing circuit within chip system 600. Logic circuit 610 may be coupled to a storage unit and invoke instructions within the storage unit, enabling chip system 600 to implement the methods and functions of various embodiments of the present application. Input / output interface 620 may be an input / output circuit within chip system 600, outputting information processed by chip system 600 or inputting data or signaling information to be processed into chip system 600 for processing.
[0174] As a solution, the chip system 600 is used to implement the operations performed by the first device or the second device in the above various method embodiments.
[0175] For example, the logic circuit 610 is used to implement operations related to processing by the first device in the above method embodiments, or operations related to processing by the second device, such as operations related to processing by the first device or the second device in the embodiments shown in either Figure 2 or Figure 3; the input / output interface 620 is used to implement operations related to sending and / or receiving by the first device in the above method embodiments, or operations related to sending and / or receiving by the second device.
[0176] An embodiment of the present application further provides a computer-readable storage medium storing computer instructions for implementing the methods executed by the first device and the second device in the above-mentioned method embodiments.
[0177] For example, when the computer program is executed by a computer, the computer can implement the methods performed by the first device and the second device in each embodiment of the above method.
[0178] An embodiment of the present application further provides a computer program product comprising instructions, which, when executed by a computer, implement the methods performed by the first device and the second device in the above-mentioned method embodiments.
[0179] The explanation of the relevant contents and beneficial effects of any of the above-mentioned devices can be referred to the corresponding method embodiments provided above, which will not be repeated here.
[0180] In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0181] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. For example, the computer can be a personal computer, a server, or a network device, etc. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from one website, computer, server or data center to another website, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that includes one or more available media integrations. The available medium may be a magnetic medium (e.g., a floppy disk, a hard disk, a magnetic tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid state disk (SSD)). For example, the aforementioned available medium includes, but is not limited to, various media that can store program code, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.
[0182] The above description is merely a specific embodiment of the present application, but the scope of protection of the present application is not limited thereto. Any changes or substitutions that can be easily conceived by a person skilled in the art within the technical scope disclosed in this application should be included in the scope of protection of this application. Therefore, the scope of protection of this application should be based on the scope of protection of the claims.
Claims
1. A secure communication method, characterized in that: include: The first device sends first information of the first device to the second device through a first message, where the first message includes one or more of a first port number, a first security parameter index SPI, a first Internet Protocol IP address, a first security algorithm list, and a first random number; The first device receives a second message including second information from the second device, where the second message includes one or more of a second port number, a second security parameter index SPI, a second Internet Protocol IP address, a second security algorithm list, and a second random number; The first device determines, based on the first information and / or the second information, a first salt value for uplink transmission between the first device and the second device using a first calculation method, and / or determines a second salt value for downlink transmission between the first device and the second device using a second calculation method.
2. The method according to claim 1, characterized in that The first information includes one of a first port number of the first message, a first security parameter index SPI, a first Internet Protocol IP address, a first security algorithm list, and a first random number; and / or The second information is included in one of a second port number of the second message, a second security parameter index SPI, a second Internet Protocol IP address, a second security algorithm list, and a second random number.
3. The method according to claim 1 or 2, characterized in that: Determining the first salt value by using the first calculation method includes: calculating the first salt value using a first safety parameter, The first security parameter includes one or more of the following: a direction identifier of the uplink transmission, a direction identifier of the uplink transmission, an uplink port number of the first device and / or the second device, an uplink IP address of the first device and / or the second device, an uplink SPI of the first device and / or the second device, an uplink counter of the first device and / or the second device, and a random number of the first device and / or the second device; Determining the second salt value by using the second calculation method includes: calculating the second salt value using the second security parameter, Among them, the second security parameter includes one or more of the following: the direction identifier of the downlink transmission, the direction identifier of the downlink transmission, the downlink port number of the first device and / or the second device, the downlink IP address of the first device and / or the second device, the downlink SPI of the first device and / or the second device, the downlink counter of the first device and / or the second device, and the random number of the first device and / or the second device.
4. The method according to claim 3, characterized in that The method further comprises: The first device determines, using the first security parameter, a first vector for the uplink transmission, and / or determines, using the second security parameter, a second vector for the downlink transmission; The first device sends the first vector and / or the second vector to the second device.
5. A secure communication method, characterized in that: include: The first device sends first information of the first device to the second device through a first message, where the first message includes one or more of a first port number, a first security parameter index SPI, a first Internet Protocol IP address, a first security algorithm list, and a first random number; The second device receives first information of the first device sent by the first device through a first message; The first device receives a second message including second information from the second device, where the second message includes one or more of a second port number, a second security parameter index SPI, a second Internet Protocol IP address, a second security algorithm list, and a second random number; The first device determines, based on the first information and / or the second information, a first salt value for uplink transmission between the first device and the second device using a first calculation method, and / or determines a second salt value for downlink transmission between the first device and the second device using a second calculation method.
6. A secure communication method, characterized in that: include: The first device determines a first vector for uplink transmission between the first device and the second device using a first security parameter, The first device sends the first vector to the second device; and / or, The first device determines, using a second security parameter, a second vector for downlink transmission between the first device and the second device; The first device sends the second vector to the second device, Among them, the first security parameter includes one or more of the following: an uplink transmission direction identifier, an uplink transmission direction identifier, an uplink port number of the first device and / or the second device, an uplink IP address of the first device and / or the second device, an uplink SPI of the first device and / or the second device, an uplink counter of the first device and / or the second device, and a random number of the first device and / or the second device; the second security parameter includes one or more of the following: a downlink transmission direction identifier, a downlink transmission direction identifier, a downlink port number of the first device and / or the second device, a downlink IP address of the first device and / or the second device, a downlink SPI of the first device and / or the second device, a downlink counter of the first device and / or the second device, and a random number of the first device and / or the second device.
7. A secure communication method, characterized in that: include: The first device determines a first vector for uplink transmission between the first device and the second device using a first security parameter, The first device sends the first vector to the second device; The second device receives the first vector from the first device; and / or, The first device determines, using a second security parameter, a second vector for downlink transmission between the first device and the second device; The first device sends the second vector to the second device; The second device receives the second vector from the first device, Among them, the first security parameter includes one or more of the following: an uplink transmission direction identifier, an uplink transmission direction identifier, an uplink port number of the first device and / or the second device, an uplink IP address of the first device and / or the second device, an uplink SPI of the first device and / or the second device, an uplink counter of the first device and / or the second device, and a random number of the first device and / or the second device; the second security parameter includes one or more of the following: a downlink transmission direction identifier, a downlink transmission direction identifier, a downlink port number of the first device and / or the second device, a downlink IP address of the first device and / or the second device, a downlink SPI of the first device and / or the second device, a downlink counter of the first device and / or the second device, and a random number of the first device and / or the second device.
8. The method according to any one of claims 1 to 7, characterized in that The first device is a terminal device or a chip or circuit configured by the first device in the terminal device, and the second device is a network device or a chip or circuit configured by the second device in the network device; or, The first device is the network device or a chip or circuit configured by the first device in the network device, and the second device is the terminal device or a chip or circuit configured by the second device in the terminal device.
9. A secure communication device, characterized in that: The secure communication device comprises units and modules for executing the method according to any one of claims 1 to 8.
10. A secure communication device, comprising a processor, wherein the processor is coupled to a memory, the memory is used to store instructions, and the processor is used to read the instructions stored in the memory, so that the secure communication device implements the method described in any one of claims 1 to 8.
11. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores instructions, and when the instructions are executed on a computer, the computer is caused to perform the method according to any one of claims 1 to 8.
12. A computer program product, characterized in that The computer program product comprises instructions for executing the method according to any one of claims 1 to 8.
13. A chip, characterized in that: The chip includes a processor and a communication interface. When the processor reads a computer program or instruction through the communication interface and runs the computer program or instruction, the communication device executes the method according to any one of claims 1 to 8.
14. A communication system, characterized in that: The method comprises a first device and a second device, wherein the first device is used to perform the method according to any one of claims 1 to 4; and the second device is used to: Receive first information of the first device through a first message, where the first message includes one or more of a first port number, a first security parameter index SPI, a first Internet Protocol IP address, a first security algorithm list, and a first random number; A second message including second information is sent to the first device, where the second message includes one or more of a second port number, a second security parameter index SPI, a second Internet Protocol IP address, a second security algorithm list, and a second random number.
15. A communication system, characterized in that: The method comprises a first device and a second device, wherein the first device is used to execute the method according to claim 6; and the second device is used to receive a first vector and / or a second vector.
Citation Information
Patent Citations
Secure communication method and device
CN118972838A
Data transmission method and device
CN104468095A
Packet encryption method using block chaining mode of block cipher
KR100864092B1
Apparatus and method for data encryption and decryption of web storage
KR1020180082671A
Method and apparatus for generating confidential parameter
WO2022033433A1
