Traffic hijacking identification method and device, electronic equipment, storage medium and product

By sending the server's SSL characteristic information to the client and obtaining the client's SSL certificate and user behavior characteristics, it can determine whether the client has traffic hijacking behavior, solving the problems of high false negative rate and difficult deployment in the existing technology, and achieving high accuracy. Sexual and imperceptible traffic hijacking identification.

CN118802301AActive Publication Date: 2024-10-18CHINA MOBILE GROUP SICHUAN +1

Patent Information

Application Number
CN202410493360.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-04-23
Publication Date
2024-10-18
Estimated Expiration
2044-04-23

AI Technical Summary

Technical Problem

When the existing technology identifies client traffic hijacking behavior, it is easy for attackers to disguise fake normal messages, resulting in a high false positive rate, and it cannot be deployed in a public environment without any impact, affecting the popularity.

Method used

By sending a server response package to the client, including the server's SSL feature information, using preset detection tools to obtain the client's SSL certificate information and user behavior feature information, it determines the consistency of the SSL certificate information between the server and the client and the user behavior feature fingerprint. , determine whether there is traffic hijacking behavior on the client.

Benefits of technology

It reduces the false negative rate of traffic hijacking, enables deployment without user awareness, and improves the accuracy and popularity of identification.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118802301A_ABST
    Figure CN118802301A_ABST
Patent Text Reader

Abstract

The invention provides a traffic hijacking identification method and device, electronic equipment, a storage medium and a product. The method comprises the following steps: sending a server response packet to a client, wherein the server response packet comprises SSL (Secure Socket Layer) feature information of the server; obtaining response data sent by the client in response to the server response packet; and based on the response data, determining whether the client is a client having a traffic hijacking behavior.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of traffic security technology, and in particular to a traffic hijacking identification method, device, electronic device, storage medium and product. Background Art

[0002] In the related technology, there are usually two ways to identify client traffic hijacking behavior: first, starting from the network request message, analyzing whether there is an attack payload to infer whether there is traffic hijacking behavior; second, installing a monitoring agent on the client, and using the agent to analyze the client process to infer whether there is traffic hijacking behavior.

[0003] However, the first method mentioned above mainly relies on the attack payload as an element for identification. When the attacker uses methods such as obfuscation or escape to disguise the attack payload as a pseudo-normal message to evade the identification logic method, it is easy to have a high false negative rate. The second method mentioned above is to install a monitoring agent on the client, which is generally suitable for environments with strong regulatory requirements within the enterprise. However, in the face of the public environment, it cannot be deployed without any feeling, which affects the user's perception, resulting in a low degree of universality of this method. Summary of the invention

[0004] The present disclosure provides a traffic hijacking identification method, device, electronic device, storage medium and product to solve the problems in the related art.

[0005] A first aspect of the present disclosure provides a method for identifying traffic hijacking, the method comprising:

[0006] Sending a server response packet to the client, wherein the server response packet includes SSL feature information of the server;

[0007] Obtaining response data sent by the client in response to the server response packet;

[0008] Based on the response data, determine whether the client is a client that has traffic hijacking behavior.

[0009] In one embodiment, obtaining the response data sent by the client in response to the server response packet includes:

[0010] In response to the client receiving the server response packet, using the preset detection tool to obtain the SSL certificate information of the client sent by the client in response to the server response packet;

[0011] The determining, based on the response data, whether the client is a client that has traffic hijacking behavior includes:

[0012] Determine whether the SSL certificate information in the SSL characteristic information of the server is consistent with the SSL certificate information of the client;

[0013] If the judgment result is no, it is determined that the client is a client that has traffic hijacking behavior.

[0014] In one embodiment, in response to the client receiving the response packet, the method provided by the present disclosure further includes:

[0015] The user behavior characteristic information in the client response packet is obtained by using a preset detection tool; the client response packet refers to the response packet sent by the client to the server after receiving the server response packet; the user behavior characteristic information includes at least one of the user's session frequency, session time or session quantity;

[0016] Generate the SSL connection feature fingerprint to be checked based on the user behavior feature information;

[0017] Determine whether the SSL certificate information on the server is consistent with the SSL certificate information on the client, including:

[0018] Determine whether the SSL certificate information of the server is consistent with the SSL certificate information of the client, and determine whether the characteristic fingerprint of the SSL connection to be checked is consistent with the characteristic fingerprint of the original SSL connection;

[0019] If the result is no, the client is determined to be a client that has traffic hijacking behavior, including:

