DEV Community

Cover image for Test Your Liveness Vendor Against Injection Attacks
SABHARI SRIRAM
SABHARI SRIRAM

Posted on Fully Autonomous

Test Your Liveness Vendor Against Injection Attacks

A liveness vendor should be tested against injection attacks by injecting videos into the live feed stream through a simulated webcam, an emulator or a hooked app, and checking whether the vendor flags the stream itself, not just the face. The test is performed without using a real camera, since recorded videos or even deepfake videos are fed in through a virtual camera. A vendor that has only passed presentation attack testing hasn't been tested for this yet.

Why a PAD certificate is not enough

Presentation Attack Detection (PAD) tests what is presented to the actual camera: an image on paper, a screen replay, a mask. Injection attacks have nothing to do with a camera lens. An attacker replaces the camera feed with a file or a live deepfake, so that the face can look perfect and there is no tangible thing for the PAD algorithm to detect.

This difference is reflected in the standards. CEN/TS 18099, which was released in late 2024, deals with biometric data injection attack detection and purposely excludes presentation attack testing from its scope since it is already covered by ISO/IEC 30107. So a vendor's ISO 30107-3 result tells you about masks and replays, not virtual cameras.

Map the attack surface first

During FIDO's Authenticate 2026, Chris Allgrove classified injection methods into software virtual cameras, hardware virtual cameras, external video capture cards, mobile device emulators, function hooking, and man-in-the-middle attacks. The attack could be carried out from the camera stream, within the application or device, or in-between the application and the decision-making server.

Note these in your flow chart. A web-based onboarding page and a native mobile application would have different vulnerabilities, meaning that there is a need to design a different test strategy. Neural Defend's guide to attack testing helps with creating deepfake attack scenarios for testing.

Liveness capture pipeline with injection points: virtual cameras at the camera feed, emulators and hooking in the app, man-in-the-middle on the network

Image created with AI assistance.

A practical test plan

  1. Ask for the evidence. Ask for any injection attack detection (IAD) test report, who conducted it, what methods are covered and their error rates. "We have liveness" isn't an answer.
  2. Build your own attack kit. Use a virtual camera on desktop, an emulator on Android, and a hooked build of your app. Inject three types of media: genuine video replay, face-swap video and a completely synthetic face.
  3. Run bona fide sessions too. Conduct tests with real people on real devices, with different phones, lighting and network environments. An IAD control that denies access to legitimate customers isn't usable.
  4. Measure both errors. Measure attacks accepted and legitimate customers blocked, broken down by attack type and by platform, not just combined.
  5. Check what the server sees. Make sure that the decision is based on signals that can't be faked by the client, like a device integrity check and a server-side decision, not an app signal.
  6. Repeat after every release. SDK updates, operating system updates and new virtual camera tools will change the outcome.

Neural Defend describes the interrelationship between the injection attack detection standards in case you have to map vendor claims against a specification.

What good looks like

An effective vendor should be able to tell you what injection techniques it recognizes, provide third-party testing results, and describe how it would handle a stream it cannot trust. ENISA's 2024 report on good practices for remote ID proofing considers injection attacks as a separate threat category. Consider them as such during procurement, and test them yourself before go-live.

Sources:

Note: This article was created with the help of AI. I reviewed and fact-checked it before publishing. The cover and diagram were also made with AI assistance.

Disclosure: I work as an AI intern at Neural Defend, a deepfake detection company. The Neural Defend guides linked in this post are from my employer.

Top comments (0)