nixos-config/config/programs/gpg.nix

55 lines
1.7 KiB
Nix
Raw Normal View History

2022-06-12 15:39:15 +00:00
{pkgs, ...}: {
2022-01-18 13:33:10 +00:00
programs.gpg = {
enable = true;
publicKeys = [
2022-02-02 15:55:39 +00:00
{
source = ../../keys/lotte_chir.rs.pgp;
trust = 5;
}
2022-01-18 13:33:10 +00:00
{
2022-02-09 15:13:35 +00:00
source = ../../keys/miifox_miifox.net.pgp;
trust = 3;
2022-01-18 13:33:10 +00:00
}
{
source = ../../keys/mdelenk_hs-mittweida.de.pgp;
trust = 5;
}
];
2022-02-02 15:55:39 +00:00
scdaemonSettings = {
disable-ccid = true;
2022-02-02 16:05:16 +00:00
pcsc-driver = "${pkgs.pcsclite.out}/lib/libpcsclite.so.1";
2022-02-02 15:55:39 +00:00
reader-port = "Yubico YubiKey";
};
settings = {
# https://github.com/drduh/config/blob/master/gpg.conf
personal-cipher-preferences = "AES256 AES192 AES";
personal-digest-preferences = "SHA512 SHA384 SHA256";
personal-compress-preferences = "ZLIB BZIP2 ZIP Uncompressed";
default-preference-list = "SHA512 SHA384 SHA256 AES256 AES192 AES ZLIB BZIP2 ZIP Uncompressed";
cert-digest-algo = "SHA512";
s2k-digest-algo = "SHA512";
s2k-cipher-algo = "AES256";
charset = "utf-8";
fixed-list-mode = true;
no-comments = true;
no-emit-version = true;
no-greeting = true;
keyid-format = "0xlong";
list-options = "show-uid-validity";
verify-options = "show-uid-validity";
with-fingerprint = true;
with-key-origin = true;
require-cross-certification = true;
no-symkey-cache = true;
use-agent = true;
throw-keyids = true;
2022-06-12 15:39:15 +00:00
keyserver = ["hkps://keys.openpgp.org" "hkps://keyserver.ubuntu.com:443" "hkps://hkps.pool.sks-keyservers.net" "hkps://pgp.ocf.berkeley.edu"];
auto-key-locate = ["local" "dane" "cert" "wkd"];
2022-02-02 15:55:39 +00:00
};
2022-01-18 13:33:10 +00:00
};
2022-04-06 13:59:25 +00:00
services.gpg-agent = {
enable = true;
2023-12-23 08:30:49 +00:00
pinentryFlavor = "qt";
2022-04-06 13:59:25 +00:00
};
2022-01-19 08:28:39 +00:00
}