[0020] If there is a judgment result of no, it is determined that the client is a client that has traffic hijacking behavior.

[0021] In one embodiment, the user behavior characteristic information includes the user's session frequency, session time, and number of sessions;

[0022] In one embodiment, in response to the client receiving the response packet, the method provided by the present disclosure further includes:

[0023] Using a preset detection tool to obtain the proxy gateway characteristics of the client; the proxy gateway characteristics include at least one of the service category, uniform resource locator URL icon or port number to which the proxy gateway belongs;

[0024] Determine whether the SSL certificate information of the server is consistent with the SSL certificate information of the client, and determine whether the characteristic fingerprint of the SSL connection to be checked is consistent with the characteristic fingerprint of the original SSL connection, including:

[0025] Determine whether the SSL certificate information of the server is consistent with the SSL certificate information of the client, whether the feature fingerprint of the SSL connection to be checked is consistent with the feature fingerprint of the original SSL connection, and whether the proxy gateway feature is consistent with the preset proxy gateway feature.

[0026] In one embodiment, in response to the client receiving the response packet, the method provided by the present disclosure further includes:

[0027] Using a preset detection tool to obtain the first time duration of a traffic packet from being sent by the client to being received by the server, where the traffic packet refers to a traffic packet for communication between the client and the server;

[0028] Determine whether the SSL certificate information of the server is consistent with the SSL certificate information of the client, and determine whether the characteristic fingerprint of the SSL connection to be checked is consistent with the characteristic fingerprint of the original SSL connection, including:

[0029] Determine whether the SSL certificate information of the server is consistent with the SSL certificate information of the client, whether the feature fingerprint of the SSL connection to be checked is consistent with the feature fingerprint of the original SSL connection, whether the proxy gateway feature is consistent with the preset proxy gateway feature, and whether the first duration is greater than the preset duration.

[0030] In one embodiment, before determining whether the SSL certificate information in the SSL characteristic information of the server is consistent with the SSL certificate information of the client, the method provided by the present disclosure further includes:

[0031] Obtain the SSL characteristic information of the server; wherein the SSL certificate information of the server includes at least one of the SSL certificate issuing authority, SSL certificate expiration time, domain name associated with the SSL certificate, IP address bound to the SSL certificate, TLS version, encryption suite, extension information, compression algorithm and browser information.

[0032] A second aspect of the present disclosure provides a traffic hijacking identification device, the device comprising:

[0033] A sending unit, used to send a server response packet to the client, wherein the server response packet includes SSL feature information of the server;

[0034] An acquisition unit, configured to acquire response data sent by the client in response to the server response packet;

[0035] A determination unit is used to determine whether the client is a client that has traffic hijacking behavior based on the response data.

[0036] A third aspect of the present disclosure provides an electronic device, including:

[0037] At least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the method described in the embodiment of the first aspect of the present disclosure.

[0038] The fourth aspect embodiment of the present disclosure proposes a non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to enable a computer to execute the method described in the first aspect embodiment of the present disclosure.

[0039] A fifth aspect embodiment of the present disclosure provides a computer program product, including a computer program, which implements the method described in the first aspect embodiment of the present disclosure when executed by a processor.

[0040] In summary, the present disclosure proposes a traffic hijacking identification method, device, electronic device, storage medium and product, the method comprising: sending a server response packet to a client, the server response packet including a preset detection tool, the preset detection tool being used to detect client feature information; obtaining response data sent by the client in response to the server response packet; and determining whether the client is a client that has engaged in traffic hijacking behavior based on the response data.

[0041] The solution provided by the present disclosure sends a response packet containing the SSL characteristic information of the server to the client, thereby obtaining the response data sent by the client in response to the server response packet, and based on the response data, determines whether the client is a client with traffic hijacking behavior. In the above process, since there is no need to obtain the attack payload from the client and there is no need to install an agent on the client, the underreporting rate of traffic hijacking behavior is reduced while achieving user-unaware deployment.

[0042] 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

[0043] The drawings herein are incorporated into and constitute a part of the specification, illustrate embodiments consistent with the present disclosure, and together with the description are used to explain the principles of the present disclosure, and do not constitute improper limitations on the present disclosure.

[0044] Figure 1 A flow chart of a method for identifying traffic hijacking provided in an embodiment of the present disclosure;

[0045] Figure 2 A schematic diagram of a process for generating a characteristic fingerprint of an SSL connection to be checked provided in an embodiment of the present disclosure;

[0046] Figure 3 A schematic diagram of a process for determining a characteristic fingerprint of an SSL connection to be checked provided in an embodiment of the present disclosure;

[0047] Figure 4A schematic diagram of a process for obtaining proxy gateway characteristics of a client provided in an embodiment of the present disclosure;

[0048] Figure 5 A schematic diagram of the structure of a traffic hijacking identification device provided in an embodiment of the present disclosure;

[0049] Figure 6 A schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION

[0050] Embodiments of the present disclosure are described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to be used to explain the present disclosure, and should not be construed as limiting the present disclosure.

[0051] In order to solve the defects in the related art, the present disclosure provides a traffic hijacking identification method, device, electronic device, storage medium and product. Among them, the traffic hijacking method provided by the present disclosure obtains the client's SSL certificate information through the preset detection tool in the response packet by sending the server response packet to the client; and then judges whether the client has traffic hijacking behavior according to whether the SSL certificate information of the server is consistent with the SSL certificate information of the client. In the above process, since there is no need to obtain the attack payload from the client and there is no need to install an agent on the client, the underreporting rate of traffic hijacking behavior is reduced while achieving user-unaware deployment.

[0052] The traffic hijacking method provided by the present disclosure can be applied to the data transmission system described below.

[0053] The data transmission system includes several node devices, and the number of node devices is not limited. The node device can be a server or a terminal. This application uses the node device as a terminal as an example for introduction. The client is deployed on the terminal, wherein the client can run on the terminal in the form of a browser, or can run on the terminal in the form of an independent application (application, APP), etc. The specific presentation form of the client is not limited here. The server involved in this application can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (Content Delivery Network, CDN), and big data and artificial intelligence platforms. The terminal can be a mobile phone, a computer, an intelligent voice interaction device, a smart home appliance, a vehicle-mounted terminal and an aircraft, etc., but is not limited to this. The embodiments of this application can be applied to various scenarios, including but not limited to cloud technology, artificial intelligence, smart transportation, assisted driving, etc.

[0054] The present disclosure is further described in detail below with reference to the accompanying drawings and specific embodiments.

[0055] like Figure 1 As shown, Figure 1 A flow chart of a method for identifying traffic hijacking provided by an embodiment of the present disclosure. The method for identifying traffic hijacking provided by an embodiment of the present disclosure comprises the following steps:

[0056] Step 101, sending a server response packet to the client, wherein the server response packet includes Secure Socket Layer (SSL) feature information of the server;

[0057] In one embodiment, the SSL characteristic information at least includes the SSL certificate information of the server.

[0058] In one embodiment, SSL is a cryptographic security protocol. SSL initiates an authentication process called a handshake between two communicating devices to ensure that the two devices are indeed who they claim to be. For example, a handshake between a server and a client.

[0059] In one embodiment, SSL also digitally signs the data transmitted between the server and the client to provide data integrity and verify whether the data has been tampered with before reaching the intended recipient.

[0060] In one embodiment, the SSL certificate information of the server includes at least one of the SSL certificate issuing authority, SSL certificate expiration time, domain name associated with the SSL certificate, IP address bound to the SSL certificate, TLS version, encryption suite, extension information, compression algorithm and browser information.

[0061] Step 102, obtaining response data sent by the client in response to the server response packet;

[0062] In one embodiment, a preset detection tool may be used to obtain response data sent by the client in response to the server response packet.

[0063] In one embodiment, the preset detection tool is used to detect client feature information.

[0064] In one embodiment, the client characteristic information at least includes SSL certificate information of the client.

[0065] In one embodiment, the server response packet refers to a response packet generated by the server in response to the handshake request of the client.

[0066] In one embodiment, during the identity authentication process of SSL starting a handshake between a server and a client, the server generates the server's SSL certificate information, and the client generates the client's SSL certificate information.

[0067] Step 103: Based on the response data, determine whether the client is a client that has traffic hijacking behavior.

[0068] In summary, the traffic hijacking identification method provided by the present invention includes: sending a server response packet to the client, the server response packet including a preset detection tool, and the preset detection tool is used to detect client characteristic information; obtaining response data sent by the client in response to the server response packet; based on the response data, determining whether the client is a client that has engaged in traffic hijacking behavior.

[0069] The solution provided by the present disclosure sends a response packet containing the SSL characteristic information of the server to the client, thereby obtaining the response data sent by the client in response to the server response packet, and based on the response data, determines whether the client is a client with traffic hijacking behavior. In the above process, since there is no need to obtain the attack payload from the client and there is no need to install an agent on the client, the underreporting rate of traffic hijacking behavior is reduced while achieving user-unaware deployment.

