pub enum NonAdministrativeSecretHandling {
Plaintext,
SystemdCreds,
}
Expand description
The handling of non-administrative secrets.
Non-administrative secrets represent passphrases for (non-Administrator) NetHSM users and may be handled in different ways (e.g. encrypted or not encrypted).
Variants§
Plaintext
Each non-administrative secret is handled in a plaintext file in a non-volatile directory.
§Warning
This variant should only be used in non-production test setups, as it implies the persistence of unencrypted non-administrative secrets on a file system.
SystemdCreds
Each non-administrative secret is encrypted for a specific system user using systemd-creds and the resulting files are stored in a non-volatile directory.
§Note
Although secrets are stored as encrypted strings in dedicated files, they may be extracted under certain circumstances:
- the root account is compromised
- decrypts and exfiltrates all secrets
- the secret is not encrypted using a TPM and the file
/var/lib/systemd/credential.secret
as well as any encrypted secret is exfiltrated
- a specific user is compromised, decrypts and exfiltrates its own ssecret
It is therefore crucial to follow common best-practices:
- rely on a TPM for encrypting secrets, so that files become host-specific
- heavily guard access to all users, especially root
Trait Implementations§
Source§impl Clone for NonAdministrativeSecretHandling
impl Clone for NonAdministrativeSecretHandling
Source§fn clone(&self) -> NonAdministrativeSecretHandling
fn clone(&self) -> NonAdministrativeSecretHandling
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Default for NonAdministrativeSecretHandling
impl Default for NonAdministrativeSecretHandling
Source§fn default() -> NonAdministrativeSecretHandling
fn default() -> NonAdministrativeSecretHandling
Source§impl<'de> Deserialize<'de> for NonAdministrativeSecretHandling
impl<'de> Deserialize<'de> for NonAdministrativeSecretHandling
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl PartialEq for NonAdministrativeSecretHandling
impl PartialEq for NonAdministrativeSecretHandling
Source§fn eq(&self, other: &NonAdministrativeSecretHandling) -> bool
fn eq(&self, other: &NonAdministrativeSecretHandling) -> bool
self
and other
values to be equal, and is used by ==
.impl Copy for NonAdministrativeSecretHandling
impl Eq for NonAdministrativeSecretHandling
impl StructuralPartialEq for NonAdministrativeSecretHandling
Auto Trait Implementations§
impl Freeze for NonAdministrativeSecretHandling
impl RefUnwindSafe for NonAdministrativeSecretHandling
impl Send for NonAdministrativeSecretHandling
impl Sync for NonAdministrativeSecretHandling
impl Unpin for NonAdministrativeSecretHandling
impl UnwindSafe for NonAdministrativeSecretHandling
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.