On-premise passive face liveness (PAD) HTTP API. Linux amd64. Port 8093.
811
On-premise passive face liveness (PAD) HTTP API. Linux amd64. CPU only. Official image: faceplugin/face-liveness.
The image is an API/SDK server only (no Gradio). The runtime is already inside — pull and run. This repository is self-contained.
This is the Face Liveness product, not Face Liveness Check / Face Verification (faceplugin/face-verification) and not the divi image (faceplugin/face-liveness-divi).
Fully on-premise anti-spoofing for KYC. One RGB photo, nothing asked of the person: printed photo, screen replay (photo and video), 3D mask, and deepfake. All processing stays on your server.
Score ≥ 0.5 → result: "Real", pass: true. Score < 0.5 → result: "Spoof", pass: false.
Passive mode at that threshold, FacePlugin QA following ISO/IEC 30107-3: BPCER 0% (none observed) and APCER 0.5–1.5% against printed photo, screen replay (photo and video), and a painted 3D resin mask. This is an internal evaluation, not an independent laboratory result, and no iBeta certification is claimed. A 0% BPCER means none observed, not a rate of zero.
Every tag is the same CPU image.
| Tag | Notes |
|---|---|
latest | Same image as latest-cpu |
latest-cpu | Current CPU image |
2.0.0 | Same image as 2.0.0-cpu |
2.0.0-cpu | Version 2.0.0 CPU image |
docker pull faceplugin/face-liveness:latest
Default listen port 8093. Use --shm-size=2gb (the SDK unpacks models into shared memory; Docker’s 64MB default is too small).
docker run -d --name faceplugin-face-liveness \
--shm-size=2gb --privileged \
-p 8093:8093 \
-v /etc/machine-id:/etc/machine-id:ro \
faceplugin/face-liveness:latest
docker logs -f faceplugin-face-liveness
# Look for the machine code line: FPMC1.…
API: http://127.0.0.1:8093
The image refuses to start without that command. A plain docker run keeps the container's own /etc/machine-id, so the license machine code is not the host's. --shm-size=2gb and --privileged are required too. This image is for a Linux host that has /etc/machine-id.
You do not need a license to start. GET /api/health works before activation. Product endpoints unlock after you activate.
The published image does not include a license. The API starts without one and prints a machine code (FPMC1.…).
GET /api/machinecode.FP1.…).# Paste the FP1. key into license.txt, then:
curl -s -X POST http://127.0.0.1:8093/api/activate \
-H 'Content-Type: text/plain' \
--data-binary @license.txt
Or mount a file the process reads on startup:
-v $(pwd)/license.txt:/root/facesdk/license.txt
Docker and native-host codes are different. If you run in Docker, send the Docker machine code. On a Linux host the code comes from /etc/machine-id; keep that volume so a recreate still matches the key.
A key labelled Liveness only or Recognition + Liveness unlocks /api/liveness. A Recognition only key does not.
curl -s http://127.0.0.1:8093/api/licenseStatus
Use a new name and host port, and keep the same machine-id mount:
docker run -d --name faceplugin-face-liveness-2 \
--shm-size=2gb --privileged \
-p 8193:8093 \
-v /etc/machine-id:/etc/machine-id:ro \
faceplugin/face-liveness:latest
Activate each published port with the same key. Every container must mount the host /etc/machine-id.
More: run multiple containers.
Routes are /api/*. There is no version segment and no /docs.
| Method | Path | Notes |
|---|---|---|
GET | /api/health | HTTP server is up. No license required |
GET | /api/machinecode | FPMC1.… |
GET | /api/licenseStatus | What the key unlocks |
GET | /api/backend | Runtime that is loaded |
POST | /api/activate | Raw license key (text/plain) |
POST | /api/liveness | JSON {"image":"<base64-jpeg>"} |
POST | /api/check_liveness | Alias of /api/liveness |
Health:
curl -s http://127.0.0.1:8093/api/health
Liveness:
curl -s -X POST http://127.0.0.1:8093/api/liveness \
-H 'Content-Type: application/json' \
-d '{"image":"<base64-jpeg>"}'
Example success data:
{ "score": 0.72, "result": "Real", "pass": true }
This API has no authentication. It listens on 0.0.0.0 so the published port works, and it answers browser requests from any origin. Put it behind your own gateway before exposing it.
| Variable | Purpose |
|---|---|
FACESDK_BIND_HOST | Listen address. Default 0.0.0.0. Set 127.0.0.1 for this machine only |
PORT / FACESDK_PORT | API port. Default 8093 |
LICENSE | A license key (FP1.…) or a path to a license file. Default /root/facesdk/license.txt |
FP_NO_LICENSE_PROMPT | Set to 1 to skip the interactive paste prompt |
Postman collection and the Gradio demo (port 9093) run on the host, not in this image: FaceLivenessDetection-Docker.
Content type
Image
Digest
sha256:ff53620d3…
Size
432 MB
Last updated
1 day ago
docker pull faceplugin/face-liveness