2023-09-11 20:23:04 +02:00
|
|
|
{
|
|
|
|
config,
|
|
|
|
lib,
|
|
|
|
...
|
|
|
|
}:
|
2021-11-25 22:03:04 +01:00
|
|
|
with lib;
|
2024-11-20 20:32:38 +01:00
|
|
|
mkIf (elem "fprintd" config.machine.services) {
|
|
|
|
security.pam.services =
|
|
|
|
let
|
2023-09-11 20:23:04 +02:00
|
|
|
unlock = [
|
|
|
|
"sudo"
|
|
|
|
"i3lock"
|
|
|
|
"login"
|
|
|
|
"lightdm"
|
|
|
|
];
|
|
|
|
in
|
2024-11-20 20:32:38 +01:00
|
|
|
listToAttrs (
|
|
|
|
forEach unlock (n: {
|
2023-09-11 20:23:04 +02:00
|
|
|
name = n;
|
2024-11-20 20:32:38 +01:00
|
|
|
value = {
|
|
|
|
fprintAuth = true;
|
|
|
|
};
|
|
|
|
})
|
|
|
|
);
|
2021-11-25 22:03:04 +01:00
|
|
|
|
2024-11-20 20:32:38 +01:00
|
|
|
services.fprintd = {
|
|
|
|
enable = true;
|
|
|
|
};
|
|
|
|
}
|