Skip to content

Physlock

services.physlock.allowAnyUser

Whether to allow any user to lock the screen. This will install a setuid wrapper to allow any user to start physlock as root, which is a minor security risk. Call the physlock binary to use this instead of using the systemd service.

Type: boolean

Default

false

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/security/physlock.nix

services.physlock.disableSysRq

Whether to disable SysRq when locked with physlock.

Type: boolean

Default

true

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/security/physlock.nix

services.physlock.enable

Whether to enable the {command}physlock screen locking mechanism.

Enable this and then run {command}systemctl start physlock to securely lock the screen.

This will switch to a new virtual terminal, turn off console switching and disable SysRq mechanism (when {option}services.physlock.disableSysRq is set) until the root or user password is given.

Type: boolean

Default

false

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/security/physlock.nix

services.physlock.lockMessage

Message to show on physlock login terminal.

Type: string

Default

""

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/security/physlock.nix

services.physlock.lockOn.extraTargets

Other targets to lock the screen just before.

Useful if you want to e.g. both autologin to X11 so that your {file}~/.xsession gets executed and still to have the screen locked so that the system can be booted relatively unattended.

Type: list of string

Default

[ ]

Example

["display-manager.service"]

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/security/physlock.nix

services.physlock.lockOn.hibernate

Whether to lock screen with physlock just before hibernate.

Type: boolean

Default

true

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/security/physlock.nix

services.physlock.lockOn.suspend

Whether to lock screen with physlock just before suspend.

Type: boolean

Default

true

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/security/physlock.nix

services.physlock.muteKernelMessages

Disable kernel messages on console while physlock is running.

Type: boolean

Default

false

Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/security/physlock.nix