[0070] In one embodiment, step 102 includes:

[0071] In response to the client receiving the server response packet, using the preset detection tool to obtain the SSL certificate information of the client sent by the client in response to the server response packet;

[0072] In one embodiment, the preset detection tool may be a tool embedded in the server response packet in the form of code or script.

[0073] In one embodiment, the preset detection tool is used to obtain the SSL certificate information of the client after the client receives it.

[0074] In one embodiment, the preset detection tool can be used as a patch, etc., and is sent to the client together with the server response packet when the server sends the server response packet to the client.

[0075] Accordingly, step 103 includes:

[0076] Determine whether the SSL certificate information in the SSL characteristic information of the server is consistent with the SSL certificate information of the client;

[0077] In one embodiment, since the packet capture tool used for traffic hijacking must set itself as an HTTPS proxy gateway to achieve traffic capture, in order to make HTTPS traffic trustworthy, it is usually cheated by forging the SSL certificate of the business system.

[0078] In one embodiment, the preset detection tool obtains the SSL certificate information of the client when the HTTPS connection is currently established on the client, and compares it with the SSL certificate information of the server. If there is a difference, the SSL certificate of the forged business system can be used as evidence of traffic hijacking by the client.

[0079] If the judgment result is no, it is determined that the client is a client that has traffic hijacking behavior.

[0080] Step 105: If the judgment result is no, it is determined that the client is a client that has traffic hijacking behavior.

[0081] In one embodiment, when the client establishes an SSL connection with the server, for the same application, the features of each ClientHello packet sent will be the same. However, the features of different applications will vary from application to application. Therefore, the feature information of different applications can be reduced to generate feature fingerprints as the key determining factor for identifying the application.

[0082] Based on this, Figure 2 As shown, in one embodiment, in response to the client receiving the server response packet, the traffic hijacking behavior identification method further includes:

[0083] Step 201, using the preset detection tool to obtain user behavior feature information of the client;

[0084] In one embodiment, the user behavior characteristic information includes at least one of the user's session frequency, session time or session quantity.

[0085] In one embodiment, data based on the SSL protocol is usually used for web page interaction, instant messaging and voice. Therefore, in order to achieve efficient traffic packet capture, it is also necessary to focus on user behavior characteristics.

[0086] In one embodiment, user behavior characteristics can generally be divided into two categories: user stickiness and user activity. User stickiness is mainly considered by session frequency and session time, and user activity is mainly considered by session quantity.

[0087] In one embodiment, a preset detection tool in a server response packet sent from the server to the client can be used to parse the client response packet sent during the SSL handshake at the server to obtain one of the user's session frequency, session time or session quantity in the ClientHello packet in turn.

[0088] Step 202, generating a feature fingerprint of the SSL connection to be checked based on the user behavior feature information;

[0089] Accordingly, in one embodiment, step 103 includes:

[0090] Determine whether the SSL certificate information of the server is consistent with the SSL certificate information of the client, and determine whether the SSL connection feature fingerprint to be checked is consistent with the original SSL connection feature fingerprint;

[0091] If there is a judgment result of no, it is determined that the client is a client that has traffic hijacking behavior.

[0092] In one embodiment, if the SSL certificate information of the server is inconsistent with the SSL certificate information of the client, or / and the SSL connection feature fingerprint to be checked is inconsistent with the original SSL connection feature fingerprint, the client can be determined to be a client that has engaged in traffic hijacking.

[0093] Based on the foregoing description, in one embodiment, the user behavior characteristic information includes the user's session frequency, session time, and session quantity;

[0094] Correspondingly, such as Figure 3 As shown, in one embodiment, step 202 includes:

[0095] Step 301, using the fifth version of the message digest algorithm (Message Digest Algorithm 5, referred to as MD5) to convert the session frequency, the session time and the number of sessions into a 64-bit hash value;

[0096] In one embodiment, MD5 can input information of any length, and its output is binary data of a fixed length of 64 bits.

[0097] In one embodiment, MD5 has a fast operation speed: MD5 operations are all 32-bit AND, OR, NOT, shift and other bit operations, so its operation speed is fast and almost no CPU time is consumed.

[0098] Step 302: Perform weighted processing on the preset weights corresponding to the session frequency, the session time and the number of sessions and the 64-bit hash value converted from the session frequency, the session time and the number of sessions to obtain the 64-bit hash value corresponding to the weighted session frequency, the session time and the number of sessions;

