Commit Graph
17 Commits
Author SHA1 Message Date
Erik Arvstedt e1e3d8a92b secrets: simplify cert generation
- Remove openssl.cnf which includes many unused settings.
- Generate the key and cert files with a single call to openssl.
  - Option `-nodes` ("no DES") disables encryption of the key file.
  - Option `-addext` is used to specify `subjectAltName` settings
    that were previously defined by openssl.cnf.

The key type is unchanged.
Certificate changes:
- Certificate duration is now 10 years
- Organization (subj 'O') is now 'loop' instead of 'loopd' for
  lightning-loop to simplify the code.
  For reference, the org. name in auto-generated loop certs is
  "loop autogenerated cert".
- The certificate now includes all default x509v3 extensions.
  These were previously restricted to just `subjectAltName` by openssl.cnf.
  We now use the openssl defaults for simplicity.
2021-09-11 15:07:24 +02:00
nixbitcoin 00a0759884 joinmarket-ob-watcher: extra permissions & functionality for fidelity bonds 2021-08-30 13:37:04 +02:00
Jonas Nick 79f4723cda lightning-charge: remove package and module 2021-01-01 19:16:46 +00:00
Jonas Nick 58de79d401 nanopos: remove package and module 2021-01-01 17:37:30 +00:00
Erik Arvstedt a359cdfb66 generate-secrets: use pwgen
Password length and alphabet is unchanged, but the restriction to
include at least one numeric and one capital char has been removed.
This restriction is not needed by client applications,
adds code complexity, and even (insignificantly) reduces entropy.

Reason for switching to pwgen:
apg uses /dev/random instead of /dev/urandom which brings no security
benefits but can stall the generate-secrets script on low-entropy
devices due to blocking.

Since `security.rngd` has been disabled in NixOS 20.09, blocking
in generate-secrets can also appear on regular NixOS desktop systems.
2020-12-18 19:56:56 +01:00
Erik Arvstedt 2a9b918f72 generate-secrets: always run with Bash, stop on errors 2020-10-23 10:54:15 +02:00
nixbitcoin e7c5f956ea lightning-loop: update module
* commandlineArgs -> configFile
* introduce tls certs
* loop dataDir
* fix formatting and descriptions

Warning: Manual migration of existing loop data directory necessary
2020-09-24 16:40:11 +00:00
nixbitcoin d0701f518c joinmarket: automatically generate wallet 2020-09-22 13:50:49 +00:00
nixbitcoin 173891fa5b joinmarket: add module 2020-09-22 13:50:37 +00:00
nixbitcoin 15b574faa7 nbxplorer/btcpayserver: add module 2020-09-15 12:09:12 +00:00
Erik Arvstedt 9b6a3ec835 generate-secrets: extract fn 'makeHMAC' 2020-08-27 12:20:06 +02:00
nixbitcoin e4fb7a52de backups: add module 2020-08-04 15:25:37 +00:00
nixbitcoin 5a978a2836 bitcoind: switch from rpcpassword to rpcauth
Includes bitcoind's `share/rpcauth` to convert apg generated passwords
into salted HMAC-SHA-256 hashed passwords.
2020-07-28 14:32:47 +00:00
nixbitcoin 4dbc348921 electrs: remove TLSProxy
https://github.com/spesmilo/electrum/issues/5278 was resolved
2020-07-21 13:41:03 +00:00
nixbitcoin e95f5981aa Remove KN countrycode 2020-04-24 16:27:48 +02:00
Erik Arvstedt b1e13e9415 simplify secrets file format
Each secret file to be deployed is now backed by one local file.
This simplifies 'setup-secrets' and the secret definitions.
Also, with the old format it was not possible to add new secrets
to secrets.nix in a simple way.

Old secrets are automatically converted to the new format when running
nix-shell.

Using the new option 'nix-bitcoin.secrets', secrets are now directly
defined by the services that use them.
2020-01-13 00:25:11 +01:00
Erik Arvstedt 6447694214 add generate-secrets pkg
generate-secrets.sh will also be used in generate-secrets.nix, so DRY
its dependency definitions.
2020-01-12 20:02:01 +01:00