Attack recognition method
By identifying the document target in the target and detecting whether it contains a face target, it is directly judged as a document attack, and solving the problem of low-efficiency identification of document attacks in the prior art, achieving more efficient and accurate attack recognition.
Patent Information
- Application Number
- CN202210557455.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-20
- Publication Date
- 2025-06-27
- Estimated Expiration
- 2042-05-20
AI Technical Summary
The existing live detection technology is vulnerable to document attacks and cannot effectively identify document attacks, resulting in the attacker passing identity verification.
By identifying the document target in the target and directly determining it as a document attack when there is a face target in the document target, document recognition is preferred rather than facial recognition to avoid environmental interference.
It improves the recognition efficiency and accuracy of document attacks and avoids the impact of environmental interference on the recognition results.
Smart Images

Figure CN114999004B_ABST
Abstract
Description
Technical Field
[0001] One or more embodiments of this specification relate to the field of live detection technology, and in particular, to a method for attack recognition. Background Art
[0002] In the scenario of authentication, face recognition is required to determine whether the face in the captured target image matches the user information. In some authentication scenarios, live detection is also required to distinguish whether the target image is a real face or a forged face attack through the real physiological characteristics of the object in the image. The live detection technology widely used in commercial scenarios is vulnerable to a type of attack - document attack, that is, by placing the attacker's real person and a document with the photo of the attacked user in the same picture. Since the current live detection algorithm only detects and selects one face for live judgment, when the attacker's real person and the document are in the same picture, the live detection algorithm may misselect the real face for live detection, resulting in a successful live detection authentication, thus breaking through the defense of the live detection algorithm; and the face recognition algorithm that cooperates with the live detection algorithm for authentication may select the user photo on the document as the recognition object, so that the user photo matches the user information, resulting in the attacker passing the authentication. Therefore, how to identify the above types of attacks is an urgent problem to be solved.
[0003] In the prior art, most identify document attacks by performing global face recognition on the target and then performing live detection on each face target in turn when there are multiple face targets in the target. Although this method can defend against the above types of attacks, it is vulnerable to interference from other images in the environment, cannot correctly judge the type of attack, and requires live detection on each face target, resulting in low efficiency in identifying attacks. Summary of the Invention
[0004] In view of this, one or more embodiments of this specification provide a method for identifying attacks.
[0005] To achieve the above object, one or more embodiments of this specification provide the following technical solutions:
[0006] According to a first aspect of one or more embodiments of this specification, a method for identifying attacks is proposed, including:
[0007] When receiving a request for live detection and face recognition of a target, identify the document target included in the target;
[0008] Detect whether there is a face target in the document target;
[0009] When there is a face target in the document target, determine that the target is a document attack.
[0010] According to a second aspect of one or more embodiments of the present specification, there is provided a computer-readable storage medium having a computer program stored thereon, and when the program is executed by a processor, the steps of the method described in the first aspect are implemented.
[0011] According to a third aspect of one or more embodiments of the present specification, there is provided an electronic device including a memory, a processor, and a computer program stored on the memory and executable on the processor, and when the processor executes the program, the steps of the method described in the first aspect are implemented.
[0012] In the technical solution provided in the present specification, by identifying a document target in a target and directly determining that the above target is a document attack image when the document target includes a face target, the document attack image can be preferentially identified and processed, and document recognition is performed first instead of directly performing face recognition, which can avoid the influence of the environment on the recognition result and improve the efficiency and accuracy of attack recognition. BRIEF DESCRIPTION OF THE DRAWINGS
[0013] Figure 1 is a schematic structural diagram of an attack recognition device provided by an exemplary embodiment of the present specification;
[0014] Figure 2 is a schematic flowchart of an attack recognition method provided by an exemplary embodiment of the present specification;
[0015] Figure 3 is a schematic diagram of a target image provided by an exemplary embodiment of the present specification;
[0016] Figure 4 is another schematic diagram of a target image provided by an exemplary embodiment of the present specification;
[0017] Figure 5 is a schematic structural diagram of an electronic device provided by an exemplary embodiment of the present specification;
[0018] Figure 6 is a schematic diagram of an attack recognition device provided by an exemplary embodiment of the present specification. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0019] Here, the exemplary embodiments will be described in detail, and the examples are shown in the drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with one or more embodiments of the present specification. On the contrary, they are merely examples of devices and methods consistent with some aspects of one or more embodiments of the present specification as detailed in the appended claims.
[0020] It should be noted that: in other embodiments, the steps of the corresponding method are not necessarily executed in the order shown and described in this specification. In some other embodiments, the steps included in the method may be more or less than those described in this specification. In addition, a single step described in this specification may be decomposed into multiple steps for description in other embodiments; and multiple steps described in this specification may also be combined into a single step for description in other embodiments.
[0021] The live detection technology is a technology for determining the true physiological characteristics of an object in some authentication scenarios. The existing live detection technologies mainly include two categories: one is the cooperative live detection technology, which means that during the authentication process, through the user's cooperation to perform combined actions such as blinking, opening the mouth, shaking the head, nodding, etc., and using technologies such as face key point positioning and face tracking to verify whether the user is a real live body; the other is the silent live detection technology. With the support of this technology, the user does not need to perform the above actions, and the silent live detection technology can directly distinguish whether the image is a live body.
[0022] The live detection technology uses a live detection algorithm to distinguish whether the captured image is a real human face or a forged face attack. All human faces presented through other media can be judged as face attacks. For example, printed paper photos, face images or videos displayed on the display screen of electronic products, silicone masks, three-dimensional 3D portraits, and photos or videos obtained through AI face-swapping technology, etc., all belong to the category of face attacks. And since the document with a photo contains both the identity information of the owner of the document and the photo of the owner of the document, such documents are often used as tools to attack the live detection technology and break through the algorithm defense of the live detection technology.
[0023] Whether it is a silent liveness detection technology or a cooperative liveness detection technology, the liveness detection technology will only select one face for liveness detection. As long as the document is held by a real person, or in other forms, the document and the real person are simultaneously in the target image where liveness detection will be performed. Since the liveness detection algorithm will only select one face in the image for liveness detection, there is a certain probability that the liveness detection algorithm will take the face of the real person as the detection target for detection, thereby determining that the image is a live image, enabling the image to pass the liveness detection and breaking through the defense of the liveness detection algorithm. Since the liveness detection technology has the ability to identify forged faces, the liveness detection technology generally works in conjunction with the face recognition technology to detect whether the image is a forged face attack through the liveness detection technology, and verify whether the face in the image matches the user information through the face recognition technology, so as to achieve double protection. Once the defense of the liveness detection algorithm is broken, since there is still a face target in the document in the image, when face recognition is performed, it may directly compare the face target on the document with the user information stored in the database, resulting in the picture passing the face recognition detection, causing adverse consequences such as the leakage of the holder's personal information or property losses. Therefore, how to identify document attacks is an urgent problem to be solved.
[0024] In the prior art, face recognition is mostly performed on the entire target image. When there are multiple face targets in the image, liveness detection is then performed on each face target in turn. Although this method can defend against the above types of attacks, it is vulnerable to interference from other images in the environment, and liveness detection needs to be performed on each face target, so the efficiency of identifying attacks is low.
[0025] To solve the above problems and further improve the recognition efficiency for document attacks, this specification proposes a method for identifying attacks. By first identifying the document target in the recognition target and directly determining that the target is a document attack when the document target includes a face target, the document attack can be identified and processed preferentially, and document recognition is performed first instead of face recognition, which can avoid the influence of the environment on the recognition result and improve the efficiency of identifying document attacks.
[0026] The method for identifying attacks proposed in this specification is introduced below. Please refer to Figure 1 , Figure 1 which is a schematic diagram of the architecture of an attack recognition system shown in an exemplary embodiment of this specification.
[0027] As Figure 1 shown, the attack recognition system may include: a server 11, a network 12, and at least one terminal 13.
[0028] Among them, the server 11 can be a physical server including an independent host, or the server 11 can be a virtual server hosted by a host cluster. During operation, the server 11 can be configured with a device for identifying attacks, which can be implemented in software and / or hardware to provide attack identification services. According to the target sent by the terminal 13 for liveness detection and face recognition requests, the target is identified for attacks. By identifying the document target in the target and detecting whether there is a face target in the document target, it is determined whether the target is a document attack.
[0029] The terminal 13 refers to an electronic device that can be used by a user and can initiate requests for liveness detection and face recognition for a target. The above-mentioned electronic device can specifically be a mobile phone, a desktop computer, a tablet device, a laptop computer, or a personal digital assistant (PDA), a wearable device (such as smart glasses, VR glasses, etc.), etc. One or more embodiments of this specification do not limit this. The terminal 13 can be equipped with an image acquisition device for acquiring the target for liveness detection and face recognition, or the terminal 13 can also receive the target collected by other devices through a communication connection, or obtain the image of the target by other means. This specification does not make specific limitations on this.
[0030] For the network 12 for interaction between the server 11 and the terminal 13, it can include various types of wired or wireless networks.
[0031] In an exemplary embodiment of this specification, the above-mentioned attack recognition system may not include the server 11 and the network 12, and only the terminal 13 performs offline attack recognition. Specifically, the terminal 13 can also be configured with a device for identifying attacks, which can be implemented in software and / or hardware to provide attack identification services. According to the target sent by the terminal 13 for liveness detection and face recognition requests, the target is identified for attacks. By identifying the document target in the target and detecting whether there is a face target in the document target, it is determined whether the target is a document attack.
[0032] In an exemplary embodiment of this specification, the above-mentioned attack recognition system can be an independent system independent of the identity authentication system for performing attack recognition. Of course, the above-mentioned attack recognition system can also be a part of the identity authentication system and cooperate with the identity authentication system to perform identity authentication through faces. Among them, the process of identity authentication mainly includes liveness detection and face recognition.
[0033] Next, in combination with Figure 2 , a method for identifying attacks provided by this specification will be described. Among them, Figure 2It is a schematic flowchart of a method for identifying an attack provided by an exemplary embodiment. As Figure 2 shown, the method may include the following steps:
[0034] S201, when receiving a request for live detection and face recognition of a target, identify the document target included in the target.
[0035] In an exemplary embodiment provided in this specification, it is assumed that when performing identity verification, the following two steps are required: First, perform live detection to determine whether the face target in the image is a real person. When it is determined to be a real person, enter the face recognition link, and compare the face target in the image with the user information stored in the database to complete the identity verification.
[0036] As Figure 3 shown, it is assumed that there is a user A holding the document of user B and attempting to access the account of user B using a terminal device. When accessing the account of user B, the identity verification as described above is required. Among them, there is a photo of user B on the document, and the terminal device has an image acquisition device that can acquire images for identity verification.
[0037] After the terminal device acquires the image of user A holding the document of user B, it uses this image as a target to initiate a request for live detection and face recognition of this target. Among them, the target is as Figure 3 shown in target 31. When receiving a request for live detection and face recognition of target 31, identify the document target included in target 31. This document target is the document of user B. It is assumed that the document target is as Figure 3 shown in document target 311.
[0038] In an exemplary embodiment of this specification, the above-mentioned document may include any document with a user photo, such as: one or more of a driver's license, an ID card, a passport, a student ID card, etc. There is no specific limitation in this specification.
[0039] In an exemplary embodiment of this specification, the above terminal device may be a terminal device for personal use such as a personal computer or a mobile phone; it may also be other terminal devices that perform identity verification through faces, such as: turnstiles or access control systems, vending machines with face recognition payment functions, ticket verification systems in tourist attractions, etc. The above terminal device may have an image acquisition device for acquiring images and initiating a liveness detection and face recognition request for the acquired images, or may receive the images acquired by other devices through a communication connection and initiate a liveness detection and face recognition request for the received images as target images. Among them, the communication connection may include connections through various types of wired or wireless networks, and may also include Bluetooth connection, infrared connection, or NFC (Near Field Communication) connection. Of course, the above terminal device may also obtain target images through other means, and this specification does not make specific limitations in this regard. In addition, the images may be in the form of real-time videos, dynamic pictures, static pictures, etc., and different types of images may be selected as the objects for recognition attacks according to different application scenarios, and this specification does not make specific limitations in this regard.
[0040] In an exemplary embodiment of this specification, the specific process of identifying the document target included in the recognition target may be completed through the following steps:
[0041] First, input the image of the target into a pre-trained document target detection model. Among them, the document target detection model is a model pre-trained for a certain type of document and can identify whether there is a document target of the corresponding type in the image. When any image is input into the document target detection model, it can be determined whether there is a document target of the document type targeted by the target detection model in the image according to the output result. Among them, the type of the document may be one or more.
[0042] Then, according to the output result of the document target detection model, determine whether the input image contains a document target.
[0043] For example, assume that Figure 3 in the image of target 31 as shown, the document target 311 included is an ID card. Then, input the image of target 31 as shown Figure 3 into the document target detection model pre-trained for ID cards, and according to the output result of the document target detection model, determine that the image of target 31 contains an ID card target - document target 311.
[0044] After identifying the document target included in the image, enter step S202.
[0045] S202, detect whether there is a face target in the document target.
[0046] In an exemplary embodiment of this specification, detecting whether there is a face target in a document target may include the following steps:
[0047] First, obtain the position coordinates of the document target. For example, as Figure 3 shown, obtain the position coordinates of document target 311; then extract the document target 311 according to the position coordinates; finally, detect whether there is a face target in the extracted document target 311. By separately extracting the document target and only detecting whether there is a face target in the document target, the range of the image area for face detection is reduced, and the detection efficiency can be improved.
[0048] In an exemplary embodiment of this specification, the document target may be extracted by intercepting the document target from the image of the target.
[0049] In an exemplary embodiment of this specification, for the document target, a face detection algorithm is used for face detection to determine whether there is a face target in the document target.
[0050] In an exemplary embodiment of this specification, the position coordinates of the above-mentioned document target may be obtained through the output result of the document target detection model in step S201. According to this position coordinate, the target image is intercepted to obtain the image of the corresponding document target. For example, after inputting the image of target 31 into the document target detection model, the output result is the position coordinate corresponding to document target 311. Then, according to this position coordinate, document target 311 is intercepted in the image of target 31 to obtain the independent image of the intercepted document target 311. Then, face detection is performed on the intercepted document target 311. Since the document target 311 includes face target 3111, it is determined that there is a face target in the document target 311.
[0051] If there is a face target in the document target, it can be determined that the target containing the document target is a document attack.
[0052] S203, in the case where there is a face target in the document target, determine that the target is a document attack. For example, in target 31 as Figure 3 shown, user B holds user A's document and attempts to impersonate user A for identity verification. In this case, since there is a document target 311 in the image of target 31 and this document target is detected to include face target 3111, it can be determined that target 31 is a document attack.
[0053] Of course, the target may not be a document attack. For example, there is no document target in the target.
[0054] In this case, to avoid other types of attacks, face detection can be performed on the entire target image to detect whether there is a face target in the target. If there is a face target in the target, it is determined whether the above face target is a live body. If the face target is a live body, then the target is not an attack. In the case where the face target is a live body, the face recognition result generated for the face target is determined as the face recognition result of the target.
[0055] For example, as Figure 4 shown, assume Figure 4 the target in is target 41, there is no document target in this target, only a face target 411, and this face target 411 is a live body. Then according to the above steps, when it is recognized that there is no document target in the image of target 41, the face detection algorithm can be directly used to detect whether there is a face target in target 41. Since there is a face target 411 in the image of target 41. Then continue to perform a live detection on the face target 411. Since this face target 411 is a live body, the face recognition result generated for this face target can be determined as the face recognition result of the target. During the identity verification process, the face recognition result of the face target 411 is used as the face recognition result of the target 41. If the face target 411 matches the user's identity, it can be determined that the target 41 passes the identity verification.
[0056] However, if the face target is not a live body, it can be determined that the target is an attack target. For example, assume that in the target 41 as Figure 4 shown, the face target 411 is a printed photo. Although the face target 411 in the target 41 can be recognized through the face recognition algorithm, since the face target 411 is a printed photo and does not have the physiological characteristics of a live body, therefore, it can be determined through the live detection algorithm that this face target 411 is not a live body. At this time, it can be determined that the target 41 is an attack target.
[0057] In an exemplary embodiment of this specification, the above live detection algorithm may include:
[0058] RGB (color system) image live detection algorithm, infrared image live detection algorithm, 3D Depth (3D depth information) live detection algorithm, etc.
[0059] Among them, the RGB image live detection algorithm uses an ordinary RGB camera as the image acquisition device, and obtains the recognition information required for live detection by analyzing portrait flaws such as moiré patterns, imaging deformations, and reflectivity. The accuracy of the recognition is ensured through multi-dimensional recognition bases.
[0060] The infrared image liveness detection algorithm adds an infrared camera on the basis of the algorithm capabilities of the RGB image liveness detection technology. Since the infrared image filters out light in a specific wavelength band, it can naturally resist forged face attacks based on screen imaging. Since both visible light and infrared light are essentially electromagnetic waves, object imaging is related to the reflection characteristics of its surface material. The reflection characteristics of a real face and attack media such as paper, screen, and three-dimensional mask are different, so the imaging effects are also different. And this surface material difference is more obvious in the reflection of infrared waves. Therefore, when a real face appears in front of the infrared camera and a face on the screen appears in front of the infrared camera, the images captured by the infrared camera are very different and can be easily distinguished. Therefore, the infrared image liveness detection technology has great advantages in identifying attack means such as photo activation.
[0061] In addition, the 3D Depth liveness detection algorithm uses depth cameras such as structured light / TOF (Time of Flight), introduces the concept of "depth information", can obtain 3D data of the face area, and based on this data for further analysis, can easily distinguish forged face attacks of 2D media such as paper photos and screens.
[0062] In this specification, one or more of different types of liveness detection algorithms can be selected according to different application scenarios to cooperate in performing liveness detection on a face target.
[0063] In another exemplary embodiment of this specification, although there is a document target in the target, there is no face target on the document target. In this case, the target is not a document attack. To determine whether the target is an attack of other types, it is also necessary to perform a comprehensive face detection on the target to detect whether there is a face target in the target. If there is a face target in the target, it is necessary to determine whether the above face target is a live body. If the face target is a live body, then the target is not an attack. In the case where the face target is a live body, the face recognition result generated for the face target is determined as the face recognition result of the above target.
[0064] In an exemplary embodiment of this specification, the comprehensive face detection may include performing face detection on the entire image of the target.
[0065] In the above two embodiments, if multiple face targets are obtained through comprehensive face detection on the target, then the liveness detection is performed on each of the multiple face targets one by one. Although in the above two embodiments, full-image face detection is also performed on the target, since document attacks have been excluded by the method introduced above, it is not necessary to perform comprehensive face detection on each target that needs to perform liveness detection and face recognition and perform liveness detection on each detected face target one by one, which can improve the overall efficiency of detection.
[0066] For ease of understanding, a specific exemplary embodiment is introduced below. Assume that in this embodiment, it is necessary to perform attack recognition on the following four images: Image A, Image B, Image C, and Image D respectively. Among them, both Image A and Image B are photos of a person holding a document. Among them, the document in Image A can clearly show the document photo; while the photo of the document in Image B is missing. Image C is a real person, and Image D is a photo of a person displayed on an electronic screen.
[0067] At this time, requests for liveness detection and face recognition are respectively received for the target images A, B, C, and D, and the document targets included in each target image are recognized. The above images are respectively input into a pre-trained document target detection model. According to their respective output results, it is determined whether each image contains a document target. And if there is a document target in the image, in the corresponding output result obtained when using the document target detection model to detect the target image, it also includes the position coordinates of the document target in the corresponding image.
[0068] Since there are document targets in Image A and Image B, the output results of Image A and Image B include the position coordinates of the document targets. Assume that the document target in Image A is document target a; the document target in Image B is document target b. Then, according to the position coordinates of document target a and document target b respectively, document target a and document target b are intercepted. And a face detection algorithm is used to detect whether there are face targets in document target a and document target b. Since there is a face target in document target a, it is directly determined that Image A is a document attack image.
[0069] And since there is no face target in document target b, Image B is not a document attack image. To determine whether Image B is an attack of other types, full-image face detection is performed on Image B, Image C, and Image D without document targets, and it is determined whether the detected face is a live body. Faces are included in Image B, Image C, and Image D. Then, liveness detection is respectively performed on the faces in each image using a liveness detection algorithm. Since the face in Image D is not a live body, it is determined that Image D is an attack image. And the images in Image B and Image C are both live bodies. Therefore, Image B and Image C can pass the liveness detection and face recognition can be performed. And the face recognition result generated for the face target in Image B can be determined as the face recognition result of Image B, and the face recognition result generated for the face target in Image C can be determined as the face recognition result of Image C.
[0070] Figure 5 It is a schematic structural diagram of an electronic device according to an exemplary embodiment of this specification. Please refer to Figure 5, at the hardware level, the device includes a processor 502, an internal bus 504, a network interface 506, a memory 508, and a non-volatile memory 510. Of course, it may also include other hardware required for other functions. The processor 502 reads the corresponding computer program from the non-volatile memory 510 into the memory 508 and then runs it, forming a device for identifying attacks at the logical level. Of course, in addition to the software implementation, one or more embodiments of this specification do not exclude other implementation methods, such as logical devices or a combination of software and hardware, etc. That is to say, the execution subject of the following processing flow is not limited to each logical unit, and can also be hardware or logical devices.
[0071] Corresponding to the embodiments of the above method, this specification also provides a device for identifying attacks, as Figure 6 shown, the device for identifying attacks may include:
[0072] An identification unit 610, configured to identify a document target included in the target when receiving a request for live detection and face recognition of a target;
[0073] A detection unit 620, configured to detect whether there is a face target in the document target;
[0074] A determination unit 630, configured to determine that the target is a document attack when there is a face target in the document target.
[0075] Optionally, the identification unit 610 may specifically be configured to:
[0076] Input an image of the target into a pre-trained document target detection model;
[0077] Determine whether the image contains a document target according to the output result of the document target detection model.
[0078] Optionally, the detection unit 620 may specifically be configured to:
[0079] Obtain the position coordinates of the document target;
[0080] Extract the document target according to the position coordinates;
[0081] Detect whether there is a face target in the extracted document target.
[0082] Optionally, the detection unit 620 may also specifically be configured to:
[0083] Perform face detection on the document target by using a face detection algorithm to determine whether there is a face target in the document target.
[0084] Optionally, the device further includes:
[0085] A target face detection unit 640, configured to detect whether there is a face target in the target when there is no document target in the target or there is no face target in the document target;
[0086] A liveness determination unit 650, configured to determine whether the face target is a live body when there is a face target in the target;
[0087] An attack target determination unit 660, configured to determine the target as an attack target when the face target is not a live body.
[0088] Optionally, the device further includes:
[0089] A result determination unit 670, configured to determine the face recognition result generated for the face target as the face recognition result of the target when the face target is a live body.
[0090] Optionally, the target face detection unit 640 may specifically be configured to:
[0091] Perform face detection on the target by using a face detection algorithm, and determine whether there is a face target in the target.
[0092] Optionally, the liveness determination unit 650 may specifically be configured to:
[0093] Perform liveness detection on the face target by using a liveness detection algorithm, and determine whether the face target is a live body.
[0094] For the implementation processes of the functions and roles of each unit in the above device, refer to the implementation processes of the corresponding steps in the above method for details, which will not be elaborated here.
[0095] The system, device, module or unit illustrated in the above embodiments may specifically be implemented by a computer chip or an entity, or by a product with certain functions. A typical implementation device is a computer, and the specific form of the computer may be a personal computer, a laptop computer, a cellular phone, a camera phone, a smart phone, a personal digital assistant, a media player, a navigation device, an email transceiver device, a game console, a tablet computer, a wearable device, or a combination of any several of these devices.
[0096] In a typical configuration, a computer includes one or more processors (CPUs), an input / output interface, a network interface, and a memory.
[0097] The memory may include non-permanent storage in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. The memory is an example of a computer-readable medium.
[0098] Computer-readable media include permanent and non-permanent, removable and non-removable media that can be used to store information by any method or technology. Information can be computer-readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassettes, disk storage, quantum memory, graphene-based storage media or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer-readable media does not include temporary computer-readable media (transitory media), such as modulated data signals and carrier waves.
[0099] In one or more embodiments of the present specification, the term "includes", "comprising" or any other variant thereof is intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, an element defined by the sentence "comprising a ..." does not exclude the presence of other identical elements in the process, method, commodity or device including the element.
[0100] The terms used in one or more embodiments of this specification are only for the purpose of describing specific embodiments, and are not intended to limit one or more embodiments of this specification. The singular forms of "a", "said" and "the" used in one or more embodiments of this specification and the appended claims are also intended to include plural forms, unless the context clearly indicates other meanings. It should also be understood that the term "and / or" used herein refers to and includes any or all possible combinations of one or more associated listed items.
[0101] It should be understood that although the terms first, second, third, etc. may be used in one or more embodiments of this specification to describe various information, such information should not be limited to these terms. These terms are only used to distinguish information of the same type from each other. For example, without departing from the scope of one or more embodiments of this specification, the first information may also be referred to as the second information, and similarly, the second information may also be referred to as the first information. Depending on the context, the word "if" as used herein may be interpreted as "when" or "while" or "in response to determining".
[0102] The above are only the preferred embodiments of one or more embodiments of this specification, and are not intended to limit one or more embodiments of this specification. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of one or more embodiments of this specification shall be included within the scope protected by one or more embodiments of this specification.
Claims
1. A method for identifying attacks, characterized in that, Including: When receiving a request for live detection and face recognition for a target, identifying the document target included in the target; Detecting whether there is a face target in the document target; When there is a face target in the document target, determining that the target is a document attack; When there is no document target in the target or there is no face target in the document target, detecting whether there is a face target in the target; When there is a face target in the target, determining whether the face target is a live body; When the face target is not a live body, determining that the target is an attack target.
2. The method according to claim 1, characterized in that The identifying the document target included in the target includes: Inputting the image of the target into a pre-trained document target detection model; According to the output result of the document target detection model, determining whether the image contains a document target.
3. The method according to claim 1, characterized in that The detecting whether there is a face target in the document target includes: Obtaining the position coordinates of the document target; Extracting the document target according to the position coordinates; Detecting whether there is a face target in the extracted document target.
4. The method according to claim 1, wherein The detecting whether there is a face target in the document target includes: For the document target, using a face detection algorithm to perform face detection and determining whether there is a face target in the document target.
5. The method according to claim 1, wherein Also including: When the face target is a live body, determining the face recognition result generated for the face target as the face recognition result of the target.
6. The method according to claim 1, wherein The detecting whether there is a face target in the target includes: For the target, using a face detection algorithm to perform face detection and determining whether there is a face target in the target.
7. The method according to claim 1, wherein The determining whether the face target is a live body includes: For the face target, using a live detection algorithm to perform live detection and determining whether the face target is a live body.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by a processor, implementing the steps of the method according to any one of claims 1-7.
9. An electronic device, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, When the processor executes the program, implementing the steps of the method according to any one of claims 1-7.
Citation Information
Patent Citations
Certificate identification method and device
CN111767845A