[0099] Step 303, performing an accumulation operation on the 64-bit hash values ​​corresponding to the weighted session frequency, the session time, and the session quantity to obtain an accumulated 64-bit hash value;

[0100] Step 304: Use the Simhash algorithm to perform dimension reduction processing on the accumulated 64-bit hash value to obtain the characteristic fingerprint of the SSL connection to be checked.

[0101] In one embodiment, when the client has traffic hijacking behavior, the web service will be started as a proxy gateway. Therefore, the service category, Uniform Resource Locator (URL) icon, and port number of the proxy gateway have regularity, and the preset detection tool in the server response package sent by the server can collect and compare the regularity of the proxy gateway and determine whether the client has traffic hijacking behavior.

[0102] Based on this, Figure 4 As shown, in one embodiment, in response to the client receiving the server response packet, the traffic hijacking behavior identification method further includes:

[0103] Step 401, using the preset detection tool to obtain the proxy gateway characteristics of the client; the proxy gateway characteristics include at least one of the service category, uniform resource locator URL icon or port number to which the proxy gateway belongs;

[0104] Accordingly, in one embodiment, step 103 includes:

[0105] Determine whether the SSL certificate information of the server is consistent with the SSL certificate information of the client, determine whether the SSL connection feature fingerprint to be checked is consistent with the original SSL connection feature fingerprint, and determine whether the proxy gateway feature is consistent with the preset proxy gateway feature;

[0106] If there is a judgment result of no, it is determined that the client is a client that has traffic hijacking behavior.

[0107] In one embodiment, if the SSL certificate information of the server is inconsistent with the SSL certificate information of the client, or / and, the SSL connection feature fingerprint to be checked is inconsistent with the original SSL connection feature fingerprint, or / and, the proxy gateway feature is inconsistent with the preset proxy gateway feature, the client can be determined to be a client that has engaged in traffic hijacking.

[0108] In one embodiment, the normal time taken for a client request data packet to be sent from the client's browser to the server is usually short. However, after the attacker uses a tool to intercept the request data packet, there is a retention time when analyzing the message. This will cause the data packet to take a long time to be sent and received. The preset detection tool in the server response packet sent by the server can be written into the request after the data packet is sent and the timestamp is encrypted. When the server receives the data packet, the negative deviation of the calculated time and the normal mean is used as one of the preliminary judgment factors for the client to have traffic hijacking behavior.

[0109] Based on this, in one embodiment, in response to the client receiving the server response packet, the traffic hijacking behavior identification method further includes:

[0110] Using the preset detection tool to obtain a first duration from when a traffic packet is sent by the client to when it is received by the server, the traffic packet being a traffic packet for communication between the client and the server;

[0111] Accordingly, in one embodiment, step 103 includes:

[0112] Determine whether the SSL certificate information of the server is consistent with the SSL certificate information of the client, and determine whether the SSL connection feature fingerprint to be checked is consistent with the original SSL connection feature fingerprint, and determine whether the proxy gateway feature is consistent with the preset proxy gateway feature, and determine whether the first time length is greater than the preset time length.

[0113] In order to implement the traffic hijacking identification method provided by the embodiment of the present disclosure, the embodiment of the present disclosure also provides a traffic hijacking identification device, such as Figure 5 shown. Figure 5 The schematic diagram of the structure of the flow hijacking identification device provided in the embodiment of the present disclosure is as follows:

[0114] The sending unit 501 is used to send a server response packet to the client, wherein the server response packet includes SSL feature information of the server;

[0115] The acquisition unit 502 is used to acquire the response data sent by the client in response to the server response packet;

[0116] The determination unit 503 is used to determine whether the client is a client that has traffic hijacking behavior based on the response data.

[0117] In one embodiment, the acquisition unit 502 is specifically configured to:

[0118] In response to the client receiving the server response packet, using the preset detection tool to obtain the SSL certificate information of the client sent by the client in response to the server response packet;

[0119] Accordingly, the determining unit 503 is specifically configured to:

[0120] Determine whether the SSL certificate information in the SSL characteristic information of the server is consistent with the SSL certificate information of the client;

[0121] If the judgment result is no, it is determined that the client is a client that has traffic hijacking behavior.

[0122] In one embodiment, the traffic hijacking identification device 500 further includes a unit for generating a feature fingerprint of an SSL connection to be detected, and the unit for generating a feature fingerprint of an SSL connection to be detected is used to:

[0123] The user behavior characteristic information in the client response packet is obtained by using a preset detection tool; the client response packet refers to the response packet sent by the client to the server after receiving the server response packet; the user behavior characteristic information includes at least one of the user's session frequency, session time or session quantity;

[0124] Generate the SSL connection feature fingerprint to be checked based on user behavior feature information.

[0125] Accordingly, in one embodiment, the determining unit 503 is specifically configured to:

[0126] Determine whether the SSL certificate information of the server is consistent with the SSL certificate information of the client, and determine whether the characteristic fingerprint of the SSL connection to be checked is consistent with the characteristic fingerprint of the original SSL connection;

[0127] If there is a judgment result of no, it is determined that the client is a client that has traffic hijacking behavior.

[0128] In one embodiment, the SSL connection feature fingerprint unit to be checked is generated, specifically for:

[0129] Generate the SSL connection feature fingerprint to be checked based on user behavior feature information, including:

[0130] Use the MD5 message digest algorithm to convert the session frequency, session time, and session quantity into a 64-bit hash value;

[0131] Perform weighted processing on the preset weights corresponding to the session frequency, session time, and session number and the 64-bit hash value converted from the session frequency, session time, and session number to obtain the 64-bit hash value corresponding to the weighted session frequency, session time, and session number;

[0132] Accumulate the 64-bit hash values ​​corresponding to the weighted session frequency, session time, and session quantity to obtain an accumulated 64-bit hash value;

[0133] The Simhash algorithm is used to reduce the dimension of the accumulated 64-bit hash value to obtain the characteristic fingerprint of the SSL connection to be tested.

[0134] In one embodiment, in one embodiment, the traffic hijacking identification device 500 further includes a proxy gateway feature acquisition unit, and the proxy gateway feature acquisition unit is used to:

[0135] Using a preset detection tool to obtain the proxy gateway characteristics of the client; the proxy gateway characteristics include at least one of the service category, uniform resource locator URL icon or port number to which the proxy gateway belongs;

[0136] Accordingly, in one embodiment, the determining unit 503 is specifically configured to:

[0137] Determine whether the SSL certificate information of the server is consistent with the SSL certificate information of the client, whether the feature fingerprint of the SSL connection to be checked is consistent with the feature fingerprint of the original SSL connection, and whether the proxy gateway feature is consistent with the preset proxy gateway feature.

[0138] In one embodiment, the traffic hijacking identification device 500 further includes a duration acquisition unit, which is used to:

[0139] Using a preset detection tool to obtain the first time duration of a traffic packet from being sent by the client to being received by the server, where the traffic packet refers to a traffic packet for communication between the client and the server;

[0140] Accordingly, in one embodiment, the determining unit 503 is specifically configured to:

[0141] Determine whether the SSL certificate information of the server is consistent with the SSL certificate information of the client, whether the feature fingerprint of the SSL connection to be checked is consistent with the feature fingerprint of the original SSL connection, whether the proxy gateway feature is consistent with the preset proxy gateway feature, and whether the first duration is greater than the preset duration.

[0142] In one embodiment, the SSL certificate information of the server includes at least one of the SSL certificate issuing authority, SSL certificate expiration time, domain name associated with the SSL certificate, IP address bound to the SSL certificate, TLS version, encryption suite, extension information, compression algorithm and browser information.

[0143] It should be noted that: when the traffic hijacking identification device provided in the above embodiment performs traffic hijacking identification, only the division of the above program modules is used as an example. In actual applications, the above processing can be assigned to different program modules as needed, that is, the internal structure of the traffic hijacking identification device is divided into different program modules to complete all or part of the processing described above. In addition, the traffic hijacking identification device provided in the above embodiment and the traffic hijacking identification method embodiment provided in the embodiment of the present disclosure belong to the same concept. The specific implementation process is detailed in the method embodiment and will not be repeated here.

[0144] Figure 6 A schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present disclosure is shown in FIG. Figure 6 As shown, the electronic device 600 includes at least one processor 602; and a memory 601 communicatively connected to the at least one processor 602; wherein the memory 601 stores instructions that can be executed by the at least one processor 602, and the instructions are executed by the at least one processor 602 to implement the steps of the traffic hijacking identification method of the embodiment of the present disclosure.

[0145] Optionally, the electronic device may specifically be a traffic hijacking identification device of an embodiment of the present application, and the electronic device may implement the corresponding processes implemented by the traffic hijacking identification device in each method of the embodiment of the present application, which will not be described in detail here for the sake of brevity.

