nix/module/common/Crypto.nix

28 lines
610 B
Nix
Raw Normal View History

2024-04-09 14:14:28 +03:00
{ pkgs, ... }: {
# GPG.
services.udev.packages = [ pkgs.yubikey-personalization ];
programs.gnupg.agent = {
enable = true;
enableSSHSupport = true;
2024-04-17 01:35:59 +03:00
pinentryPackage = pkgs.pinentry-tty;
2024-04-09 14:14:28 +03:00
};
2024-04-09 16:47:03 +03:00
# PCSC.
services.pcscd.enable = true;
# Yubikey touch notification.
# ISSUE: Not working on Sway with Mako for some reason.
# programs.yubikey-touch-detector.enable = true;
2024-04-09 16:47:03 +03:00
2024-04-09 14:14:28 +03:00
environment.systemPackages = with pkgs; [
yubikey-manager
2024-04-09 14:26:36 +03:00
# yubioath-desktop # OTP.
2024-04-09 14:14:28 +03:00
];
2024-04-09 14:26:36 +03:00
# Store GPG data on tmpfs.
# environment.variables = {
# GNUPGHOME = "$(mktemp -d -t gnupg-$(date +%Y-%m-%d)-XXXXXXXXXX)";
# };
2024-04-09 14:14:28 +03:00
}