Article information processing method and device, electronic equipment and storage medium
By expressing product prices as a pixel matrix and performing scrambling, the problem of easy crawling of product prices in clear text is solved, and secure transmission and anti-crawling effects of price data are achieved.
Patent Information
- Application Number
- CN202410585676.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-11
- Publication Date
- 2024-08-23
AI Technical Summary
Commodity prices transmitted in plain text are easily crawled by illegal platforms, causing security issues in platform operations.
The product price is represented as a pixel matrix and scrambled. The scrambled pixel matrix cannot be restored in the eyes of illegal platforms and unauthorized visitors. By using data scrambling and descrambling technologies on the server side and user side respectively, it is ensured that Security of price data.
It effectively improves the anti-crawling effect of commodity price data, prevents illegal platforms from obtaining original price data through crawlers parsing page content, and enhances the security of data transmission.
Smart Images

Figure CN118536153A
Abstract
Description
Technical Field
[0001] Embodiments of the present invention relate to the field of computer technology, and in particular, to an item information processing method, device, electronic device, and storage medium. Background Art
[0002] At present, the price of goods is transmitted to the user end in plain text. In the process of implementing the present invention, the inventor found that since the price of goods is transmitted in plain text, illegal platforms can use crawlers to parse the page content and build a page document object model (DOM) structure based on the parsing results, and use the page DOM structure to locate the price element, thereby extracting the price of goods. That is, the price of goods is transmitted in plain text, and the price data is easily crawled by illegal platforms, which may cause security problems in platform operations. Summary of the invention
[0003] Embodiments of the present invention provide an item information processing method, device, electronic device and storage medium, which can improve the anti-climbing effect of price data and protect the security of commodity price data.
[0004] In a first aspect, an item information processing method provided by an embodiment of the present invention is applied to a server, including:
[0005] Receiving an item attribute acquisition request sent by a user terminal, wherein the item attribute acquisition request includes an item identifier of a target item;
[0006] Acquire an original pixel matrix corresponding to the attribute value of the target object according to the object identification;
[0007] Performing scrambling processing on the original pixel matrix to obtain a scrambled pixel matrix;
[0008] Feedback an item attribute acquisition response to the user terminal, wherein the item attribute acquisition response includes the scrambled pixel matrix, so that the user terminal determines the attribute value by using the original pixel matrix obtained by descrambling the scrambled pixel matrix.
[0009] In a second aspect, an item information processing method provided by an embodiment of the present invention is applied to a user terminal, including:
[0010] Sending an item attribute acquisition request to a server, wherein the item attribute acquisition request includes an item identifier of a target item, so that the server acquires an original pixel matrix corresponding to an attribute value of the target item according to the item identifier;
[0011] Receiving an item attribute acquisition response fed back by the server, wherein the item attribute acquisition response includes a scrambled pixel matrix, and the scrambled pixel matrix is obtained by scrambling the original pixel matrix by the server;
[0012] Performing descrambling processing on the scrambled pixel matrix to obtain the original pixel matrix;
[0013] The property value is determined based on the original pixel matrix.
[0014] In a third aspect, an article information processing device provided by an embodiment of the present invention includes:
[0015] A request receiving module, used to receive an item attribute acquisition request sent by a user terminal, wherein the item attribute acquisition request includes an item identifier of a target item;
[0016] An acquisition module, used for acquiring an original pixel matrix corresponding to the attribute value of the target object according to the object identification;
[0017] A scrambling module, used for performing scrambling processing on the original pixel matrix to obtain a scrambled pixel matrix;
[0018] A feedback module is used to feed back an item attribute acquisition response to the user terminal, wherein the item attribute acquisition response includes the scrambled pixel matrix, so that the user terminal determines the attribute value by using the original pixel matrix obtained by descrambling the scrambled pixel matrix.
[0019] In a fourth aspect, an embodiment of the present invention provides an item information processing device, including:
[0020] A sending module, configured to send an item attribute acquisition request to a server, wherein the item attribute acquisition request includes an item identifier of a target item, so that the server acquires an original pixel matrix corresponding to an attribute value of the target item according to the item identifier;
[0021] a response receiving module, configured to receive an item attribute acquisition response fed back by the server, wherein the item attribute acquisition response includes a scrambled pixel matrix, and the scrambled pixel matrix is obtained by scrambling the original pixel matrix by the server;
[0022] A descrambling module, used for performing descrambling processing on the scrambled pixel matrix to obtain the original pixel matrix;
[0023] A determination module is used to determine the attribute value based on the original pixel matrix.
[0024] In a fifth aspect, an electronic device provided by an embodiment of the present invention includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, an item information processing method as in any embodiment of the present invention is implemented.
[0025] In a sixth aspect, an item information processing system provided by an embodiment of the present invention includes a server end for executing the item information processing method of any embodiment of the present invention and a user end for executing the item information processing method of any embodiment of the present invention.
[0026] In a seventh aspect, an embodiment of the present invention provides a computer-readable storage medium, on which a computer program is stored, and when the program is executed by a processor, an item information processing method as in any embodiment of the present invention is implemented.
[0027] According to the scheme of the embodiment of the present invention, the attribute value of the item can be the commodity price, that is, the commodity price is represented by a pixel matrix, and the pixel matrix is scrambled. The scrambled pixel matrix cannot be restored for illegal platforms and other unauthorized visitors, and has no practical significance. Therefore, even if the illegal platform parses the page content through a crawler to create a DOM structure, it cannot directly obtain the original commodity price data, thereby improving the security of the commodity price data; the pixel matrix corresponding to the commodity price is scrambled and then transmitted, which solves the problem of plain text transmission of price data from the source of the data, and improves the anti-crawling effect of price data; in addition, the present invention uses data scrambling and de-scrambling technology on the server and the user respectively, which is a relatively simple and effective data processing method, which is relatively easy to implement and can be compatible with existing systems and processes, and does not require major modifications to the existing system. The technical implementation is feasible, simple and effective. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] In order to more clearly illustrate the technical solution of the present invention, the drawings required for use in the embodiments are briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present invention and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.
[0029] Figure 1 is a flow chart of an item information processing method provided by an embodiment of the present invention;
[0030] Figure 2a is another flowchart of the method for processing item information provided by an embodiment of the present invention;
[0031] Figure 2b is an example diagram of gridding attribute values according to pixels provided by an embodiment of the present invention;
[0032] Figure 2c is an example diagram of pre-stored data for attribute values provided by an embodiment of the present invention;
[0033] Figure 2dThis is an example diagram of the effect of scrambling a pixel matrix provided by an embodiment of the present invention;
[0034] Figure 3a is another flowchart of the method for processing item information provided by an embodiment of the present invention;
[0035] Figure 3b is an example diagram of drawing an attribute value picture provided by an embodiment of the present invention;
[0036] Figure 4 is a structural schematic diagram of an item information processing device provided by an embodiment of the present invention;
[0037] Figure 5 is another structural schematic diagram of the item information processing device provided by an embodiment of the present invention;
[0038] Figure 6 is a structural schematic diagram of an item information processing system provided by an embodiment of the present invention;
[0039] Figure 7 It is a structural schematic diagram of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0040] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
[0041] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0042] Figure 1This is a flow chart of the method for processing item information provided by an embodiment of the present invention. The method for processing item information provided by an embodiment of the present invention can be used in the scenario of preventing commodity prices from being crawled by illegal platforms. Of course, the method for processing item information provided by an embodiment of the present invention can also be applied to other scenarios where the security of item attribute data needs to be ensured. The following is only an example of the method for preventing commodity prices from being crawled by illegal platforms. The method of the embodiment of the present invention can be executed by the item information processing device provided by an embodiment of the present invention, which can be implemented in software and / or hardware.
[0043] In a specific embodiment, the item information processing method provided by the embodiment of the present invention can be applied to an item information processing system including a user end and a server end. The user end can be the front end corresponding to the shopping platform, and the server end can be the back end corresponding to the shopping platform. The shopping platform is used for users to purchase target items from merchants. The target items can be any commodities. The user end and the server end cooperate with each other to achieve anti-price climbing of commodities.
[0044] The following first describes the item information processing method provided by the embodiment of the present invention from the server side. The server side can be an electronic device such as a computer or a server. The server side provides background data support for the shopping platform. Figure 1 The item information processing method of this embodiment may include the following steps:
[0045] Step 110: receiving an item attribute acquisition request sent by a user terminal, wherein the item attribute acquisition request includes an item identifier of a target item.
[0046] The user end may be a user's mobile phone, personal computer or other electronic device. The user end may install a shopping platform. The user may send an item attribute acquisition request to the server end through the shopping platform of the user end. The item attribute acquisition request is used to request to obtain the attribute value of the target item from the server end. The attribute of the target item may be information used to characterize the characteristics, properties, etc. of the target item. For example, the attributes of the target item may include price, size, model, etc., and the attribute value of the target item may be a specific value of price, size, model, etc. The item attribute acquisition request may be a Hypertext Transfer Protocol (HTTP) request, a Hypertext Transfer Protocol Secure (HTTPS) request, etc., and the server end receives the item attribute acquisition request sent by the user end. The target item may be any item that the user wants to buy, check the price or pay attention to, and the item identifier may be identification information used to distinguish different items or identify the target item. For example, the item identifier may be the item name, item number, stock keeping unit (SKU) of the item, etc.
[0047] Step 120: Obtain the original pixel matrix corresponding to the attribute value of the target object according to the object identification.
[0048] The server has the attribute value of the target item. In order to avoid leakage of the attribute value of the target item, the server can generate the corresponding original pixel matrix for the attribute value of the target item in advance and store the original pixel matrix, that is, the server stores the attribute value of the target item in the form of a pixel matrix. After obtaining the object identification of the target item, the server can obtain the original pixel matrix corresponding to the attribute value of the pre-stored target item according to the object identification. The pixel matrix is a two-dimensional matrix structure used to represent the pixel distribution of the attribute value.
[0049] Specifically, the service end can grid the shape of the attribute value of the target item according to the pixel grid, thereby obtaining the pixel grid, and create the original pixel matrix corresponding to the attribute value according to the characteristics of each pixel in the pixel grid. Gridding the shape of the attribute value according to the pixel grid can be understood as dividing the number representing the attribute value into several small areas, each area represents a pixel, and mapping the pixel representing the attribute value to a blank grid of a fixed size. After mapping, the pixel representing the attribute value is distinguished from other pixels and displayed, and the other pixels are blank pixels that do not represent the attribute value, thereby obtaining a pixel grid, which is a grid that uses pixels to reflect the shape of the attribute value. The characteristics of each pixel in the pixel grid can be an element that distinguishes the display of the pixel representing the attribute value from other pixels. For example, the characteristics of each pixel in the pixel grid can be the character representation, color representation, brightness representation, etc. of each pixel. After obtaining the pixel grid, the position of each pixel in the pixel grid can be determined by its row and column index in the grid, so the original pixel matrix corresponding to the attribute value can be created according to the position of each pixel and the characteristics of each pixel. The original pixel matrix is a matrix that has not been disturbed. The attribute value of the target object can be composed of numbers, decimal points, etc. Each component factor corresponds to an original pixel matrix, that is, the attribute value of the target object can be represented by a pixel matrix group.
[0050] For example, the number 8 is represented by a 10*10 grid pixel, in which some pixels are colored and others are colorless, i.e., blank pixels. The combination of colored pixels and colorless pixels can reflect the shape of the data 8. The pixel matrix corresponding to the number 8 can be created based on the position of each pixel in the pixel grid corresponding to the number 8 and the characteristics of each pixel. Assuming that the price of a product is 518.00, each component factor in this price corresponds to an original pixel matrix, and the price of 518.00 can be represented by a pixel matrix group including 6 original pixel matrices.
[0051] Step 130, scrambling the original pixel matrix to obtain a scrambled pixel matrix.
[0052] Matrix scrambling is a technical means of processing the matrix by changing the order of elements in the matrix, exchanging positions, or applying other transformation operations to increase the complexity of the data or the difficulty of cracking. For example, scrambling the original pixel matrix may include one or a combination of the following operations:
[0053] Element arrangement transformation: changing the arrangement order of elements in the matrix, for example, the order of the original pixels can be disrupted by using a randomization algorithm or a specific arrangement algorithm;
[0054] Position exchange: By exchanging elements at different positions in the matrix, the position of the original pixel changes;
[0055] Numerical transformation: Numerical transformation of elements in a matrix, such as changing the value of an element by applying arithmetic operations or applying encryption algorithms.
[0056] The purpose of scrambling the original pixel matrix is to make the relationship between the scrambled pixel matrix and the original pixel matrix complicated or difficult to understand. Through scrambling, the information in the original pixel matrix is obfuscated, so that only the user end with the corresponding parsing algorithm or key can parse and restore the scrambled pixel matrix, thereby protecting the security or privacy of the data.
[0057] Step 140: Feedback an item attribute acquisition response to the user end, wherein the item attribute acquisition response includes a scrambled pixel matrix, so that the user end determines the attribute value of the target item by using an original pixel matrix obtained by descrambling the scrambled pixel matrix.
[0058] The server and the user may pre-agree on the matrix scrambling algorithm used by the server, or may pre-agree on the matrix descrambling algorithm used by the user. After the server feeds back the scrambled pixel matrix to the user, the user may descramble the scrambled pixel matrix according to the pre-agreed algorithm to obtain the original pixel matrix. The user may determine the attribute value of the target object according to the original pixel matrix.
[0059] The scheme of this embodiment represents the attribute value of the item, such as the commodity price, with a pixel matrix, and scrambles the pixel matrix. The scrambled pixel matrix cannot be restored for illegal platforms and other unauthorized visitors, and has no practical significance. Therefore, even if the illegal platform parses the page content through a crawler to create a DOM structure, it cannot directly obtain the original commodity price data, thereby improving the security of the commodity price data; the pixel matrix corresponding to the commodity price is scrambled and then transmitted, which solves the problem of plain text transmission of price data from the source of the data, and improves the anti-crawling effect of price data; in addition, the present invention uses data scrambling and de-scrambling technology on the server and user ends respectively. This technology is a relatively simple and effective data processing method, which is relatively easy to implement and is compatible with existing systems and processes. It does not require major modifications to the existing system, and the technical implementation is feasible, simple and effective.
[0060] The following further describes the method for processing item information provided by the embodiment of the present invention by taking the attribute value being price as an example from the server end. Figure 2a As shown, the item information processing method of this embodiment may include the following steps:
[0061] Step 210: Mapping the attribute value of the target item using a preset mapping function to obtain a function mapping value corresponding to the attribute value.
[0062] The preset mapping function is a function that maps input data to an output value of a fixed length. For example, the preset mapping function may be a hash function, a message authentication code function, a gradient increasing coding function, etc. The attribute value of the target item is mapped using the preset mapping function, and the attribute value of the target item is represented by the mapped function mapping value, which can protect the attribute value of the target item from being leaked. Since the attribute value of the target item can be composed of multiple factors such as numbers and decimal points, each component factor of the attribute value of the target item can be mapped using the preset mapping function to obtain the function mapping value corresponding to each component factor. That is, after the attribute value of the target item is mapped, an array of function mapping values will be obtained.
[0063] Take the preset mapping function as a hash function and the price of the target item as 518.00 as an example. Assuming that the hash value obtained after mapping the number 5 with the hash function is represented by hash5, the hash value obtained after mapping the number 1 is represented by hash1, the hash value obtained after mapping the number 8 is represented by hash8, the hash value obtained after mapping the decimal point is represented by hash-, and the hash value obtained after mapping the number 0 is represented by hash0, then after the hash function is used to map the price 518.00, the hash array obtained can be as follows:
[0064] [hash5, hash1, hash8, hash-, hash0, hash0].
[0065] Step 220 , gridding the shape of the attribute value of the target object according to pixels to obtain a pixel grid, and creating an original pixel matrix corresponding to the attribute value according to the characteristics of each pixel in the pixel grid.
[0066] The attribute value of the target item can be represented by different fonts, that is, the attribute value of the target item can have different shapes. The specific font used can be preset according to actual needs. Specifically, when processing the attribute value of the target item, each component factor representing the attribute value can be divided into several small areas, each area represents a pixel, and the pixel representing the attribute value is mapped to a blank grid of a fixed size. After mapping, the pixel representing the attribute value and other pixels are distinguished and displayed, thereby obtaining a pixel grid. The pixel grid is a grid that uses pixels to reflect the shape of the attribute value. The feature of each pixel in the pixel grid can be an element that distinguishes the pixel representing the attribute value from other pixels. For example, the feature of each pixel in the pixel grid can be a character representation, color representation, brightness representation, etc. of each pixel. For example, if one of the component factors of the attribute value is the number 5, the pixel corresponding to 5 in the pixel grid can be represented by a character such as a non-zero number, an asterisk, etc., and the pixels other than the pixel corresponding to 5 in the pixel grid can be represented by another character such as 0, a pound sign, etc.; or the pixel corresponding to 5 in the pixel grid and other pixels can be represented by different colors or different brightness to distinguish the pixels.
[0067] Figure 2b This is an example diagram of how to grid the attribute values according to pixels. Taking the gridding of the number 5 as an example, in the grid, the pixels corresponding to the shape of the number 5 can be represented by the number 5, and the other pixels in the grid can be represented by 0, so as to use the pixel grid to reflect the number 5.
[0068] After obtaining the pixel grid, the position of each pixel in the pixel grid can be determined by its row and column index in the grid, so the original pixel matrix corresponding to the attribute value can be created according to the position of each pixel and the characteristics of each pixel. The original pixel matrix is an unperturbed matrix. The attribute value of the target object can be composed of factors such as numbers and decimal points. Each component factor corresponds to an original pixel matrix, that is, the attribute value of the target object can be represented by a pixel matrix group.
[0069] Specifically, a matrix with m rows and n columns can be defined according to the size of the pixel grid, where m and n are both positive integers. mn Represents the pixel in the mth row and nth column of the pixel grid, then an original pixel matrix can be expressed as follows:
[0070]
[0071] The features of each pixel in the pixel grid can be quantified, for example, an asterisk is represented by 1 and a pound sign is represented by 0. The original pixel matrix of each component factor is created according to the position and quantified features of each pixel. Each pixel in the original pixel matrix can be represented by a specific numerical value.
[0072] In practical applications, a preset mapping function can be used to map the possible components of the attribute value in advance, such as 0 to 9 and a decimal point, and the mapping results can be saved. The possible components of the attribute value can also be gridded in pixels in advance and an original pixel matrix can be created and saved. That is, a function mapping value and an original pixel matrix are stored in advance on the server side for each possible component factor. For example, the server side can store the pre-stored data for the attribute value as follows: Figure 2c As shown, each number corresponds to a pre-stored hash value and a matrix data, and the matrix data is the original pixel matrix. When the attribute value of the target object needs to be processed, the storage can be directly queried to obtain the function mapping value and the original pixel matrix corresponding to each component factor of the attribute value of the target object, so as to improve data processing efficiency.
[0073] Step 230: Store the function mapping value and the original pixel matrix corresponding to the attribute value in the form of key-value pairs.
[0074] The key in the key-value pair is the function mapping value corresponding to the attribute value, which can be a hash array, and the value in the key-value pair is the original pixel matrix corresponding to the attribute value, which can be a pixel matrix group. The function mapping value and the original pixel matrix corresponding to the attribute value are stored in the form of key-value pairs, and the corresponding values can be quickly retrieved and accessed through the key later, thereby improving data retrieval efficiency. In addition, storing the function mapping value and the original pixel matrix corresponding to the attribute value in the form of key-value pairs is equivalent to converting and encrypting the attribute value of the target object instead of directly storing the original plaintext attribute value, which can protect the security of the attribute value of the target object.
[0075] Step 240: receiving an item attribute acquisition request sent by the user terminal, wherein the item attribute acquisition request includes an item identifier of the target item.
[0076] The item identification may be identification information used to distinguish different items or identify a target item. For example, the item identification may be an item name, an item number, an item SKU, etc.
[0077] Step 250: Obtain a function mapping value corresponding to the attribute value of the target item according to the item identifier.
[0078] Step 260, obtaining the original pixel matrix according to the function mapping value.
[0079] That is, first query the stored key according to the item ID, the key is the function mapping value, and then retrieve the value according to the key, the value is the original pixel matrix.
[0080] Step 270, determine the disturbance parameters.
[0081] The disturbance parameter is a parameter used to disturb the original pixel matrix. There may be one or more disturbance parameters, depending on actual needs, and no specific limitation is made here. Specifically in this embodiment, the disturbance parameter may include a fixed disturbance parameter and a dynamic disturbance parameter. The fixed disturbance parameter may be a relatively fixed and unchanged disturbance parameter, and the dynamic disturbance parameter may be a disturbance parameter that changes with the request or time. The fixed disturbance parameter may be determined according to the function mapping value corresponding to the attribute value of the target item stored in the server, and the dynamic disturbance parameter may be obtained from the item attribute acquisition request.
[0082] For fixed disturbance parameters, taking the preset mapping function as a hash function as an example, the fixed disturbance parameters can be determined by starting the matrix transposition at intervals according to the mantissa AZ of the hash value, and the matrix transposition is to swap the rows and columns of the matrix. The rule of starting the matrix transposition at intervals according to the mantissa AZ of the hash value can be preset. For example, the rule of starting the matrix transposition at intervals according to the mantissa AZ of the hash value can be shown in Table 1 below:
[0083]
[0084] Table 1
[0085] As shown in Table 1, if the last digit of the hash value corresponding to a component factor of the attribute value is A, the original pixel matrix corresponding to the component factor is transposed; if the last digit of the hash value corresponding to a component factor is B, the original pixel matrix corresponding to the component factor is not transposed.
[0086] For example, assume that the price of a product is 518.00, where the hash value digits corresponding to 5 and 1 are A and C respectively, and the hash value digits corresponding to 8, a decimal point, and 0 are B, D, and F respectively. For the pixel matrix group corresponding to 518.00, the fixed disturbance parameter may be to enable matrix transposition for the original pixel matrix corresponding to 5 and 1, and not to enable matrix transposition for the original pixel matrix corresponding to 8, a decimal point, and 0.
[0087] The dynamic disturbance parameter can be determined based on the dynamic, random or real-time changing data carried in the item attribute acquisition request. In practical applications, the item attribute acquisition request generally carries a request timestamp, which is used to identify the time when the request was initiated and changes in real time. The dynamic disturbance parameter can be determined based on the request timestamp. For example, the preset bit data of the time identified by the request timestamp can be used as the indication data for the matrix row or column interchange. The preset bits can be, for example, the last two bits or two bits in the middle.
[0088] For example, if the time identified by the request timestamp is 17:51:34, and the attribute value of the target item is 518.00, then the dynamic disruption parameter can be to swap the data of the third column and the fourth column of the original pixel matrix corresponding to each component factor in 518.00, that is, the data of the six original pixel matrices, or to swap the data of the third row and the fourth row. Since the request timestamp is regular data carried in the request, when the dynamic disruption parameter is determined by using the request timestamp, there is no need to modify the request; and since the timestamp is constantly changing, each request will generate different dynamic disruption parameters, thereby increasing the difficulty of decoding and cracking, and preventing replay attacks.
[0089] It should be noted that the above method for determining fixed disturbance parameters and dynamic disturbance parameters is only an example. In actual applications, other methods can be used to determine fixed disturbance parameters and dynamic disturbance parameters. For example, the server can also directly configure which component factors of the attribute value are enabled for matrix transposition, such as enabling matrix transposition for even digits, or directly carrying the row number or column number indicating row or column swapping in the item attribute acquisition request.
[0090] Step 280: Scramble the original pixel matrix according to the scrambling parameter to obtain a scrambled pixel matrix.
[0091] That is, the original pixel matrix is scrambled using two types of parameters, fixed scrambling parameters and dynamic scrambling parameters. In practical applications, the order of using fixed scrambling parameters and dynamic scrambling parameters can be set according to actual needs. Fixed scrambling parameters can be used first, or dynamic scrambling parameters can be used first. For example, taking the number 5 scrambled using fixed scrambling parameters and dynamic scrambling parameters as an example, the scrambling effect can be as follows: Figure 2d As shown, the original pixel matrix corresponding to the number 5 can be scrambled using a fixed scrambling parameter, and the pixel grid corresponding to the scrambled pixel matrix can be as follows: Figure 2d As shown in the middle picture, the scrambled pixel matrix is further scrambled using dynamic scrambling parameters. The corresponding pixel grid after the second scrambling can be shown as Figure 2d Position shown in the picture on the right.
[0092] The use of fixed scrambling parameters has the reproducibility of scrambling results. When the same original pixel matrix is scrambled, the same scrambling result will be generated, which can ensure that the same input will get the same output, making it easier to decode and restore data. The use of dynamic scrambling parameters has randomness and security. By using dynamic scrambling parameters, different scrambling results will be generated each time the original pixel matrix is scrambled, which can increase the complexity and difficulty of scrambling. The cracker must obtain specific scrambling parameters in real time to unlock the scrambled pixel matrix, and cannot rely on fixed scrambling parameters for cracking, which improves the security of the data. By combining fixed scrambling parameters with dynamic scrambling parameters, it is possible to increase the difficulty of cracking and the security of the data while providing a certain degree of reproducibility. In practical applications, fixed scrambling parameters and dynamic scrambling parameters can be used one by one according to actual needs.
[0093] Step 290: Feedback an item attribute acquisition response to the user end, wherein the item attribute acquisition response includes a scrambled pixel matrix, so that the user end determines the attribute value by using the original pixel matrix obtained by descrambling the scrambled pixel matrix.
[0094] The server and the user may pre-agree on the matrix scrambling algorithm used by the server, or may pre-agree on the matrix descrambling algorithm used by the user. After the server feeds back the scrambled pixel matrix to the user, the user may descramble the scrambled pixel matrix according to the pre-agreed algorithm to obtain the original pixel matrix. The user may determine the attribute value of the target object according to the original pixel matrix.
[0095] The scrambling or descrambling rules agreed upon by the server and the user can be changed at any time through configuration. In this way, after the configured rules are crawled, they can respond quickly and change the rules in time, thereby improving the anti-crawl effect of price data.
[0096] In addition, when the user end determines the attribute value according to the original pixel matrix, it can first determine the display parameters of each pixel based on the original pixel matrix. The display parameters of each pixel may include display position, display color, display brightness, etc., and draw a value picture corresponding to the attribute value of the target item according to the display parameters of each pixel, that is, the attribute value picture, to display the attribute value picture of the target item, that is, to display the price of the target item in the form of a picture. In this way, even if the crawler parses the page and creates the page DOM structure, it cannot directly locate the price element and cannot directly extract the price. If you want to extract the price, you need to further parse and identify the price picture, which further improves the anti-crawling effect of the price data.
[0097] The scheme of this embodiment represents the attribute value of the item, such as the commodity price, with a pixel matrix, and scrambles the pixel matrix. The scrambled pixel matrix cannot be restored for illegal platforms and other unauthorized visitors, and has no practical significance. Therefore, even if the illegal platform parses the page content through a crawler to create a DOM structure, it cannot directly obtain the original commodity price data, thereby improving the security of the commodity price data; the pixel matrix corresponding to the commodity price is scrambled and then transmitted, which solves the problem of plain text transmission of price data from the source of the data, and improves the anti-crawling effect of price data; in addition, the present invention uses data scrambling and de-scrambling technology on the server and user ends respectively. This technology is a relatively simple and effective data processing method, which is relatively easy to implement and is compatible with existing systems and processes. It does not require major modifications to the existing system, and the technical implementation is feasible, simple and effective.
[0098] The following describes the method for processing item information provided by the embodiment of the present invention from the perspective of the user end. The user end may be an electronic device such as a mobile phone or a personal computer. The user end may be installed with a shopping platform. Figure 3a The item information processing method of this embodiment may include the following steps:
[0099] Step 310: Send an item attribute acquisition request to the server, where the item attribute acquisition request includes an item identifier of the target item, so that the server acquires the original pixel matrix corresponding to the attribute value of the target item according to the item identifier.
[0100] The user can send an item attribute acquisition request to the server through the shopping platform of the user. The item attribute acquisition request is used to request to obtain the attribute value of the target item from the server. The target item can be any item that the user wants to buy, check the price or pay attention to. The item identifier can be identification information used to distinguish different items or identify the target item. For example, the item identifier can be the item name, item number, item SKU, etc.
[0101] The server can use the preset mapping function to map the attribute value of the target object to obtain the function mapping value corresponding to the attribute value, and grid the shape of the attribute value of the target object according to the pixel to obtain the pixel grid, create the original pixel matrix corresponding to the attribute value according to the characteristics of each pixel in the pixel grid, and store the function mapping value and the original pixel matrix corresponding to the attribute value in the form of a key-value pair. Among them, the key in the key-value pair is the function mapping value corresponding to the attribute value, and the value in the key-value pair is the original pixel matrix corresponding to the attribute value.
[0102] The server uses key-value pairs to store the function mapping values and original pixel matrices corresponding to the attribute values. The corresponding values can be quickly retrieved and accessed through the key later, improving data retrieval efficiency. In addition, using key-value pairs to store the function mapping values and original pixel matrices corresponding to the attribute values is equivalent to converting and encrypting the attribute values of the target item instead of directly storing the original plaintext attribute values, which can protect the data security of the attribute values of the target item.
[0103] After receiving the item attribute acquisition request sent by the user, the server can obtain the function mapping value corresponding to the attribute value of the target item according to the item identifier carried in the item attribute acquisition request, obtain the original pixel matrix according to the function mapping value, scramble the original pixel matrix, and obtain the scrambled pixel matrix. For the specific scrambling process, please refer to the description of the previous embodiment, which will not be repeated here.
[0104] Step 320: Receive an item attribute acquisition response fed back by the server. The item attribute acquisition response includes a scrambled pixel matrix, which is obtained by scrambling the original pixel matrix by the server.
[0105] Step 330: De-scramble the scrambled pixel matrix to obtain an original pixel matrix.
[0106] Specifically, the user terminal may first determine the disturbance parameters, and use the disturbance parameters to perform de-scrambling processing on the scrambled pixel matrix to obtain the original pixel matrix. The disturbance parameters include fixed disturbance parameters and dynamic disturbance parameters. The item attribute acquisition response may include the function mapping value corresponding to the attribute value of the target item, and the fixed disturbance parameters may be determined according to the function mapping value. For example, which matrices in the scrambled pixel matrix group are obtained after transposition may be determined according to the mantissa of the function mapping value, and the determined matrix may be restored. The dynamic disturbance parameters may be obtained from the item attribute acquisition request, and the item attribute acquisition request may include a request timestamp, and the dynamic disturbance parameters may be determined according to the request timestamp. For example, which rows or columns of each matrix in the scrambled pixel matrix group are interchanged may be determined according to the request timestamp, and the determined rows or columns may be restored. In practical applications, the de-scrambling process corresponds to the scrambling process. If the fixed disturbance parameters are used for scrambling first, and then the dynamic disturbance parameters are used for scrambling, then when de-scrambling, the dynamic disturbance parameters may be used for de-scrambling first, and then the fixed disturbance parameters may be used for de-scrambling. The de-scrambling process is equivalent to restoring the matrix.
[0107] Step 340: Determine the attribute value of the target object based on the original pixel matrix.
[0108] Since the attribute value of the target item is generally composed of factors such as numbers and decimal points, each component factor will correspond to an original pixel matrix, so the original pixel matrix group will be obtained after de-interference. The dots per inch (Dots Per Inch, DPI) of the user end or the display size of the attribute value can be obtained, and the display size of the price image can be set according to the DPI of the user end or the display size of the attribute value. After obtaining the original pixel matrix group, for each original pixel matrix in the original pixel matrix group, the display parameters of each pixel can be determined. The display parameters of each pixel may include display position, display color, display brightness, etc., and the value picture corresponding to each original pixel matrix is drawn according to the display parameters of each pixel. After obtaining the value picture corresponding to each original pixel matrix in the original pixel matrix group, the obtained value picture is spliced or fused to obtain the picture corresponding to the attribute value of the target item, that is, the attribute value picture, and the attribute value picture of the target item is displayed.
[0109] Taking the target item's attribute value as 518.00 as an example, the value image generation process can be as follows: Figure 3b As shown. The DPI or price display size of the user end can be obtained, and the width and height of 518.00 can be set according to the DPI or price display size of the user end. For the first component factor 5 in 518.00, after restoring the original pixel matrix corresponding to 5, the display parameters of each pixel in the original pixel matrix corresponding to 5 can be obtained, and the value picture corresponding to the first component factor 5 can be drawn according to the display parameters of each pixel. Similarly, the value pictures corresponding to the remaining component factors can be drawn. Finally, the value pictures corresponding to all component factors in 518.00 are spliced or fused to obtain the price picture corresponding to 518.00.
[0110] The server transmits the product price in plain text, and the product price is displayed in text form on the page. After the crawler crawls the page content and parses the page, it can build the page DOM structure based on the parsing results. Since the product price is displayed in text form, it can directly locate the price element in text form and directly extract the product price.
[0111] This embodiment displays the price of the target item in the form of a picture. In this way, even if the crawler parses the page and creates the page DOM structure, it cannot directly locate the price element and cannot directly extract the price. If you want to extract the price, you need to further parse and identify the price picture, which further improves the anti-crawling effect of the price data.
[0112] The scheme of this embodiment can obtain the commodity price transmitted by using the scrambled pixel matrix, and determine the price of the target item by using the original pixel matrix obtained by descrambling the scrambled pixel matrix. The scrambled pixel matrix cannot be restored by illegal platforms and other unauthorized visitors. Therefore, even if the illegal platform creates a DOM structure by parsing the page content through a crawler, it cannot directly obtain the original commodity price data, thereby improving the security of the commodity price data; the pixel matrix corresponding to the commodity price is scrambled and then transmitted, which solves the problem of plain text transmission of price data from the source of the data and improves the anti-crawling effect of price data; in addition, the present invention uses data scrambling and descrambling technology on the server and the user respectively. This technology is a relatively simple and effective data processing method, which is relatively easy to implement and is compatible with existing systems and processes. It does not require major modifications to the existing system, and the technical implementation is feasible, simple and effective.
[0113] Figure 4 is a schematic diagram of the structure of an item information processing device provided by an embodiment of the present invention. The device can be applied to a server, such as Figure 4 As shown, the device may specifically include:
[0114] The request receiving module 401 is used to receive an item attribute acquisition request sent by a user terminal, wherein the item attribute acquisition request includes an item identifier of a target item;
[0115] An acquisition module 402 is used to acquire an original pixel matrix corresponding to the attribute value of the target object according to the object identification;
[0116] The scrambling module 403 is used to perform scrambling processing on the original pixel matrix to obtain a scrambled pixel matrix;
[0117] The feedback module 404 is used to feed back an item attribute acquisition response to the user terminal, wherein the item attribute acquisition response includes the scrambled pixel matrix, so that the user terminal determines the attribute value by using the original pixel matrix obtained by descrambling the scrambled pixel matrix.
[0118] In one embodiment, the device further includes a preprocessing module, which is used to:
[0119] Mapping the attribute value using a preset mapping function to obtain a function mapping value corresponding to the attribute value;
[0120] The shape of the attribute value is gridded according to pixels to obtain a pixel grid, and an original pixel matrix corresponding to the attribute value is created according to the characteristics of each pixel in the pixel grid;
[0121] The function mapping value and the original pixel matrix corresponding to the attribute value are stored.
[0122] In one embodiment, the preprocessing module stores the function mapping value and the original pixel matrix corresponding to the attribute value, including:
[0123] Store the function mapping value and the original pixel matrix corresponding to the attribute value in the form of key-value pairs;
[0124] The key in the key-value pair is the function mapping value, and the value in the key-value pair is the original pixel matrix.
[0125] In one embodiment, the acquisition module 402 is specifically used for:
[0126] Acquire a function mapping value corresponding to the attribute value according to the item identifier;
[0127] The original pixel matrix is obtained according to the function mapping value.
[0128] In one embodiment, the scrambling module 403 is specifically used for:
[0129] Determine disturbance parameters;
[0130] The original pixel matrix is scrambled according to the scrambling parameters to obtain the scrambled pixel matrix.
[0131] In one embodiment, the item attribute acquisition request also includes a dynamic disturbance parameter, and the scrambling module 403 determines the disturbance parameter, including:
[0132] Determine a fixed disturbance parameter according to the function mapping value;
[0133] Acquire the dynamic disturbance parameter from the item attribute acquisition request;
[0134] The fixed scrambling parameter and the dynamic scrambling parameter are determined as the scrambling parameters.
[0135] Those skilled in the art can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional modules is used as an example for illustration. In actual applications, the above-mentioned functions can be assigned to different functional modules as needed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. The specific working process of the functional modules described above can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.
[0136] The device of this embodiment represents the commodity price with a pixel matrix and scrambles the pixel matrix. The scrambled pixel matrix cannot be restored for illegal platforms and other unauthorized visitors and has no practical significance. Therefore, even if the illegal platform parses the page content through a crawler to create a DOM structure, it cannot directly obtain the original commodity price data, thereby improving the security of the commodity price data; the pixel matrix corresponding to the commodity price is scrambled and then transmitted, which solves the problem of plain text transmission of price data from the source of the data and improves the anti-crawling effect of price data; in addition, the present invention uses data scrambling and de-scrambling technology on the server and user ends respectively. This technology is a relatively simple and effective data processing method, which is relatively easy to implement and is compatible with existing systems and processes. It does not require major modifications to the existing system, and the technical implementation is feasible, simple and effective.
[0137] Figure 5 is another structural diagram of an item information processing device provided by an embodiment of the present invention. The device can be applied to a user terminal, such as Figure 5 As shown, the device may specifically include:
[0138] The sending module 501 is used to send an item attribute acquisition request to a server, wherein the item attribute acquisition request includes an item identifier of a target item, so that the server acquires an original pixel matrix corresponding to an attribute value of the target item according to the item identifier;
[0139] A response receiving module 502 is used to receive an item attribute acquisition response fed back by the server, wherein the item attribute acquisition response includes a scrambled pixel matrix, and the scrambled pixel matrix is obtained by the server scrambling the original pixel matrix;
[0140] A de-scrambling module 503 is used to perform de-scrambling processing on the scrambled pixel matrix to obtain the original pixel matrix;
[0141] The determination module 504 is configured to determine the attribute value based on the original pixel matrix.
[0142] In one embodiment, the de-scrambling module 503 is specifically used for:
[0143] Determine disturbance parameters;
[0144] The scrambled pixel matrix is de-scrambled according to the scrambling parameters to obtain the original pixel matrix.
[0145] In one embodiment, the item attribute acquisition request further includes a dynamic disturbance parameter, the item attribute acquisition response further includes a function mapping value corresponding to the attribute value, the function mapping value is obtained by the server side mapping the attribute value using a preset mapping function, and the de-scrambling module 503 determines the disturbance parameter, including:
[0146] Determine a fixed disturbance parameter according to the function mapping value;
[0147] Acquire the dynamic disturbance parameter from the item attribute acquisition request;
[0148] The fixed scrambling parameter and the dynamic scrambling parameter are determined as the scrambling parameters.
[0149] In one embodiment, the determination module 504 is specifically configured to:
[0150] Determining a display parameter of each pixel based on the original pixel matrix;
[0151] Draw an attribute value picture according to the display parameter of each pixel;
[0152] Displays a picture of the attribute value.
[0153] Those skilled in the art can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional modules is used as an example for illustration. In actual applications, the above-mentioned functions can be assigned to different functional modules as needed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. The specific working process of the functional modules described above can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.
[0154] The device of this embodiment can obtain the commodity price transmitted by using the scrambled pixel matrix, and determine the price of the target item by using the original pixel matrix obtained by descrambling the scrambled pixel matrix. The scrambled pixel matrix cannot be restored for illegal platforms and other unauthorized visitors, and is of no practical significance. Therefore, even if the illegal platform creates a DOM structure by parsing the page content through a crawler, it cannot directly obtain the original commodity price data, thereby improving the security of the commodity price data; the pixel matrix corresponding to the commodity price is scrambled and then transmitted, which solves the problem of plain text transmission of price data from the source of the data, and improves the anti-crawling effect of price data; in addition, the present invention uses data scrambling and descrambling technology on the server and the user respectively. This technology is a relatively simple and effective data processing method, which is relatively easy to implement and is compatible with existing systems and processes. It does not require major modifications to the existing system, and the technical implementation is feasible, simple and effective.
[0155] An embodiment of the present invention further provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the method for processing item information provided in any of the above embodiments is implemented.
[0156] An embodiment of the present invention further provides a computer-readable medium on which a computer program is stored. When the program is executed by a processor, the method for processing item information provided by any of the above embodiments is implemented.
[0157] Figure 6 An exemplary system architecture 600 is shown to which the item information processing method or item information processing device according to the embodiment of the present invention can be applied.
[0158] like Figure 6 As shown, the system architecture 600 may include user terminals 601, 602, 603, a network 604, and a server 605. The network 604 is used to provide a medium for communication links between the user terminals 601, 602, 603, and the server 605. The network 604 may include various connection types, such as wired, wireless communication links, or optical fiber cables.
[0159] The user can use the client 601, 602, 603 to interact with the server 605 through the network 604 to receive or send messages, etc. Various client applications can be installed on the client 601, 602, 603, such as shopping application clients, enterprise application clients, e-commerce application clients, web browser applications, search applications, instant messaging tools, and email clients.
[0160] The user terminals 601 , 602 , and 603 may be various electronic devices having a display screen and supporting various clients, including but not limited to smart phones, tablet computers, laptop computers, desktop computers, and the like.
[0161] The server 605 may be a server that provides various services, such as a backend server that provides support for item attribute acquisition requests sent by users using the user terminals 601, 602, and 603. The backend server may process the received item attribute acquisition requests and feed back the processing results to the user terminals 601, 602, and 603.
[0162] It should be noted that the item information processing method provided in the embodiment of the present invention is executed by the server 605 and the user terminals 601, 602, and 603. The server 605 is mainly used to scramble the pixel matrix representing the attribute value, and the user terminals 601, 602, and 603 are mainly used to descramble and display the scrambled pixel matrix. Accordingly, the item information processing device can be respectively set in the server 605 and the user terminals 601, 602, and 603.
[0163] It should be understood that Figure 6 The number of user terminals, networks, and servers in the figure is only for illustration. Any number of user terminals, networks, and servers may be provided according to implementation requirements.
[0164] Reference below Figure 7 , which shows a schematic diagram of the structure of a computer system 700 of an electronic device suitable for implementing an embodiment of the present invention. Figure 7 The electronic device shown can be a user end or a server end. Figure 7 The electronic device shown is only an example and should not bring any limitation to the function and scope of use of the present invention.
[0165] like Figure 7 As shown, the computer system 700 includes a central processing unit (CPU) 701, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 702 or a program loaded from a storage part 708 into a random access memory (RAM) 703. In the RAM 703, various programs and data required for the operation of the computer system 700 are also stored. The CPU 701, the ROM 702, and the RAM 703 are connected to each other via a bus 704. An input / output (I / O) interface 705 is also connected to the bus 704.
[0166] The following components are connected to the I / O interface 705: an input section 706 including a keyboard, a mouse, etc.; an output section 707 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 708 including a hard disk, etc.; and a communication section 709 including a network interface card such as a LAN card, a modem, etc. The communication section 709 performs communication processing via a network such as the Internet. A drive 710 is also connected to the I / O interface 705 as needed. A removable medium 711, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 710 as needed, so that a computer program read therefrom is installed into the storage section 708 as needed.
[0167] In particular, according to the embodiments disclosed in the present invention, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present invention include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 709, and / or installed from the removable medium 711. When the computer program is executed by the central processing unit (CPU) 701, the above-mentioned functions defined in the system of the present invention are executed.
[0168] It should be noted that the computer-readable medium shown in the present invention may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. 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 of the above. In the present invention, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In the present invention, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, which may 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 medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above.
[0169] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present invention. In this regard, each box in the flow chart or block diagram can represent a module, a program segment, or a part of a code, and the above-mentioned module, program segment, or a part of a code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flow chart, and the combination of the boxes in the block diagram or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0170] The modules and / or units involved in the description of the present invention may be implemented by software or hardware. The modules and / or units described may also be arranged in a processor, for example, may be described as: a processor includes a request receiving module, an acquisition module, an scrambling module and a feedback module. Or may be described as: a processor includes a sending module, a response receiving module, a descrambling module and a determination module. Among them, the names of these modules do not constitute a limitation on the modules themselves in some cases.
[0171] As another aspect, the present invention further provides a computer-readable medium, which may be included in the device described in the above embodiment; or may exist independently without being assembled into the device. The above computer-readable medium carries one or more programs, and when the above one or more programs are executed by a device, the device includes:
[0172] Receive an item attribute acquisition request sent by a user terminal, wherein the item attribute acquisition request includes an item identifier of a target item; acquire an original pixel matrix corresponding to an attribute value of the target item according to the item identifier; scramble the original pixel matrix to obtain a scrambled pixel matrix; and feed back an item attribute acquisition response to the user terminal, wherein the item attribute acquisition response includes the scrambled pixel matrix, so that the user terminal determines the attribute value by using the original pixel matrix obtained by descrambling the scrambled pixel matrix.
[0173] Alternatively, when the above one or more programs are executed by a device, the device includes:
[0174] Sending an item attribute acquisition request to a server, wherein the item attribute acquisition request includes an item identifier of a target item, so that the server acquires an original pixel matrix corresponding to an attribute value of the target item according to the item identifier; receiving an item attribute acquisition response fed back by the server, wherein the item attribute acquisition response includes a scrambled pixel matrix, wherein the scrambled pixel matrix is obtained by scrambling the original pixel matrix by the server; performing descrambling processing on the scrambled pixel matrix to obtain the original pixel matrix; and determining the attribute value based on the original pixel matrix.
[0175] The scheme of the embodiment of the present invention represents the attribute value of the item, such as the commodity price, with a pixel matrix, and scrambles the pixel matrix. The scrambled pixel matrix cannot be restored for illegal platforms and other unauthorized visitors, and has no practical significance. Therefore, even if the illegal platform parses the page content through a crawler to create a DOM structure, it cannot directly obtain the original commodity price data, thereby improving the security of the commodity price data; the pixel matrix corresponding to the commodity price is scrambled and then transmitted, which solves the problem of plain text transmission of price data from the source of the data, and improves the anti-crawling effect of price data; in addition, the present invention uses data scrambling and de-scrambling technology on the server and user ends respectively. This technology is a relatively simple and effective data processing method, which is relatively easy to implement and is compatible with existing systems and processes. It does not require major modifications to the existing system, and the technical implementation is feasible, simple and effective.
[0176] It should be understood that the various forms of processes shown above can be used to reorder, add or delete steps. For example, the steps described in the present invention can be executed in parallel, sequentially or in different orders, as long as the desired results of the technical solution of the present invention can be achieved, and this document does not limit this.
[0177] It should be noted that the collection, collection, updating, analysis, processing, use, transmission, storage and other aspects of user personal information involved in the technical solution of this disclosure are in compliance with the provisions of relevant laws and regulations, are used for legitimate purposes, and do not violate public order and good morals. Necessary measures are taken for user personal information to prevent illegal access to user personal information data and maintain the security of user personal information, network security and national security.
[0178] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may occur depending on design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A method for processing item information, characterized in that: include: Receiving an item attribute acquisition request sent by a user terminal, wherein the item attribute acquisition request includes an item identifier of a target item; Acquire an original pixel matrix corresponding to the attribute value of the target object according to the object identification; Performing scrambling processing on the original pixel matrix to obtain a scrambled pixel matrix; Feedback an item attribute acquisition response to the user terminal, wherein the item attribute acquisition response includes the scrambled pixel matrix, so that the user terminal determines the attribute value by using the original pixel matrix obtained by descrambling the scrambled pixel matrix.
2. The method for processing item information according to claim 1, characterized in that: Before receiving the item attribute acquisition request sent by the user, it also includes: Mapping the attribute value using a preset mapping function to obtain a function mapping value corresponding to the attribute value; The shape of the attribute value is gridded according to pixels to obtain a pixel grid, and an original pixel matrix corresponding to the attribute value is created according to the characteristics of each pixel in the pixel grid; The function mapping value and the original pixel matrix corresponding to the attribute value are stored.
3. The method for processing item information according to claim 2, characterized in that: The storing of the function mapping value and the original pixel matrix corresponding to the attribute value includes: Store the function mapping value and the original pixel matrix corresponding to the attribute value in the form of key-value pairs; The key in the key-value pair is the function mapping value, and the value in the key-value pair is the original pixel matrix.
4. The method for processing item information according to claim 3, characterized in that: The step of obtaining the original pixel matrix corresponding to the attribute value of the target object according to the object identification includes: Acquire a function mapping value corresponding to the attribute value according to the item identifier; The original pixel matrix is obtained according to the function mapping value.
5. The method for processing item information according to any one of claims 2 to 4, characterized in that: The scrambling process is performed on the original pixel matrix to obtain a scrambled pixel matrix, including: Determine disturbance parameters; The original pixel matrix is scrambled according to the scrambling parameters to obtain the scrambled pixel matrix.
6. The method for processing item information according to claim 5, characterized in that: The item attribute acquisition request also includes a dynamic disturbance parameter, and the determination of the disturbance parameter includes: Determine a fixed disturbance parameter according to the function mapping value; Acquire the dynamic disturbance parameter from the item attribute acquisition request; The fixed scrambling parameter and the dynamic scrambling parameter are determined as the scrambling parameters.
7. A method for processing item information, characterized in that: include: Sending an item attribute acquisition request to a server, wherein the item attribute acquisition request includes an item identifier of a target item, so that the server acquires an original pixel matrix corresponding to an attribute value of the target item according to the item identifier; receiving an item attribute acquisition response fed back by the server, wherein the item attribute acquisition response includes a scrambled pixel matrix, and the scrambled pixel matrix is obtained by scrambling the original pixel matrix by the server; Performing descrambling processing on the scrambled pixel matrix to obtain the original pixel matrix; The property value is determined based on the original pixel matrix.
8. The method for processing item information according to claim 7, characterized in that: The descrambling the scrambled pixel matrix to obtain the original pixel matrix includes: Determine disturbance parameters; The scrambled pixel matrix is de-scrambled according to the scrambling parameters to obtain the original pixel matrix.
9. The method for processing item information according to claim 8, characterized in that: The item attribute acquisition request also includes a dynamic disturbance parameter, and the item attribute acquisition response also includes a function mapping value corresponding to the attribute value, wherein the function mapping value is obtained by the server side mapping the attribute value using a preset mapping function, and the determining of the disturbance parameter includes: Determine a fixed disturbance parameter according to the function mapping value; Acquire the dynamic disturbance parameter from the item attribute acquisition request; The fixed scrambling parameter and the dynamic scrambling parameter are determined as the scrambling parameters.
10. The method for processing item information according to any one of claims 7 to 9, characterized in that: The determining the attribute value based on the original pixel matrix comprises: Determining a display parameter of each pixel based on the original pixel matrix; Draw an attribute value picture according to the display parameter of each pixel; Displays a picture of the attribute value.
11. An item information processing device, characterized in that: include: A request receiving module, used to receive an item attribute acquisition request sent by a user terminal, wherein the item attribute acquisition request includes an item identifier of a target item; An acquisition module, used for acquiring an original pixel matrix corresponding to the attribute value of the target object according to the object identification; A scrambling module, used for performing scrambling processing on the original pixel matrix to obtain a scrambled pixel matrix; A feedback module is used to feed back an item attribute acquisition response to the user terminal, wherein the item attribute acquisition response includes the scrambled pixel matrix, so that the user terminal determines the attribute value by using the original pixel matrix obtained by descrambling the scrambled pixel matrix.
12. An item information processing device, characterized in that: include: A sending module, configured to send an item attribute acquisition request to a server, wherein the item attribute acquisition request includes an item identifier of a target item, so that the server acquires an original pixel matrix corresponding to an attribute value of the target item according to the item identifier; a response receiving module, configured to receive an item attribute acquisition response fed back by the server, wherein the item attribute acquisition response includes a scrambled pixel matrix, and the scrambled pixel matrix is obtained by scrambling the original pixel matrix by the server; A descrambling module, used for performing descrambling processing on the scrambled pixel matrix to obtain the original pixel matrix; A determination module is used to determine the attribute value based on the original pixel matrix.
13. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the program, the item information processing method according to any one of claims 1 to 6 is implemented, or when the processor executes the program, the item information processing method according to any one of claims 7 to 10 is implemented.
14. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the item information processing method according to any one of claims 1 to 6 is implemented, or when the program is executed by a processor, the item information processing method according to any one of claims 7 to 10 is implemented.