[0146] It is understood that the electronic device also includes a communication interface 603. The various components in the electronic device are coupled together through a bus system 604. It is understood that the bus system 604 is used to realize the connection and communication between these components. In addition to the data bus, the bus system 604 also includes a power bus, a control bus, and a status signal bus. However, for the sake of clarity, Figure 6 Various buses are labeled as bus system 604 .

[0147] It can be understood that the memory 601 can be a volatile memory or a non-volatile memory, and can also include both volatile and non-volatile memories. Among them, the non-volatile memory can 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), a magnetic random access memory (FRAM), a flash memory, a magnetic surface memory, an optical disc, or a compact disc read-only memory (CD ROM); the magnetic surface memory can be a disk memory or a tape memory. The volatile memory can be a random access memory (RAM), which is used as an external cache. By way of example and not limitation, many forms of RAM are available, such as static random access memory (SRAM), synchronous static random access memory (SSRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDRSDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM, SyncLink Dynamic Random Access Memory), and direct RAM bus random access memory (DRRAM, Direct Rambus Random Access Memory).The memory 601 described in the embodiment of the present invention is intended to include but is not limited to these and any other suitable types of memories.

[0148] The method disclosed in the above embodiment of the present disclosure can be applied to the processor 602, or implemented by the processor 602. The processor 602 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by the hardware integrated logic circuit in the processor 602 or the instruction in the form of software. The above processor 602 may be a general-purpose processor, a DSP, or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, etc. The processor 602 can implement or execute the various methods, steps and logic block diagrams disclosed in the embodiments of the present invention. The general-purpose processor may be a microprocessor or any conventional processor, etc. In combination with the steps of the method disclosed in the embodiment of the present invention, it can be directly embodied as a hardware decoding processor to execute, or it can be executed by a combination of hardware and software modules in the decoding processor. The software module can be located in a storage medium, which is located in the memory 601, and the processor 602 reads the information in the memory 601 and completes the steps of the above method in combination with its hardware.

[0149] In an exemplary embodiment, the electronic device may be implemented by one or more application specific integrated circuits (ASICs), DSPs, programmable logic devices (PLDs), complex programmable logic devices (CPLDs), FPGAs, general purpose processors, controllers, MCUs, microprocessors, or other electronic components to execute the aforementioned method.

[0150] This public security embodiment also provides a non-transitory computer-readable storage medium storing computer instructions, and the computer instructions are used to implement the steps of the traffic hijacking identification method of the embodiment of the present invention when the computer executes them.

[0151] Optionally, the computer-readable storage medium can be applied to the traffic hijacking identification device in the embodiments of the present application, and the computer instructions enable the computer to execute the corresponding processes implemented by the traffic hijacking identification device in the various methods of the embodiments of the present application. For the sake of brevity, they will not be repeated here.

[0152] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. The device embodiments described above are only schematic. For example, the division of units is only a logical function division. There may be other division methods in actual implementation, such as: multiple units or components can be combined, or can be integrated into another system, or some features can be ignored or not executed. In addition, the coupling, direct coupling, or communication connection between the components shown or discussed can be through some interfaces, and the indirect coupling or communication connection of devices or units can be electrical, mechanical or other forms.

[0153] The units described above as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units; some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.

[0154] In addition, all functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may be separately used as a unit, or two or more units may be integrated into one unit; the above-mentioned integrated units may be implemented in the form of hardware or in the form of hardware plus software functional units.

[0155] A person of ordinary skill in the art can understand that: all or part of the steps of implementing the above-mentioned method embodiment can be completed by hardware related to program instructions, and the aforementioned program can be stored in a computer-readable storage medium, which, when executed, executes the steps of the above-mentioned method embodiment; and the aforementioned storage medium includes: various media that can store program codes, such as mobile storage devices, ROM, RAM, disks or optical disks.

[0156] Alternatively, if the above-mentioned integrated unit of the present invention is implemented in the form of a software function module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the embodiment of the present invention can be essentially or partly reflected in the form of a software product that contributes to the prior art. The computer software product is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the methods of each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as mobile storage devices, ROM, RAM, magnetic disks or optical disks.

[0157] The above is only a specific embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any person skilled in the art can easily think of changes or substitutions within the technical scope disclosed by the present invention, which should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention should be based on the protection scope of the claims.

Claims

1. A method for identifying traffic hijacking, characterized in that: include: Sending a server response packet to the client, wherein the server response packet includes SSL feature information of the server; Obtaining response data sent by the client in response to the server response packet; Based on the response data, determine whether the client is a client that has traffic hijacking behavior.

