This project is mirrored from https://gitee.com/mirrors/nomad.git. Pull mirroring failed .
Repository mirroring has been paused due to too many failed attempts. It can be resumed by a project maintainer.
  1. 27 Jun, 2022 4 commits
  2. 24 Jun, 2022 1 commit
  3. 23 Jun, 2022 2 commits
  4. 22 Jun, 2022 4 commits
  5. 21 Jun, 2022 4 commits
  6. 20 Jun, 2022 10 commits
    • Jai's avatar
      dx: update `canCreate` logic and token generation for secure var dev environment (#13438) · 34adc19b
      Jai authored
      * ui:  add logic for create permission computed property
      
      * ui:  update token factory and variable ability to simulate create permissions for dev env
      34adc19b
    • Phil Renaud's avatar
      Append an empty item when editing an existing Secure Variable (#13436) · 812e94ee
      Phil Renaud authored
      * Did-insert modifier to add an extra row when editing
      
      * Defensive logic on model existing
      
      * Defensive pattern on copy keyValues
      812e94ee
    • Phil Renaud's avatar
      Throw an error if you try to save a Secure Variable with no items (#13424) · feb2b9de
      Phil Renaud authored
      * Error thrown if you have no KVs on save
      
      * Acceptance tests for flash messages and no-key-value adds
      
      * Post-hoc accounting for new variable path routing
      
      * Trim on key before validating it as existing
      feb2b9de
    • Tim Gross's avatar
      core job for key rotation (#13309) · a1f05b17
      Tim Gross authored
      Extend the GC job to support periodic key rotation.
      
      Update the GC process to safely support signed workload identity. We
      can't GC any key used to sign a workload identity. Finding which key
      was used to sign every allocation will be expensive, but there are not
      that many keys. This lets us take a conservative approach: find the
      oldest live allocation and ensure that we don't GC any key older than
      that key.
      a1f05b17
    • Tim Gross's avatar
      move gossip keyring command to their own subcommands (#13383) · b550510b
      Tim Gross authored
      Move all the gossip keyring and key generation commands under
      `operator gossip keyring` subcommands to align with the new `operator
      secure-variables keyring` subcommands. Deprecate the `operator keyring`
      and `operator keygen` commands.
      b550510b
    • Phil Renaud's avatar
      Secure Variables: show file metadata on list pages (#13423) · bbba2309
      Phil Renaud authored
      * Add modified times and namespaces to layout
      
      * Undo typing change
      
      * Post-hoc accounting for new variable path routing
      bbba2309
    • Tim Gross's avatar
      fix blocking query for `Keyring.List` RPC (#13384) · 2c25bb21
      Tim Gross authored
      The blocking query for `Keyring.List` appended the keys for each pass
      through the blocking query to the response. This results in mulitple
      copies of keys in the response. Overwrite the `reply.Keys` field on
      each pass through the blocking query to ensure we only get the
      expected page of responses.
      2c25bb21
    • Tim Gross's avatar
      secure variables ACL policies (#13294) · 0b36d439
      Tim Gross authored
      Adds a new policy block inside namespaces to control access to secure
      variables on the basis of path, with support for globbing.
      
      Splits out VerifyClaim from ResolveClaim.
      The ServiceRegistration RPC only needs to be able to verify that a
      claim is valid for some allocation in the store; it doesn't care about
      implicit policies or capabilities. Split this out to its own method on
      the server so that the SecureVariables RPC can reuse it as a separate
      step from resolving policies (see next commit).
      
      Support implicit policies based on workload identity
      0b36d439
    • Tim Gross's avatar
      implement Encrypt/Decrypt methods of encrypter (#13375) · 1779284f
      Tim Gross authored
      The `Encrypt` method generates an appropriately-sized nonce and uses
      that buffer as the prefix for the ciphertext. This keeps the
      ciphertext and nonce together for decryption, and reuses the buffer as
      much as possible without presenting the temptation to reuse the
      cleartext buffer owned by the caller.
      
      We include the key ID as the "additional data" field that's used as an
      extra input to the authentication signature, to provide additional
      protection that a ciphertext originated with that key.
      
      Refactors the locking for the keyring so that the public methods are
      generally (with one commented exception) responsible for taking the
      lock and then inner methods are assumed locked.
      1779284f
    • Charlie Voiselle's avatar
      Implement HTTP search API for Variables (#13257) · e96bc369
      Charlie Voiselle authored
      * Add Path only index for SecureVariables
      * Add GetSecureVariablesByPrefix; refactor tests
      * Add search for SecureVariables
      * Add prefix search for secure variables
      e96bc369
  7. 17 Jun, 2022 4 commits
  8. 14 Jun, 2022 11 commits
    • Charlie Voiselle's avatar
      Secure Variables: Seperate Encrypted and Decrypted structs (#13355) · 71d187d6
      Charlie Voiselle authored
      
      This PR splits SecureVariable into SecureVariableDecrypted and
      SecureVariableEncrypted in order to use the type system to help
      verify that cleartext secret material is not committed to file.
      
      * Make Encrypt function return KeyID
      * Split SecureVariable
      Co-authored-by: default avatarTim Gross <tgross@hashicorp.com>
      71d187d6
    • Tim Gross's avatar
      keyring CLI: refactor to use subcommands (#13351) · 260f0b1a
      Tim Gross authored
      Split the flag options for the `secure-variables keyring` into their
      own subcommands. The gossip keyring CLI will be similarly refactored
      and the old version will be deprecated.
      260f0b1a
    • Phil Renaud's avatar
      Secure Variables form validation improvements (#13335) · 32c6d042
      Phil Renaud authored
      * Validation tests for secure variables form: duplicate path error
      
      * Validation for dot in key name
      
      * Defensive pattern on copy keyValues
      32c6d042
    • Phil Renaud's avatar
      variable index header and deletion hook (#13302) · aeaabb71
      Phil Renaud authored
      * variable index header and deletion hook
      
      * Some visual improvements to edit header and back button
      
      * Mirage fixtures for variables
      
      * Deletion flow test
      
      * Account for disabled state of add-more button
      
      * Transition destination changes after design chat
      
      * Simplified parent folder path by adding to variable model
      
      * Lint cleanup
      
      * test update to reflect path redirect on delete
      
      * No longer have to re-traverse to a deleted var folder after deletion, tests updated
      aeaabb71
    • Tim Gross's avatar
      workload identity (#13223) · 6fa2c8a0
      Tim Gross authored
      In order to support implicit ACL policies for tasks to get their own
      secrets, each task would need to have its own ACL token. This would
      add extra raft overhead as well as new garbage collection jobs for
      cleaning up task-specific ACL tokens. Instead, Nomad will create a
      workload Identity Claim for each task.
      
      An Identity Claim is a JSON Web Token (JWT) signed by the server’s
      private key and attached to an Allocation at the time a plan is
      applied. The encoded JWT can be submitted as the X-Nomad-Token header
      to replace ACL token secret IDs for the RPCs that support identity
      claims.
      
      Whenever a key is is added to a server’s keyring, it will use the key
      as the seed for a Ed25519 public-private private keypair. That keypair
      will be used for signing the JWT and for verifying the JWT.
      
      This implementation is a ruthlessly minimal approach to support the
      secure variables feature. When a JWT is verified, the allocation ID
      will be checked against the Nomad state store...
      6fa2c8a0
    • Phil Renaud's avatar
      Notify a user if they try to make a variable with an existing path (#13278) · 680dd0ed
      Phil Renaud authored
      * Notify a user if they try to make a variable with an existing path
      
      * Stylize error fade
      
      * Bugfix: if you click the dupe link to a variable you havent previously loaded, you lack its keyvalues
      
      * rename and typefix for duplicate path warning
      680dd0ed
    • Phil Renaud's avatar
      Disable path input when model is not new (#13273) · 6b495cf7
      Phil Renaud authored
      * Disable path input when model is not new
      
      * isDisabled tests for secure variables path
      6b495cf7
    • Tim Gross's avatar
      ffbc7ebc
    • Charlie Voiselle's avatar
      73c21e85
    • Tim Gross's avatar
      keyring replication (#13167) · 89f9e087
      Tim Gross authored
      Replication for the secure variables keyring. Because only key
      metadata is stored in raft, we need to distribute key material
      out-of-band from raft replication. A goroutine runs on each server and
      watches for changes to the `RootKeyMeta`. When a new key is received,
      attempt to fetch the key from the leader. If the leader doesn't have
      the key (which may happen if a key is rotated right before a leader
      transition), try to get the key from any peer.
      89f9e087
    • Phil Renaud's avatar
      Secure Variables: Build a path tree and traverse it at /variables/*path (#13202) · 7442901a
      Phil Renaud authored
      * Recursive trie-building with variable paths
      
      * tree structure applied to new path routes and a new util class
      
      * Breadcrumbs for SV paths and prompt when nothing exists at a path
      
      * Lint and test cleanup
      
      * Pre-review cleanup
      
      * lintfix
      
      * Abstracted pathtree each-ins into a new component class
      
      * Path tree component styles
      
      * Types added and PR feedback addressed
      
      * Path tree to variable paths
      
      * Slightly simpler path QP mods
      
      * More pr feedback handling
      
      * Trim moved into a function on variable model
      
      * Traversal and compaction tests for PathTree
      
      * Trim Path tests
      
      * Variable-paths component tests
      
      * Lint fixup for tests
      7442901a