Disclosure of Invention
Therefore, the embodiment of the invention provides a resource data page identification method based on a uniform resource locator, so as to solve the problem that the security of accessing resource data based on a browser is poor due to the lack of a protection mechanism when the browser is used for accessing internal resource data in the prior art.
In order to achieve the above object, the embodiments of the present invention provide the following technical solutions:
in a first aspect, an embodiment of the present invention provides a method for identifying a resource data page based on a uniform resource locator, including: configuring a uniform resource locator information list corresponding to resource data needing to be added with watermarks in a background server of a browser in advance; when a user accesses target resource data through the browser, target uniform resource locator information corresponding to the target resource data is obtained; and matching the target uniform resource locator information with uniform resource locator information in the uniform resource locator information list, and covering the target watermark in an access webpage corresponding to the target resource data if the matching is successful.
Further, the method for identifying a resource data page based on a uniform resource locator further includes: presetting configuration options of watermark information through the background server; and receiving the setting request information aiming at the watermark, which is sent by the user based on the configuration option, and configuring the content and the attribute of the watermark according to the setting request information to obtain the target watermark.
Further, the configuration options include: at least one of a watermark content option, a watermark size option, a watermark color option, and a watermark transparency option.
Further, the configuring, in advance, a uniform resource locator information list corresponding to the resource data to be watermarked in the background server of the browser specifically includes: determining resource data needing to be added with watermarks; and acquiring the uniform resource locator information corresponding to the resource data to be watermarked according to the resource data to be watermarked and a preset mapping relation, integrating the uniform resource locator information into a uniform resource locator information list, and performing pre-configuration in a background server of the browser.
Further, the watermark content option includes at least one of a name option, a mobile phone number option, a mailbox option and a time option.
Further, the resource data includes at least one of text data, picture data, and image data.
Further, the method for identifying a resource data page based on a uniform resource locator further includes: and pre-storing the uniform resource locator information list into a database.
In a second aspect, an embodiment of the present invention further provides a device for identifying a resource data page based on a uniform resource locator, where the device includes: the background configuration unit is used for configuring a uniform resource locator information list corresponding to the resource data needing to be added with the watermark in a background server of the browser in advance; the resource locator information acquisition unit is used for acquiring target uniform resource locator information corresponding to target resource data when a user accesses the target resource data through the browser; and the watermark setting unit is used for matching the target uniform resource locator information with the uniform resource locator information in the uniform resource locator information list, and if the matching is successful, covering the target watermark in the access webpage corresponding to the target resource data.
Further, the apparatus for identifying a resource data page based on a uniform resource locator further includes: the configuration option unit is used for presetting configuration options of watermark information through the background server; and the watermark setting unit is used for receiving the setting request information aiming at the watermark, which is sent by the user based on the configuration options, and configuring the content and the attribute of the watermark according to the setting request information to obtain the target watermark.
Further, the configuration options include: at least one of a watermark content option, a watermark size option, a watermark color option, and a watermark transparency option.
Further, the background configuration unit is specifically configured to: determining resource data needing to be added with watermarks; and acquiring the uniform resource locator information corresponding to the resource data to be watermarked according to the resource data to be watermarked and a preset mapping relation, integrating the uniform resource locator information into a uniform resource locator information list, and performing pre-configuration in a background server of the browser.
Further, the watermark content option includes at least one of a name option, a mobile phone number option, a mailbox option and a time option.
Further, the resource data includes at least one of text data, picture data, and image data.
Further, the apparatus for identifying a resource data page based on a uniform resource locator further includes: and the storage unit is used for pre-storing the uniform resource locator information list into a database.
In a third aspect, an embodiment of the present invention further provides an electronic device, including: a processor and a memory; the memory is configured to store a program of a uniform resource locator-based resource data page identification method, and after the electronic device is powered on and runs the program of the uniform resource locator-based resource data page identification method through the processor, the electronic device executes any one of the above-mentioned uniform resource locator-based resource data page identification methods.
In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium, where the computer-readable storage medium contains one or more program instructions, where the one or more program instructions are used for a server to execute any one of the above methods for identifying a page of resource data based on a uniform resource locator.
By adopting the resource data page identification method based on the uniform resource locator, the watermark can be set on the webpage of the resource data accessed by the browser based on the uniform resource locator, and the risk that important file resource data are copied and stolen is avoided, so that the safety of accessing the resource data based on the browser is improved, and the use experience of a user is improved.
Detailed Description
The present invention is described in terms of particular embodiments, other advantages and features of the invention will become apparent to those skilled in the art from the following disclosure, and it is to be understood that the described embodiments are merely exemplary of the invention and that it is not intended to limit the invention to the particular embodiments disclosed. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The following describes an embodiment of the method for identifying a resource data page based on a uniform resource locator according to the present invention in detail. As shown in fig. 1, which is a flowchart of a method for identifying a resource data page based on a uniform resource locator according to an embodiment of the present invention, a specific implementation process includes the following steps:
step S101: and configuring a uniform resource locator information list corresponding to the resource data needing to be added with the watermark in a background server of the browser in advance.
In the embodiment of the present invention, the uniform resource locator information (URL) is a representation manner for specifying a resource data location, and may also refer to a web page address of a web page bearing the resource data in a browser. The resource data includes text data, picture data, image data, and the like.
In this step, a uniform resource locator information list corresponding to the resource data to be watermarked can be preconfigured through a background server of the browser, and stored in the database as a basis for judging whether to add the watermark.
The method is characterized in that a uniform resource locator information list corresponding to resource data needing to be added with watermarks is configured in a background server of the browser in advance, and the method can be specifically realized in the following way: firstly, determining resource data needing to be added with a watermark; further, according to the resource data to be watermarked and a preset mapping relationship, the uniform resource locator information corresponding to the resource data to be watermarked is obtained, the uniform resource locator information is integrated into a uniform resource locator information list, and the uniform resource locator information is configured in advance in a background server of the browser.
Step S102: and when a user accesses target resource data through the browser, acquiring target uniform resource locator information corresponding to the target resource data.
After the list of uniform resource locator information corresponding to the resource data to be watermarked is configured in step S101, in this step, the actual uniform resource locator information (i.e., target uniform resource locator information) corresponding to the target resource data may be accessed by identifying the browser.
Step S103: and matching the target uniform resource locator information with uniform resource locator information in the uniform resource locator information list, and covering the target watermark in an access webpage corresponding to the target resource data if the matching is successful.
After the target uniform resource locator information corresponding to the target resource data is acquired in step S102, it is determined in this step whether the target uniform resource locator information is located in a list, and if so, a preset target watermark is covered in an access webpage corresponding to the target resource data.
In the embodiment of the invention, the configuration options of the watermark information can be preset through the background server; and when receiving the setting request information aiming at the watermark, which is sent by the user based on the configuration option, configuring the content and the attribute of the watermark according to the setting request information to obtain the target watermark. The configuration options may include setting functions such as a watermark content option, a watermark size option, a watermark color option, and a watermark transparency option. The watermark content option includes a name option, a mobile phone number option, a mailbox option, a time option, and the like, which is not specifically limited herein.
In addition, when different web pages are switched through the browser, the uniform resource locators corresponding to the different web pages can be identified, and the watermark information can be added into the web pages according to the identification result and the requirements, the watermark information can be configured through a background, and the configurable watermark information comprises the specific content, the size and the dimension of the watermark display, the color and the transparency of the watermark and the like.
By adopting the resource data page identification method based on the uniform resource locator, the watermark can be set on the webpage of the resource data accessed by the browser based on the uniform resource locator, and the risk that important file resource data are copied and stolen is avoided, so that the safety of accessing the resource data based on the browser is improved, and the use experience of a user is improved.
Corresponding to the method for identifying the resource data page based on the uniform resource locator, the invention also provides a device for identifying the resource data page based on the uniform resource locator. Since the embodiment of the apparatus is similar to the above method embodiment, the description is simple, and please refer to the description of the above method embodiment, and the following embodiments of the apparatus for identifying a resource data page based on a uniform resource locator are only exemplary. Please refer to fig. 2, which is a schematic diagram of a resource data page identifier apparatus based on uniform resource locators according to an embodiment of the present invention.
The invention relates to a resource data page identification device based on uniform resource locators, which comprises the following parts:
a background configuration unit 201, configured to configure a uniform resource locator information list corresponding to resource data that needs to be watermarked in a background server of the browser in advance.
In the embodiment of the present invention, the uniform resource locator information (URL) is a representation manner for specifying a resource data location, and may also refer to a web page address of a web page bearing the resource data in a browser. The resource data includes text data, picture data, image data, and the like.
In the background configuration unit 201, a uniform resource locator information list corresponding to the resource data to be watermarked may be configured in advance through a background server of the browser, and stored in a database as a basis for determining whether to add a watermark. The method is characterized in that a uniform resource locator information list corresponding to resource data needing to be added with watermarks is configured in a background server of the browser in advance, and the method can be specifically realized in the following way: firstly, determining resource data needing to be added with a watermark; further, according to the resource data to be watermarked and a preset mapping relationship, the uniform resource locator information corresponding to the resource data to be watermarked is obtained, the uniform resource locator information is integrated into a uniform resource locator information list, and the uniform resource locator information is configured in advance in a background server of the browser.
A resource locator information obtaining unit 202, configured to obtain target uniform resource locator information corresponding to target resource data when a user accesses the target resource data through the browser.
After the uniform resource locator information list corresponding to the resource data to be watermarked is configured in the background configuration unit 201, in this step, the actual uniform resource locator information (i.e. the target uniform resource locator information) corresponding to the target resource data can be accessed by identifying the browser.
And the watermark setting unit 203 is configured to match the target uniform resource locator information with uniform resource locator information in the uniform resource locator information list, and if matching is successful, cover the target watermark in an access webpage corresponding to the target resource data.
After the resource locator information obtaining unit 202 obtains the target uniform resource locator information corresponding to the target resource data, the watermark setting unit 203 determines whether the target uniform resource locator information is located in the list, and if so, covers a preset target watermark in an access webpage corresponding to the target resource data.
In the embodiment of the invention, the configuration options of the watermark information can be preset through the background server; and when receiving the setting request information aiming at the watermark, which is sent by the user based on the configuration option, configuring the content and the attribute of the watermark according to the setting request information to obtain the target watermark. The configuration options may include setting functions such as a watermark content option, a watermark size option, a watermark color option, and a watermark transparency option. The watermark content option includes a name option, a mobile phone number option, a mailbox option, a time option, and the like, which is not specifically limited herein.
In addition, when different web pages are switched through the browser, the uniform resource locators corresponding to the different web pages can be identified, and the watermark information can be added into the web pages according to the identification result and the requirements, the watermark information can be configured through a background, and the configurable watermark information comprises the specific content, the size and the dimension of the watermark display, the color and the transparency of the watermark and the like.
By adopting the resource data page identification device based on the uniform resource locator, the watermark can be set on the webpage of the resource data accessed by the browser based on the uniform resource locator, so that the risk of copying and stealing important file resource data is avoided, the safety of accessing the resource data based on the browser is improved, and the use experience of a user is improved.
Corresponding to the method for identifying the resource data page based on the uniform resource locator, the invention also provides electronic equipment. Since the embodiment of the electronic device is similar to the above method embodiment, the description is relatively simple, and please refer to the description of the above method embodiment, and the electronic device described below is only schematic. Fig. 3 is a schematic view of an electronic device according to an embodiment of the present invention.
The electronic device specifically includes: a processor 301 and a memory 302; the memory 302 is configured to run one or more program instructions, and is configured to store a program of a uniform resource locator-based resource data page identification method, and after the server is powered on and runs the program of the uniform resource locator-based resource data page identification method through the processor 301, the server executes any one of the above-mentioned uniform resource locator-based resource data page identification methods. The electronic device can be a background server corresponding to the browser.
Corresponding to the method for identifying the resource data page based on the uniform resource locator, the invention also provides a computer storage medium. Since the embodiment of the computer storage medium is similar to the above method embodiment, the description is simple, and please refer to the description of the above method embodiment, and the computer storage medium described below is only schematic.
The computer storage medium contains one or more program instructions for execution by a server of the above-described method for uniform resource locator-based resource data page identification. The server can be a background server corresponding to the browser, and personalized configuration can be realized according to user requirements.
In an embodiment of the invention, the processor or processor module may be an integrated circuit chip having signal processing capabilities. The Processor may be a general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic device, discrete hardware component.
The various methods, steps and logic blocks disclosed in the embodiments of the present invention may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of the method disclosed in connection with the embodiments of the present invention may be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software module may be located in ram, flash memory, rom, prom, or eprom, registers, etc. storage media as is well known in the art. The processor reads the information in the storage medium and completes the steps of the method in combination with the hardware.
The storage medium may be a memory, for example, which may be volatile memory or nonvolatile memory, or which may include both volatile and nonvolatile memory.
The nonvolatile Memory may be a Read-Only Memory (ROM), a Programmable ROM (PROM), an Erasable PROM (EPROM), an Electrically Erasable PROM (EEPROM), or a flash Memory.
The volatile Memory may be a Random Access Memory (RAM) which serves as an external cache. By way of example and not limitation, many forms of RAM are available, such as Static random access memory (Static RAM, SRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), Double Data Rate SDRAM (ddr Data Rate SDRAM), Enhanced SDRAM (ESDRAM), synclink DRAM (SLDRAM), and Direct memory bus RAM (DRRAM).
The storage media described in connection with the embodiments of the invention are intended to comprise, without being limited to, these and any other suitable types of memory.
Those skilled in the art will appreciate that the functionality described in the present invention may be implemented in a combination of hardware and software in one or more of the examples described above. When software is applied, the corresponding functionality may be stored on or transmitted over as one or more instructions or code on a computer-readable medium. Computer-readable media includes both computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another. A storage media may be any available media that can be accessed by a general purpose or special purpose computer.
The above-mentioned embodiments, objects, technical solutions and advantages of the present invention are further described in detail, it should be understood that the above-mentioned embodiments are only exemplary embodiments of the present invention, and are not intended to limit the scope of the present invention, and any modifications, equivalent substitutions, improvements and the like made on the basis of the technical solutions of the present invention should be included in the scope of the present invention.