Tools: Building a Face Authentication System for Linux (Using PAM, systemd, and ONNX) (2026)
shekh-2810 / AstraLock AstraLock is a lightweight face-authentication system designed for Linux. It replaces legacy camera pipelines with modern deep-learning models, optimized preprocessing, and a clean, modular architecture. The goal is simple: reliable face-based login on Linux without the sluggishness, low-light failures, or angle sensitivity seen in older tools. AstraLock AstraLock is a Linux biometric authentication system that enables face-based login through PAM and systemd, designed to be offline, auditable, and hackable, offering a native Linux alternative to projects like Howdy and closed platforms such as Windows Hello without cloud dependencies.
It runs a local daemon that performs facial verification and integrates directly with system authentication flows such as sudo, login, display managers, and polkit. What AstraLock Is A system daemon that performs face verification A PAM module (pam_facelock.so) for system authentication A CLI tool for enrollment, verification, and testing A local-only LBPH model (no cloud, no network) No external services.No telemetry.No vendor lock-in. Features 🔐PAM authentication (login, sudo, polkit, display managers)🧠Offline facial recognition (LBPH, OpenCV) ⚙️systemd-managed daemon lifecycle📷 Webcam support via OpenCV🧪Built-in testing via pamtester Simple CLI for users and admins Architecture… View on GitHub
shekh-2810 / AstraLock
AstraLock is a lightweight face-authentication system designed for Linux. It replaces legacy camera pipelines with modern deep-learning models, optimized preprocessing, and a clean, modular architecture. The goal is simple: reliable face-based login on Linux without the sluggishness, low-light failures, or angle sensitivity seen in older tools.
AstraLock
What AstraLock Is
Features
Architecture
The Problem with Existing Approaches
Design Goals
High-Level Architecture
Why this design?
Recognition Pipeline
Key Challenges
1. PAM Behavior is Subtle
2. Display Managers Are Inconsistent
3. Camera Reliability
4. Avoiding Lockouts
Current Capabilities
Security Considerations
What I Learned
Looking for Feedback
Project Linux still lacks a reliable, native biometric authentication system. While platforms like Windows and macOS have tightly integrated face authentication, Linux users typically rely on passwords — or experimental tools that often break under real-world conditions. So I built AstraLock. AstraLock is a Linux biometric authentication system that enables face-based login through PAM and systemd, designed to be offline, auditable, and hackable, offering a native Linux alternative to projects like Howdy and closed platforms such as Windows Hello without cloud dependencies. It runs a local daemon that performs facial verification and integrates directly with system authentication flows such as sudo, login, display managers, and polkit. A system daemon that performs face verification A PAM module (pam_facelock.so) for system authentication A CLI tool for enrollment, verification, and testing A local-only LBPH model (no cloud, no network) No external services.No telemetry.
No vendor lock-in. Most existing solutions (like Howdy) work — until they don’t. The biggest issue wasn’t the ML part — it was system integration. Before writing code, I defined strict constraints: Instead of embedding everything inside PAM, I separated concerns: PAM modules should stay minimal and predictable. Heavy operations like: are handled by a separate daemon. This avoids blocking PAM and improves reliability. The pipeline uses modern ONNX-based models: Everything runs locally. No external APIs. No network calls. The biggest issue was handling: Small changes in PAM configuration can completely change outcomes. GDM, SDDM, and others: This required testing across environments. Accessing /dev/video* sounds simple — but: Biometric authentication is probabilistic. This is not meant to replace passwords entirely. The system is designed for: convenience + controlled risk, not absolute security I’m particularly interested in input on: AstraLock is open source and still evolving. If you’ve worked with PAM, Linux auth, or system-level tooling, I’d appreciate your perspective. Templates let you quickly answer FAQs or store snippets for re-use. Are you sure you want to ? It will become hidden in your post, but will still be visible via the comment's permalink. Hide child comments as well For further actions, you may consider blocking this person and/or reporting abuse