2. The method according to claim 1, characterized in that The obtaining of response data sent by the client in response to the server response packet includes: In response to the client receiving the server response packet, using the preset detection tool to obtain the SSL certificate information of the client sent by the client in response to the server response packet; The determining, based on the response data, whether the client is a client that has traffic hijacking behavior includes: Determine whether the SSL certificate information in the SSL characteristic information of the server is consistent with the SSL certificate information of the client; If the judgment result is no, it is determined that the client is a client that has traffic hijacking behavior.

3. The method according to claim 2, characterized in that After the client receives the server response packet, the method further comprises: Using the preset detection tool to obtain user behavior characteristic information of the client, the user behavior characteristic information includes at least one of the user's session frequency, session time or session quantity; Based on the user behavior feature information, generate a feature fingerprint of the SSL connection to be checked; The determining whether the SSL certificate information of the server is consistent with the SSL certificate information of the client includes: Determine whether the SSL certificate information of the server is consistent with the SSL certificate information of the client, and determine whether the SSL connection feature fingerprint to be checked is consistent with the original SSL connection feature fingerprint; If the judgment result is no, determining that the client is a client that has traffic hijacking behavior includes: If there is a judgment result of no, it is determined that the client is a client that has traffic hijacking behavior.

4. The method according to claim 2, characterized in that After the client receives the server response packet, the method further comprises: Using the preset detection tool to obtain the proxy gateway characteristics of the client; the proxy gateway characteristics include at least one of the service category, uniform resource locator URL icon or port number to which the proxy gateway belongs; The determining whether the SSL certificate information of the server is consistent with the SSL certificate information of the client, and determining whether the SSL connection feature fingerprint to be checked is consistent with the original SSL connection feature fingerprint, includes: Determine whether the SSL certificate information of the server is consistent with the SSL certificate information of the client, determine whether the SSL connection feature fingerprint to be checked is consistent with the original SSL connection feature fingerprint, and determine whether the proxy gateway feature is consistent with the preset proxy gateway feature.

5. The method according to claim 4, characterized in that After the client receives the server response packet, the method further comprises: Using the preset detection tool to obtain a first duration from when a traffic packet is sent by the client to when it is received by the server, the traffic packet being a traffic packet for communication between the client and the server; The determining whether the SSL certificate information of the server is consistent with the SSL certificate information of the client, and determining whether the SSL connection feature fingerprint to be checked is consistent with the original SSL connection feature fingerprint, includes: Determine whether the SSL certificate information of the server is consistent with the SSL certificate information of the client, and determine whether the SSL connection feature fingerprint to be checked is consistent with the original SSL connection feature fingerprint, and determine whether the proxy gateway feature is consistent with the preset proxy gateway feature, and determine whether the first time length is greater than the preset time length.

6. The method according to any one of claims 2 to 5, characterized in that Before determining whether the SSL certificate information in the SSL characteristic information of the server is consistent with the SSL certificate information of the client, the method further includes: Obtain the SSL characteristic information of the server; wherein the SSL certificate information of the server includes at least one of the SSL certificate issuing authority, SSL certificate expiration time, domain name associated with the SSL certificate, IP address bound to the SSL certificate, TLS version, encryption suite, extension information, compression algorithm and browser information.

7. A traffic hijacking identification device, characterized in that: include: A sending unit, used to send a server response packet to the client, wherein the server response packet includes SSL feature information of the server; An acquisition unit, configured to acquire response data sent by the client in response to the server response packet; A determination unit is used to determine whether the client is a client that has traffic hijacking behavior based on the response data.

8. An electronic device, characterized in that: include: at least one processor; as well as a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor to enable the at least one processor to perform the method according to any one of claims 1 to 7.

9. A non-transitory computer-readable storage medium storing computer instructions, characterized in that: The computer instructions are used to cause the computer to execute the method according to any one of claims 1 to 7.

10. A computer program product, characterized in that The invention comprises a computer program which, when executed by a processor, implements the method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Network hijacking treatment method, device and system

    CN107360187A

  • Method and system for verifying SSL certificate

    CN108259406A

  • Service hijacking prevention system, method and device and storage medium

    CN111865956A

  • Webpage hijacking detection method and device, computer equipment and storage medium

    CN112152993A

  • Method and device for positioning HTTP hijacking, medium and equipment

    CN112311724A

Cited By

  • Traffic hijacking detection method and device based on multi-dimensional protocol feature cross validation

    CN122179154A

  • Traffic hijacking detection method and device based on multi-dimensional protocol feature cross-validation

    CN122179154B