Skip to content

Commit

Permalink
feat(nix): disable fprint auth as it's not unlocking keyring
Browse files Browse the repository at this point in the history
  • Loading branch information
sbulav committed Feb 1, 2024
1 parent 87e0c74 commit f4002bd
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 2 deletions.
23 changes: 22 additions & 1 deletion nix/modules/nixos/hardware/fingerprint/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,26 @@ in {
enable = mkBoolOpt false "Whether or not to enable fingerprint support.";
};

config = mkIf cfg.enable {services.fprintd.enable = true;};
config = mkIf cfg.enable {
services.fprintd.enable = true;

security.pam.services.swaylock.text = ''
# Account management.
account required pam_unix.so
# Authentication management.
# prompt for a password; pressing Enter on a blank field will proceed to fingerprint authentication.
auth sufficient pam_unix.so nullok likeauth try_first_pass
auth sufficient ${pkgs.fprintd}/lib/security/pam_fprintd.so
auth required pam_deny.so
# Password management.
password sufficient pam_unix.so nullok sha512
# Session management.
session required pam_env.so conffile=/etc/pam/environment readenv=0
session required pam_unix.so
'';
};
}
2 changes: 1 addition & 1 deletion nix/systems/x86_64-linux/nz/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# Enable Bootloader
system.boot.efi.enable = true;
system.battery.enable = true; # Only for laptops, they will still work without it, just improves battery life
hardware.fingerprint.enable = true;
hardware.fingerprint.enable = false;
hardware.bluetoothmy.enable = true;

# environment.systemPackages = with pkgs; [
Expand Down

0 comments on commit f4002bd

Please sign in to comment.