Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for CreateKey (0.05 sec)

  1. internal/kms/kes.go

    	}
    	return keyInfos, continueAt, nil
    }
    
    // CreateKey tries to create a new key at the KMS with the
    // given key ID.
    //
    // If the a key with the same keyID already exists then
    // CreateKey returns kes.ErrKeyExists.
    func (c *kesConn) CreateKey(ctx context.Context, req *CreateKeyRequest) error {
    	if err := c.client.CreateKey(ctx, req.Name); err != nil {
    		if errors.Is(err, kes.ErrKeyExists) {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sun Aug 18 06:43:03 UTC 2024
    - 7.3K bytes
    - Viewed (0)
  2. internal/kms/stub.go

    			matches = append(matches, madmin.KMSKeyInfo{Name: keyName, CreatedAt: StubCreatedAt, CreatedBy: StubCreatedBy})
    		}
    	}
    
    	return matches, "", nil
    }
    
    // CreateKey creates a new key with the given name.
    func (s *StubKMS) CreateKey(_ context.Context, req *CreateKeyRequest) error {
    	if s.containsKeyName(req.Name) {
    		return ErrKeyExists
    	}
    	s.KeyNames = append(s.KeyNames, req.Name)
    	return nil
    }
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sun Aug 18 06:43:03 UTC 2024
    - 3.6K bytes
    - Viewed (0)
  3. internal/kms/conn.go

    	APIs(context.Context) ([]madmin.KMSAPI, error)
    
    	// Stat returns the current KMS status.
    	Status(context.Context) (map[string]madmin.ItemState, error)
    
    	// CreateKey creates a new key at the KMS with the given key ID.
    	CreateKey(context.Context, *CreateKeyRequest) error
    
    	ListKeys(context.Context, *ListRequest) ([]madmin.KMSKeyInfo, string, error)
    
    	// GenerateKey generates a new data encryption key using the
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sun Aug 18 06:43:03 UTC 2024
    - 5K bytes
    - Viewed (0)
  4. internal/kms/secret-key.go

    		return []madmin.KMSKeyInfo{{Name: s.keyID}}, "", nil
    	}
    	return []madmin.KMSKeyInfo{}, "", nil
    }
    
    // CreateKey returns ErrKeyExists unless req.Name is equal to the secretKey name.
    // The builtin KMS does not support creating multiple keys.
    func (s secretKey) CreateKey(_ context.Context, req *CreateKeyRequest) error {
    	if req.Name != s.keyID {
    		return ErrNotSupported
    	}
    	return ErrKeyExists
    }
    
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Sun Aug 18 06:43:03 UTC 2024
    - 8.3K bytes
    - Viewed (0)
Back to top