ChainSecretStore
in package
implements
WritableSecretStoreInterface
Table of Contents
Interfaces
Properties
Methods
- __construct() : mixed
- delete() : void
- Delete a secret value.
- exists() : bool
- Return true if a secret name exists without revealing or decrypting its value.
- get() : SensitiveString|null
- Fetch a secret value.
- list() : array<int, string>
- put() : void
- Store or replace a secret value.
- rotatedAt() : DateTimeImmutable|null
- Return when a secret was last rotated, if known, without revealing the value.
- writableStore() : WritableSecretStoreInterface
- Resolve the explicitly configured writable store.
Properties
$stores read-only
private
array<string|int, mixed>
$stores
$writeTo read-only
private
string|null
$writeTo
= null
Methods
__construct()
public
__construct(array<string, SecretStoreInterface> $stores[, string|null $writeTo = null ]) : mixed
Parameters
- $stores : array<string, SecretStoreInterface>
- $writeTo : string|null = null
delete()
Delete a secret value.
public
delete(string $name) : void
Parameters
- $name : string
-
Secret name
Tags
exists()
Return true if a secret name exists without revealing or decrypting its value.
public
exists(string $name) : bool
Parameters
- $name : string
Tags
Return values
boolget()
Fetch a secret value.
public
get(string $name) : SensitiveString|null
Parameters
- $name : string
-
Secret name
Tags
Return values
SensitiveString|nulllist()
public
list([string $prefix = '' ]) : array<int, string>
Parameters
- $prefix : string = ''
Tags
Return values
array<int, string> —Secret names only; never values.
put()
Store or replace a secret value.
public
put(string $name, SensitiveString $value) : void
Parameters
- $name : string
-
Secret name
- $value : SensitiveString
-
Secret value
Tags
rotatedAt()
Return when a secret was last rotated, if known, without revealing the value.
public
rotatedAt(string $name) : DateTimeImmutable|null
Parameters
- $name : string
-
Secret name
Tags
Return values
DateTimeImmutable|nullwritableStore()
Resolve the explicitly configured writable store.
private
writableStore() : WritableSecretStoreInterface