feat(signing): minisign content verification + KATELLO_PASSWORD_FILE#37
Merged
Conversation
ContentViewSyncer: when signing_public_key is set, prepends three steps before nix copy — curl nix-cache-info, curl .minisig, minisign -V. The public key is embedded in the NixOS image so an unauthenticated Katello cannot deliver arbitrary closures. SyncDaemon: accepts signing_public_key constructor arg; wired through to ContentViewSyncer on each poll. daemon_from_env() reads SOURCEOS_SIGNING_PUBLIC_KEY. _resolve_password(): reads KATELLO_PASSWORD_FILE before KATELLO_PASSWORD, supporting systemd LoadCredential pattern used by the NixOS module. 95 tests passing.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
ContentViewSyncernow accepts asigning_public_key(minisignRWS...string). When set, the plan prepends three steps beforenix copy:curl nix-cache-info,curl nix-cache-info.minisig,minisign -V. Prevents an unauthenticated Katello from delivering arbitrary closures — the key is baked into the NixOS image.KATELLO_PASSWORD_FILE:_resolve_password()reads the password from a file path before env var. Supports the systemdLoadCredentialpattern the NixOS module uses.SyncDaemon: wiressigning_public_keythrough toContentViewSynceron each poll.daemon_from_env()readsSOURCEOS_SIGNING_PUBLIC_KEY.--signing-public-keyadded tosync plan,sync apply, andsync daemon.Test plan
python3 -m pytest tests/ -q→ 95 passedsync plan --signing-public-key RWS...shows minisign steps in plan outputsync applywithKATELLO_PASSWORD_FILE=/path/to/fileresolves password from file