diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-12 03:50:40 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-12 03:50:40 +0000 |
commit | fc53809803cd2bc2434e312b19a18fa36776da12 (patch) | |
tree | b4b43bd6538f51965ce32856e9c053d0f90919c8 /src/shared/machine-credential.h | |
parent | Adding upstream version 255.5. (diff) | |
download | systemd-fc53809803cd2bc2434e312b19a18fa36776da12.tar.xz systemd-fc53809803cd2bc2434e312b19a18fa36776da12.zip |
Adding upstream version 256.upstream/256
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/shared/machine-credential.h')
-rw-r--r-- | src/shared/machine-credential.h | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/src/shared/machine-credential.h b/src/shared/machine-credential.h index c9044a2..182f077 100644 --- a/src/shared/machine-credential.h +++ b/src/shared/machine-credential.h @@ -5,10 +5,18 @@ typedef struct MachineCredential { char *id; - void *data; + char *data; size_t size; } MachineCredential; -void machine_credential_free_all(MachineCredential *creds, size_t n); -int machine_credential_set(MachineCredential **credentials, size_t *n_credentials, const char *cred_string); -int machine_credential_load(MachineCredential **credentials, size_t *n_credentials, const char *cred_path); +typedef struct MachineCredentialContext { + MachineCredential *credentials; + size_t n_credentials; +} MachineCredentialContext; + +void machine_credential_context_done(MachineCredentialContext *ctx); + +bool machine_credentials_contains(const MachineCredentialContext *ctx, const char *id); + +int machine_credential_set(MachineCredentialContext *ctx, const char *cred_str); +int machine_credential_load(MachineCredentialContext *ctx, const char *cred_path); |