Skip to content

Security: Insecure default permissions (644) for face model files in /etc/howdy/models #1098

Description

@omartayel

[SECURITY] Insecure default permissions (644) for face model files

Description

I discovered that the howdy add command (and the installation process) creates facial model files (.dat) with world-readable permissions (644 / -rw-r--r--).

Additionally, the /etc/howdy/models directory is created with 755 permissions, allowing any user to list the registered face models on the system.

While these .dat files are mathematical vectors and not raw images, they represent sensitive biometric data. In their current state, any unprivileged user or malicious process on the system can read these models, which could potentially be used for reconstruction or spoofing in other biometric contexts.

Environment

  • OS: CachyOS (Arch Linux)
  • Hardware: Ryzen 9 9950X3D / Logitech Brio (IR)
  • Howdy Version: 3.0.0 Beta (howdy-git)
  • Python Version: 3.14+

Steps to Reproduce

  1. Enroll a new face model: sudo howdy add
  2. Check the permissions of the newly created model as a non-root user:
    ls -l /etc/howdy/models/
  3. Observe the output: -rw-r--r-- 1 root root ... *.dat

Expected Behavior

Biometric data should follow the principle of least privilege:

  • Models: Should be created with 600 (-rw-------) permissions.
  • Directory: /etc/howdy/models should be 700 (drwx------).
    Only the root user (and the PAM stack running as root) should have access to this data.

Actual Behavior

The files are created with 644 permissions, making the biometric vectors accessible to all users on the system.

Evidence

Terminal capture showing the insecure state of the model files:

Image

Proposed Fix

Update the enrollment script (e.g., in cli/add.py) to explicitly set strict permissions immediately after file creation:

os.chmod(model_path, 0o600)

The installation script should also ensure that the /etc/howdy/models directory is initialized with 700 during the build process.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions