Message interaction method and device, storage medium and electronic equipment
By adjusting the reply message field of the DHCPv6 address request message, and sending a new address directly to the client, solving the problem of insufficient address acquisition complexity and reliability in the prior art, and achieving fast and reliable address allocation.
Patent Information
- Application Number
- CN202310842411.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-07-10
- Publication Date
- 2025-01-10
AI Technical Summary
During the DHCPv6 address acquisition process, when the server processes the address request message, only the occupied address is added to the unallocated list. The client needs to re-initiate the complete process to obtain a new address, resulting in many operation steps and poor reliability.
By adjusting the fields in the reply message corresponding to the address request message, confirming the authentication option abnormality based on the adjusted reply message, and sending a new address directly to the client to avoid re-initiating the complete address allocation process.
Simplifies address acquisition operations, improves interaction efficiency and reliability, ensures that clients obtain available addresses in a timely manner, and avoids the limitation of not being able to obtain available addresses due to no re-initiating requests.
Smart Images

Figure CN119299425A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of network technology, and in particular to a message interaction method and device, a computer-readable storage medium, and an electronic device. Background Art
[0002] Under normal circumstances, during the DHCPv6 address acquisition process, when the server processes the address request message decline, it only adds the occupied address to the unallocated list. Only when the client re-initiates the complete address allocation process can a new address be allocated.
[0003] In the above method, there are many steps to obtain a new address, and available addresses may be allocated, which has poor reliability and certain limitations. Summary of the invention
[0004] The purpose of the present disclosure is to provide a message interaction method and device, a computer-readable storage medium and an electronic device, thereby overcoming the problem of complex operation of obtaining a new address due to limitations and defects of related technologies, at least to a certain extent.
[0005] According to the first aspect of the present disclosure, a message interaction method is provided, comprising: in response to a request message sent by a client, sending a request reply message to the client; receiving an address request message sent by the client based on the request reply message, adjusting the fields in the reply message corresponding to the address request message, and sending the adjusted reply message to the client; in response to the client determining that the authentication option is abnormal according to the adjusted reply message, sending a new address to the client for message interaction.
[0006] According to a second aspect of the present disclosure, a message interaction device is provided, including: a request message receiving module, used to send a request reply message to the client in response to a request message sent by the client; a message adjustment module, used to receive an address request message sent by the client based on the request reply message, adjust the fields in the reply message corresponding to the address request message, and send the adjusted reply message to the client; an address sending module, used to send a new address to the client in response to the client determining that the authentication option is abnormal according to the adjusted reply message, so as to perform message interaction.
[0007] According to a third aspect of the present disclosure, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the method described in any one of the above and its possible implementation methods are implemented.
[0008] According to a fourth aspect of the present disclosure, an electronic device is provided, comprising: a processor; and a memory for storing executable instructions of the processor; wherein the processor is configured to execute any one of the above-mentioned methods and possible implementations thereof by executing the executable instructions.
[0009] In the technical solution provided in the embodiment of the present disclosure, on the one hand, by adjusting the fields in the reply message corresponding to the address request message, when it is determined that the authentication option is abnormal according to the adjusted reply message, the client is triggered to resend a new authentication message and send the new address to the client, without relying on the complete address allocation process to be re-initiated, the operation steps are simplified, and the next interaction is quickly triggered by filling in the fields, thereby improving the interaction efficiency. On the other hand, the fields in the reply message corresponding to the address request message can be adjusted, and when it is determined that the authentication option is abnormal according to the adjusted reply message, a new authentication message is immediately triggered, so that the new address is sent to the client in time based on the triggered new authentication message, avoiding the limitation of the related art that the available address cannot be obtained if the client no longer re-initiates the request, improving the reliability and flexibility of address allocation, and also improving timeliness, thereby improving the reliability of message interaction.
[0010] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0011] The accompanying drawings herein are incorporated into the specification and constitute a part of the specification, illustrate embodiments consistent with the present disclosure, and together with the specification are used to explain the principles of the present disclosure. Obviously, the accompanying drawings described below are only some embodiments of the present disclosure, and for ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without creative work.
[0012] Figure 1 A schematic diagram shows an application scenario in which the message interaction method according to an embodiment of the present disclosure can be applied.
[0013] Figure 2 A flowchart of a message interaction method according to an embodiment of the present disclosure is schematically shown.
[0014] Figure 3 A schematic diagram schematically illustrates an authentication mechanism in an embodiment of the present disclosure.
[0015] Figure 4 A schematic diagram schematically illustrates a request reply message in an embodiment of the present disclosure.
[0016] Figure 5 A schematic diagram schematically illustrates a protocol standard in an embodiment of the present disclosure.
[0017] Figure 6 The complete flow chart of the interaction performed by the server side in the embodiment of the present disclosure is schematically shown.
[0018] Figure 7 A schematic diagram schematically illustrates message interaction between a client and a server in an embodiment of the present disclosure.
[0019] Figure 8 A block diagram of a message interaction device in an embodiment of the present disclosure is schematically shown.
[0020] Fig. 9 A block diagram of an electronic device in an embodiment of the present disclosure is schematically shown. DETAILED DESCRIPTION
[0021] Example embodiments will now be described more fully with reference to the accompanying drawings. However, example embodiments can be implemented in a variety of forms and should not be construed as being limited to the examples set forth herein; on the contrary, these embodiments are provided so that the present disclosure will be more comprehensive and complete, and the concepts of the example embodiments are fully conveyed to those skilled in the art. The described features, structures, or characteristics may be combined in one or more embodiments in any suitable manner. In the following description, many specific details are provided to provide a full understanding of the embodiments of the present disclosure. However, those skilled in the art will appreciate that the technical solutions of the present disclosure may be practiced while omitting one or more of the specific details, or other methods, components, devices, steps, etc. may be adopted. In other cases, known technical solutions are not shown or described in detail to avoid obscuring various aspects of the present disclosure.
[0022] In addition, the accompanying drawings are only schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the figures represent the same or similar parts, and their repeated description will be omitted. Some of the block diagrams shown in the accompanying drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software form, or implemented in one or more hardware modules or integrated circuits, or implemented in different networks and / or processor devices and / or microcontroller devices.
[0023] In some embodiments, according to the RFC 3315 Dynamic Host Configuration Protocol for IPv6 document, under normal circumstances, the address acquisition process of DHCPv6 may include the following steps: First, the client sends a configuration request to the server. After receiving the configuration request, the server may send a configuration response message to indicate that it can provide services; Next, the client sends a request message to the server to obtain relevant configuration and address information of the server through the request message. After receiving the request message sent by the client, the server may send a request reply message to the client in response to the request message sent by the client. After the client receives the request reply message sent by the server, the address carried in the request reply message may have been used by other nodes. At this time, the client can send an address request message to the server. After the server receives the address request message sent by the client, it sends a reply message to the client after processing.
[0024] In some embodiments, when the current server processes the address request message decline, it only adds the occupied address to the unallocated list, and does not reallocate a new available address in the reply message corresponding to the address request message and send it to the client. Only when the client re-initiates a complete solicit->advertise->request->reply process can a new address be allocated; if the client does not re-initiate the request because the version is too old or for other reasons, it will not be able to obtain an available IPv6 address after the address request message sending process, thus affecting the interaction process.
[0025] In order to solve the above technical problems, in an embodiment of the present disclosure, a message interaction method is provided, which can be a message interaction process applied to a protocol. The protocol can be a DHCPv6 protocol or a DHCPv4 protocol. Figure 1 A schematic diagram of an application scenario for message interaction is shown schematically in FIG.
[0026] refer to Figure 1 As shown in , the client 101 can send a request message to the server 102, and the server can send a request reply message corresponding to the request message to the client. After receiving the request reply message, the client sends an address request message to the server based on the request reply message. The server can adjust the fields in the reply message corresponding to the address request message according to the protocol standard to obtain an adjusted reply message, and send the adjusted reply message to the client; the client determines that the authentication option is abnormal according to the adjusted reply message, and resends a new authentication message to the server. The server can respond to the new authentication message and send a new address to the client, so that the client interacts according to the new address.
[0027] Next, refer to Figure 2 As shown in , each step in the embodiment of the present disclosure is described in detail.
[0028] In step S210, in response to the request message sent by the client, a request reply message is sent to the client.
[0029] The embodiments of the present disclosure can be applied to DHCP application scenarios. DHCP (Dynamic Host Configure Protocol) refers to a network protocol used to configure the IP address, IP prefix and / or other configurations required by an IPv6 host working on an IPv6 network. DHCP can be divided into DHCPv4 and DHCPv6 according to the type of IP protocol. The embodiments of the present disclosure can be applied to the DHCPv4 address acquisition and DHCPv6 address acquisition processes. First, the application in the DHCPv6 address acquisition process is used as an example for explanation.
[0030] DHCP uses the client / server model. The computer that requests configuration information is the DHCP client, and the computer that provides the information is called the DHCP server. There are three ways for DHCP to assign addresses to clients: manual configuration, automatic configuration, and dynamic configuration. The task of dynamic allocation of host addresses is driven by the network host. When the DHCP server receives information from the network host requesting an address, it will send relevant address configuration and other information to the network host to implement dynamic configuration of the network host address information. Among them, the client can be a DHCPv6 client, and the server can be a DHCPv6 server. In addition, the client and server in the embodiments of the present disclosure also support the Authentication Option authentication mechanism, which is designed to prevent tampering attacks in the interaction process and to improve security. Authentication Option is an option object for the entire identity authentication function, and it is necessary to use it to configure the identity authentication function during the application startup phase. The authentication mechanism can be referenced Figure 3 as shown in .
[0031] Before the server receives the request message sent by the client, if both the client and the server support the authentication mechanism, the client may send an authentication message solicit to the server, and the solicit message may be used to request authentication to achieve two-way authentication between the client and the server. Exemplarily, the client may send an authentication message solicit to the server, and the authentication message solicit may carry an authentication option to inform the server that the client supports authentication, and all subsequent interaction processes need to be based on authentication to interact. After receiving the authentication message solicit sent by the client, the server may send an authentication response message corresponding to the authentication message solicit to the client. The authentication response message may be an advertise message, which is used to reply to the authentication message. The authentication response message sent by the server may be used to indicate that the server supports the authentication option, or that the server does not support the authentication option. When the authentication response message indicates that the server supports the authentication option, the subsequent process may continue to be executed; when the authentication response message indicates that the server does not support the authentication option, the subsequent process is stopped.
[0032] Next, after the server sends the authentication response message to the client, the client can send a request message to the server. The request message can be a request message. After the client receives the authentication response message advertise, it selects a server according to the selection rules and sends a request message to the server to request relevant configuration and address, etc. In the disclosed embodiment, when there is only one server, the client selects the server; when there are multiple servers, the client can randomly select a server or select a server according to selection rules such as whether it is in an idle state. After determining the server, the client can send a request message request to the server to request the relevant configuration and address of the server based on the request message. The address can be an IPv6 address, etc.
[0033] After the server receives the request message request sent by the client, it can send a request reply message reply corresponding to the request message to the client. The request messages and various types of messages sent subsequently refer to the authentication process, which will carry authentication options, which is equivalent to an encryption strategy corresponding to the carried key. The request reply message can carry an address to facilitate the client to interact through the address. Exemplarily, msg_type can be filled in, the transaction id of the request message request is copied as the transaction id, and the necessary option option is filled in. An address is allocated from the address pool, option5 (IA_Address) is added, the allocated address and time information are filled in, and the request reply message reply is sent by unicast to send the allocated address to the client through the request reply message. The request reply message can refer to Figure 4 as shown in .
[0034] In step S220, an address request message sent by the client based on the request reply message is received, a field in the reply message corresponding to the address request message is adjusted, and the adjusted reply message is sent to the client.
[0035] In the disclosed embodiment, after sending a request reply message to the client, the client can determine the usage status of the allocated address contained in the request reply message. If the usage status is used, that is, the allocated address has been used in the local link, the client can send an address request message to the server. The address request message can be a decline message, which is used to indicate that the address allocated by the server has been used by other nodes and cannot be allocated again. If the usage status is not used, that is, the allocated address is not used in the local link, the client does not need to send an address request message to the server, and can interact directly through the address.
[0036] After receiving the address request message, the server may process the address request message according to the protocol standard. For example, the address whose usage status is used may be added to the unallocatable list, or other operations may be performed to make the address unallocatable.
[0037] When the address usage status is determined to be used, after receiving the address request message sent by the client, the server may send a reply message corresponding to the address request message to the client. The reply message reply may include multiple fields, for example, a first type field and a second type field. The first type field may be used to indicate the processing status of the address request message, and the first type field may be, for example, a status code; the second type field may be an authentication option field, for example, an Authentication Option.
[0038] In the disclosed embodiment, the fields in the reply message of the address request message can be adjusted to obtain an adjusted reply message. Exemplarily, based on the usage status of the address request message, the first type of field in the reply message corresponding to the address request message can be normally filled, and the second type of field in the reply message can be abnormally filled. Exemplarily, the first type of field can be filled with a first identifier to indicate that the processing status of the address request message is completed; the first type of field can also be filled with a second identifier to indicate that the processing status of the address request message is uncompleted, and which identifier to fill is determined based on the usage status.
[0039] In addition, when adjusting the reply message, the second type field Authentication Option in the reply message may be abnormally filled to obtain an adjusted reply message. Abnormal filling here refers to incorrect filling or no filling of the second type field (authentication option field). For example, if the authentication option field is 1, the authentication option field may be filled with 2 or other illegal fields to incorrectly fill the authentication option field. In other embodiments, the second type field may not be filled to make it an empty field or a missing field, so that the adjusted reply message does not carry the authentication option field.
[0040] In addition, when it is identified that the authentication option field is incorrectly filled or not filled, a prompt mark can be provided to prompt the status of the authentication option field.
[0041] In the disclosed embodiment, by incorrectly filling or not filling the second type field in the reply message corresponding to the address request message to obtain an adjusted reply message, and sending the adjusted reply message to the client, the client can determine whether the validity verification has passed according to the adjusted reply message. For example, when the second type field in the adjusted reply message is incorrectly filled or not filled, it can be determined that the validity verification has not passed. When the second type field in the adjusted reply message is correctly filled, it can be determined that the validity verification has passed. In the disclosed embodiment, only the functional behavior of the server needs to be modified, and there is no need to modify the functional behavior of the client, which improves convenience and processing efficiency.
[0042] In step S230, in response to the client determining that the authentication option is abnormal according to the adjusted reply message, a new address is sent to the client for message interaction.
[0043] In the disclosed embodiment, the client can receive the adjusted reply message sent by the server, and can determine whether the authentication option is abnormal based on the adjusted reply message. Exemplarily, after the client receives the adjusted reply message reply sent by the server, it can determine whether the address request message has been processed based on the first type field in the adjusted reply message; in the case where the address request message has been processed, it can further determine whether the validity verification has been passed based on the second type field in the adjusted reply message. If the authentication option field represented by the second type field is an error field or a missing field, that is, the authentication option field is incorrectly filled or the authentication option field is not filled in the adjusted reply message, it can be considered that the authentication option is illegal or missing, and it can be determined that the validity verification has not been passed. If the authentication option field represented by the second type field is a correct field, that is, the authentication option field is correctly filled in the adjusted reply message, the authentication option can be considered legal, and it can be determined that the validity verification has been passed.
[0044] If the validity verification fails, the server may send a new address to the client so as to perform message interaction between the client and the server through the new address. Exemplarily, after the client determines that the authentication option is abnormal based on the authentication option field in the adjusted reply message, it may trigger a new authentication message process and send the new authentication message to the server; the server may receive the new authentication message resent by the client, provide a new address in response to the new authentication message, and send the new address to the client. Specifically, when the client determines that the authentication option field is illegal or missing based on the second type field in the adjusted reply message, the client may trigger a new authentication message in accordance with the protocol standard, the server receives the new authentication message, and restarts the DHCF configuration process based on the new authentication message. The protocol standard can be found at Figure 5 as shown in .
[0045] Specifically, the client can send a new authentication message, the server receives the new authentication message and sends the corresponding authentication response message to the client. The client further sends a request message to the server, and the server sends a request reply message to the client. The client and the server complete the reconfigured address request process through solicit->advertise->request->reply. After the new address is determined, the new address can be sent to the client to enable the client and server to interact based on the new address. The new address can still be an IPv6 address, as long as it is different from the address sent in the last solicit process. If the validity verification is passed, there is no need to trigger a new authentication message or allocate a new address.
[0046] In the disclosed embodiment, when the allocated address is used, the filling content of the second type field in the reply message corresponding to the address usage message is modified, so that the client can promptly trigger a new authentication message to allocate a new address according to the adjusted reply message, without the need to perform other types of operations. This avoids the limitation of having to wait for a long time or being unable to re-trigger due to the request interval for re-acquiring the address relying on the client's retry mechanism, thereby improving processing efficiency and flexibility, and being able to promptly trigger a new address acquisition process, so that the client can obtain the address in a timely manner, thereby improving reliability and timeliness.
[0047] Figure 6 The overall flow chart of the server side is schematically shown in Figure 6 As shown in , it mainly includes the following steps:
[0048] In step S610, receiving an authentication message sent by the client;
[0049] In step S620, an authentication response message is sent to the client;
[0050] In step S630, a request message sent by the client is received;
[0051] In step S640, a request reply message is sent to the client;
[0052] In step S650, when the client determines that the usage status of the allocated address in the local link is used according to the request reply message, receiving the address request message sent by the client;
[0053] In step S660, the fields in the reply message corresponding to the address request message are adjusted to obtain an adjusted reply message, and the adjusted reply message is sent to the client; wherein the first type of fields in the reply message may be filled normally, and the second type of fields in the reply message may be filled abnormally, for example, filled with an illegal identifier or not filled;
[0054] In step S670, in response to the address request message sent by the client, a new authentication message is triggered to allocate a new address and send it to the client so that the client can normally obtain the new IPv6 address.
[0055] It should be noted that there is also a decline process in the DHCPv4 process, so the technical solution in the embodiment of the present disclosure can be extended to the DHCPv4 process. In addition, the specific steps of processing in the DHCPv4 process are the same as those of processing in the DHCPv4 process, and will not be repeated here.
[0056] Figure 7 Schematically shows a flow chart of message interaction between the client and the server, refer to Figure 7 As shown in , it mainly includes the following steps:
[0057] In step S710, the client sends an authentication message to the server, wherein the authentication message may be a solicit, and the client sends the solicit to locate the server, determine whether there is a server in the current environment, and inform the server that it supports authentication.
[0058] In step S720, the server sends an authentication response message to the client. The authentication response message may be an advertise message, which is used to reply to the authentication message. The authentication response message sent by the server may be used to indicate that the authentication option is supported or not supported. That is, the server may send an advertise message to indicate that it can provide DHCP services.
[0059] In step S730, the client sends a request message to the server. The request message may be Request. After receiving the authentication response message advertise, the client selects a server according to the conditions and sends a request message request to request related configuration and ipv6 address.
[0060] In step S740, the server sends a request reply message to the client. The request reply message reply may include the allocated address.
[0061] In step S750, the client sends an address request message according to the usage status of the address. The address request message can be a decline message. When the client determines from the request reply message that the address contained in the message has been used by another node, it can send an address request message decline message to the server to indicate that the usage status of the address is already used and cannot be allocated again.
[0062] In step S760, the server receives the address request message decline, and after processing, sends a reply message corresponding to the address request message to the client.
[0063] Exemplarily, a reply message sent by the server corresponding to the address request message may be modified to obtain an adjusted reply message, and the adjusted reply message may be sent to the client. The adjusted reply message may include a first type field and a second type field, wherein the first type field is normally filled and the second type field is abnormally filled.
[0064] In step S770, the client sends a new authentication message. After receiving the second type field, if the client determines that the authentication option is illegal or missing according to the second type field in the adjusted reply message, resulting in failure to pass the validity verification, the client can immediately trigger a new authentication message according to the protocol standard, so that the server sends the new address to the client after receiving the new authentication message, so that the client can normally obtain the new IPv6 address, thereby improving the timeliness of the client obtaining the address.
[0065] The technical solution in the disclosed embodiment obtains an adjusted reply message by modifying the second type of message in the reply message. When the authentication option is determined to be illegal or missing through the adjusted reply message, the client will trigger a new authentication message to allocate a new address, so that the client can obtain the new address in time. It avoids the limitation in the related art that a new address can only be allocated when the client re-initiates the authentication message to re-initiate the complete process of solicit->advertise->request->reply. It also avoids the problem that when the client does not re-initiate the request due to an old version or other reasons, it will not be able to obtain an available IPv6 address after the decline process, thereby improving the reliability and timeliness of address allocation, improving the efficiency and convenience of address allocation, and also improving the efficiency of message interaction. In addition, in the disclosed embodiment, there is no need to modify the basic mechanism of the protocol, but to use the interaction mechanism that has been clearly defined in the protocol to optimize the interaction process of the address request message, simplifying the operation steps and improving convenience. During the processing, only the functional behavior of the server needs to be modified, without modifying the functional behavior of the client, which improves convenience.
[0066] The present disclosure provides a message interaction device, referring to Figure 8 As shown in , the message interaction device 800 may include: a request message receiving module 801, a message adjustment module 802 and an address sending module 803, wherein:
[0067] The request message receiving module 801 is used to send a request reply message to the client in response to the request message sent by the client;
[0068] A message adjustment module 802, configured to receive an address request message sent by the client based on the request reply message, adjust a field in a reply message corresponding to the address request message, and send the adjusted reply message to the client;
[0069] The address sending module 803 is used to send a new address to the client for message interaction in response to the client determining that the authentication option is abnormal according to the adjusted reply message.
[0070] In an exemplary embodiment of the present disclosure, the message adjustment module includes: a field filling module, which is used to normally fill the first type field in the reply message corresponding to the address request message, and abnormally fill the second type field in the reply message.
[0071] In an exemplary embodiment of the present disclosure, the field filling module includes: a first field filling module, configured to fill a first type of field in the address request message to determine a processing status.
[0072] In an exemplary embodiment of the present disclosure, the field filling module includes: a second field filling module, configured to incorrectly fill or not fill the authentication option field in the address request message.
[0073] In an exemplary embodiment of the present disclosure, the address sending module includes: an authentication message resending module, which is used to receive a new authentication message resent by the client in response to the client determining that the authentication option is abnormal based on the authentication option field in the adjusted reply message, and send a new address to the client in response to the new authentication message.
[0074] In an exemplary embodiment of the present disclosure, before responding to the request message sent by the client, the device also includes: an authentication module, configured to send an authentication response message corresponding to the authentication message to the client in response to the authentication message sent by the client.
[0075] In an exemplary embodiment of the present disclosure, the address request message is used to indicate that the address in the reply message is used.
[0076] It should be noted that the specific details of each part of the above-mentioned message interaction device have been described in detail in the implementation method of the message interaction method part. The undisclosed details can be found in the implementation method content of the method part, and will not be repeated here.
[0077] The exemplary embodiment of the present disclosure also provides an electronic device. The electronic device may be the above-mentioned terminal. Generally, the electronic device may include a processor and a memory, the memory is used to store executable instructions of the processor, and the processor is configured to execute the above-mentioned message interaction method by executing the executable instructions.
[0078] Below Fig. 9 The mobile terminal 900 in FIG. 1 is taken as an example to exemplify the structure of the electronic device. It should be understood by those skilled in the art that, in addition to the components specifically used for mobile purposes, Fig. 9 The construction in can also be applied to fixed type equipment.
[0079] like Fig. 9 As shown, the mobile terminal 900 may specifically include: a processor 901, a memory 902, a bus 903, a mobile communication module 904, an antenna 1, a wireless communication module 905, an antenna 2, a display screen 906, a camera module 907, an audio module 908, a power module 909 and a sensor module 910.
[0080] The processor 901 may include one or more processing units, for example, the processor 901 may include an AP (Application Processor), a modem processor, a GPU (Graphics Processing Unit), an ISP (Image Signal Processor), a controller, an encoder, a decoder, a DSP (Digital Signal Processor), a baseband processor and / or an NPU (Neural-Network Processing Unit), etc. The method in this exemplary embodiment may be executed by an AP, a GPU or a DSP. When the method involves processing related to a neural network, it may be executed by an NPU, for example, the NPU may load neural network parameters and execute algorithm instructions related to the neural network.
[0081] The encoder can encode (i.e. compress) an image or video to reduce the data size for easy storage or transmission. The decoder can decode (i.e. decompress) the encoded data of the image or video to restore the image or video data. The mobile terminal 900 can support one or more encoders and decoders, for example: image formats such as JPEG (Joint Photographic Experts Group), PNG (Portable Network Graphics), BMP (Bitmap), and video formats such as MPEG (Moving Picture Experts Group) 1, MPEG10, H.1063, H.1064, and HEVC (High Efficiency Video Coding).
[0082] The processor 901 may be connected to the memory 902 or other components via a bus 903 .
[0083] The memory 902 may be used to store computer executable program codes, which may include instructions. The processor 901 executes various functional applications and data processing of the mobile terminal 900 by running the instructions stored in the memory 902. The memory 902 may also store application data, such as images, videos, and other files.
[0084] The communication function of the mobile terminal 900 can be implemented by the mobile communication module 904, antenna 1, wireless communication module 905, antenna 2, modulation and demodulation processor and baseband processor. Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. The mobile communication module 904 can provide 3G, 4G, 5G and other mobile communication solutions applied to the mobile terminal 900. The wireless communication module 905 can provide wireless communication solutions such as wireless LAN, Bluetooth, near field communication, etc. applied to the mobile terminal 900.
[0085] The display screen 906 is used to implement display functions, such as displaying user interfaces, images, videos, etc. The camera module 907 is used to implement shooting functions, such as shooting images, videos, etc., and the camera module may include a color temperature sensor array. The audio module 908 is used to implement audio functions, such as playing audio, collecting voice, etc. The power module 909 is used to implement power management functions, such as charging the battery, powering the device, monitoring the battery status, etc. The sensor module 910 may include one or more sensors for implementing corresponding sensing detection functions. For example, the sensor module 910 may include an inertial sensor, which is used to detect the motion posture of the mobile terminal 900 and output inertial sensing data.
[0086] It should be noted that a computer-readable storage medium is also provided in an embodiment of the present disclosure. The computer-readable storage medium may be included in the electronic device described in the above embodiment; or may exist independently without being assembled into the electronic device.
[0087] The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus or device, or any combination thereof. More specific examples of computer-readable storage media may include, but are not limited to, an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program that may be used by or in conjunction with an instruction execution system, apparatus, or device.
[0088] The computer-readable storage medium can send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer-readable storage medium can be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above. The computer-readable storage medium carries one or more programs, and when the one or more programs are executed by an electronic device, the electronic device implements the method described in the following embodiments.
[0089] Through the description of the above implementation, it is easy for those skilled in the art to understand that the example implementation described here can be implemented by software, or by software combined with necessary hardware. Therefore, the technical solution according to the implementation of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, including several instructions to enable a computing device (which can be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the implementation of the present disclosure.
[0090] In addition, the above-mentioned figures are only schematic illustrations of the processes included in the method according to the exemplary embodiments of the present disclosure, and are not intended to be limiting. It is easy to understand that the processes shown in the above-mentioned figures do not indicate or limit the time sequence of these processes. In addition, it is also easy to understand that these processes can be performed synchronously or asynchronously, for example, in multiple modules.
[0091] It should be noted that, although several modules or units of the device for action execution are mentioned in the above detailed description, this division is not mandatory. In fact, according to the embodiments of the present disclosure, the features and functions of two or more modules or units described above can be embodied in one module or unit. On the contrary, the features and functions of one module or unit described above can be further divided into multiple modules or units to be embodied.
[0092] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing what is disclosed herein. This application is intended to cover any variations, uses, or adaptations of the present disclosure that follow the general principles of the present disclosure and include common knowledge or customary technical means in the art that are not disclosed in the present disclosure. The specification and embodiments are to be considered merely as exemplary, and the true scope and spirit of the present disclosure are indicated by the claims.
[0093] It should be understood that the present disclosure is not limited to the exact structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.
Claims
1. A message interaction method, characterized in that: include: In response to the request message sent by the client, sending a request reply message to the client; receiving an address request message sent by the client based on the request reply message, adjusting a field in a reply message corresponding to the address request message, and sending the adjusted reply message to the client; In response to the client determining that the authentication option is abnormal according to the adjusted reply message, a new address is sent to the client for message interaction.
2. The message interaction method according to claim 1, characterized in that: The adjusting the fields in the reply message corresponding to the address request message includes: The first type field in the reply message corresponding to the address request message is normally filled, and the second type field in the reply message is abnormally filled.
3. The message interaction method according to claim 2, characterized in that: The normally filling the first type field in the reply message corresponding to the address request message includes: According to the processing status of the address request message, the first type field in the reply message corresponding to the address request message is filled.
4. The message interaction method according to claim 2, characterized in that: The abnormal filling of the second type field in the reply message includes: The authentication option field in the address request message is incorrectly filled or not filled.
5. The message interaction method according to claim 1, characterized in that: In response to the client determining that the authentication option is abnormal according to the adjusted reply message, sending a new address to the client includes: In response to the client determining that the authentication option is abnormal according to the authentication option field in the adjusted reply message, receiving a new authentication message resent by the client, and sending a new address to the client in response to the new authentication message.
6. The message interaction method according to claim 1, characterized in that: Before responding to the request message sent by the client, the method further includes: In response to the authentication message sent by the client, an authentication response message corresponding to the authentication message is sent to the client.
7. The message interaction method according to claim 1, characterized in that: The address request message is used to indicate that the address in the reply message is used.
8. A message interaction device, characterized in that: include: A request message receiving module, used to send a request reply message to the client in response to the request message sent by the client; A message adjustment module, used for receiving the address request message sent by the client based on the request reply message, adjusting the fields in the reply message corresponding to the address request message, and sending the adjusted reply message to the client; The address sending module is used to send a new address to the client for message interaction in response to the client determining that the authentication option is abnormal according to the adjusted reply message.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the message interaction method according to any one of claims 1 to 7 is implemented.
10. An electronic device, characterized in that: include: processor; as well as A memory, configured to store executable instructions of the processor; The processor is configured to execute the message interaction method according to any one of claims 1 to 7 by executing the executable instructions.