bookclerk_library::entities::encrypted_secrets

Development These docs follow the development version and change with every merge.

Last updated View as Markdown

SeaORM entity for the encrypted_secrets table.

Retained in the schema and entities per the multi-storefront design; the encryption / secrets-file removal work lives in crate::secrets.

Item Kind Summary
Model struct Row shape for this table (DeriveEntityModel).
ColumnIter struct An iterator over the variants of [Column]
Entity struct Generated by sea-orm-macros
PrimaryKeyIter struct An iterator over the variants of [PrimaryKey]
ActiveModel struct Generated by sea-orm-macros
RelationIter struct An iterator over the variants of [Relation]
Column enum Generated by sea-orm-macros
PrimaryKey enum Generated by sea-orm-macros
Relation enum Declared SeaORM relations (none unless FK edges are modeled).

Structs

Model

pub struct Model {
    pub id: i64,
    pub kind: String,
    pub provider: Option<String>,
    pub account_type: String,
    pub account_id: Option<String>,
    pub name: String,
    pub format: String,
    pub ciphertext: Vec<u8>,
    pub kdf_algorithm: Option<String>,
    pub kdf_salt: Option<Vec<u8>>,
    pub kdf_m_cost: Option<i64>,
    pub kdf_t_cost: Option<i64>,
    pub kdf_p_cost: Option<i64>,
    pub cipher_algorithm: Option<String>,
    pub cipher_nonce: Option<Vec<u8>>,
    pub created_at: String,
    pub updated_at: String,
}

Row shape for this table (DeriveEntityModel).

Fields

  • id: Surrogate primary key assigned by the database.
  • kind: Secret kind discriminator (source_auth, s3, …).
  • provider: External identity or integration provider id (for example ABS).
  • account_type: Ownership namespace: crate::secrets::secret_account_type.
  • account_id: Store or operator account id this row belongs to.
  • name: Human-readable or logical name for this row.
  • format: Sealing format tag (sealed-v1, legacy json-encrypted, …).
  • ciphertext: Encrypted payload bytes for this secret.
  • kdf_algorithm: KDF algorithm id for legacy rows (for example argon2id).
  • kdf_salt: Random salt for legacy Argon2 key derivation.
  • kdf_m_cost: Argon2 memory cost in KiB for legacy rows.
  • kdf_t_cost: Argon2 time cost (iterations) for legacy rows.
  • kdf_p_cost: Argon2 parallel lane count stored for legacy json-encrypted rows.
  • cipher_algorithm: AEAD algorithm id (for example xchacha20poly1305).
  • cipher_nonce: AEAD nonce bytes used with ciphertext.
  • created_at: RFC 3339 timestamp when the row was inserted.
  • updated_at: RFC 3339 timestamp when the row was last modified.

Model::into_ex

pub fn into_ex(self) -> Self

Generated by sea-orm-macros

Implements: Clone, Debug, Eq, From<Model>, FromQueryResult, IntoActiveModel<ActiveModel>, ModelTrait, PartialEq, TryFrom<ActiveModel>, TryIntoModel<Model>

ColumnIter

pub struct ColumnIter {
    /* private fields */
}

An iterator over the variants of Column

Implements: Clone, Debug, DoubleEndedIterator, ExactSizeIterator, FusedIterator, Iterator

Entity

pub struct Entity;

Generated by sea-orm-macros

Implements: Clone, Copy, Debug, Default, EntityName, EntityTrait, Iden, IdenStatic

PrimaryKeyIter

pub struct PrimaryKeyIter {
    /* private fields */
}

An iterator over the variants of PrimaryKey

Implements: Clone, Debug, DoubleEndedIterator, ExactSizeIterator, FusedIterator, Iterator

ActiveModel

pub struct ActiveModel {
    pub id: ActiveValue<i64>,
    pub kind: ActiveValue<String>,
    pub provider: ActiveValue<Option<String>>,
    pub account_type: ActiveValue<String>,
    pub account_id: ActiveValue<Option<String>>,
    pub name: ActiveValue<String>,
    pub format: ActiveValue<String>,
    pub ciphertext: ActiveValue<Vec<u8>>,
    pub kdf_algorithm: ActiveValue<Option<String>>,
    pub kdf_salt: ActiveValue<Option<Vec<u8>>>,
    pub kdf_m_cost: ActiveValue<Option<i64>>,
    pub kdf_t_cost: ActiveValue<Option<i64>>,
    pub kdf_p_cost: ActiveValue<Option<i64>>,
    pub cipher_algorithm: ActiveValue<Option<String>>,
    pub cipher_nonce: ActiveValue<Option<Vec<u8>>>,
    pub created_at: ActiveValue<String>,
    pub updated_at: ActiveValue<String>,
}

Generated by sea-orm-macros

Fields

  • id: Generated by sea-orm-macros
  • kind: Generated by sea-orm-macros
  • provider: Generated by sea-orm-macros
  • account_type: Generated by sea-orm-macros
  • account_id: Generated by sea-orm-macros
  • name: Generated by sea-orm-macros
  • format: Generated by sea-orm-macros
  • ciphertext: Generated by sea-orm-macros
  • kdf_algorithm: Generated by sea-orm-macros
  • kdf_salt: Generated by sea-orm-macros
  • kdf_m_cost: Generated by sea-orm-macros
  • kdf_t_cost: Generated by sea-orm-macros
  • kdf_p_cost: Generated by sea-orm-macros
  • cipher_algorithm: Generated by sea-orm-macros
  • cipher_nonce: Generated by sea-orm-macros
  • created_at: Generated by sea-orm-macros
  • updated_at: Generated by sea-orm-macros

Implements: ActiveModelBehavior, ActiveModelTrait, Clone, Debug, Default, From<Model>, IntoActiveModel<ActiveModel>, PartialEq, TryFrom<ActiveModel>, TryIntoModel<Model>

RelationIter

pub struct RelationIter {
    /* private fields */
}

An iterator over the variants of Relation

Implements: Clone, Debug, DoubleEndedIterator, ExactSizeIterator, FusedIterator, Iterator

Enums

Column

pub enum Column {
    Id,
    Kind,
    Provider,
    AccountType,
    AccountId,
    Name,
    Format,
    Ciphertext,
    KdfAlgorithm,
    KdfSalt,
    KdfMCost,
    KdfTCost,
    KdfPCost,
    CipherAlgorithm,
    CipherNonce,
    CreatedAt,
    UpdatedAt,
}

Generated by sea-orm-macros

Variants

  • Id: Generated by sea-orm-macros
  • Kind: Generated by sea-orm-macros
  • Provider: Generated by sea-orm-macros
  • AccountType: Generated by sea-orm-macros
  • AccountId: Generated by sea-orm-macros
  • Name: Generated by sea-orm-macros
  • Format: Generated by sea-orm-macros
  • Ciphertext: Generated by sea-orm-macros
  • KdfAlgorithm: Generated by sea-orm-macros
  • KdfSalt: Generated by sea-orm-macros
  • KdfMCost: Generated by sea-orm-macros
  • KdfTCost: Generated by sea-orm-macros
  • KdfPCost: Generated by sea-orm-macros
  • CipherAlgorithm: Generated by sea-orm-macros
  • CipherNonce: Generated by sea-orm-macros
  • CreatedAt: Generated by sea-orm-macros
  • UpdatedAt: Generated by sea-orm-macros

Implements: Clone, ColumnTrait, Copy, Debug, FromStr, Iden, IdenStatic, IntoEnumIterator

PrimaryKey

pub enum PrimaryKey {
    Id,
}

Generated by sea-orm-macros

Variants

  • Id: Generated by sea-orm-macros

Implements: Clone, Copy, Debug, Iden, IdenStatic, IntoEnumIterator, PrimaryKeyToColumn, PrimaryKeyTrait

Relation

pub enum Relation {}

Declared SeaORM relations (none unless FK edges are modeled).

Implements: Clone, Copy, Debug, IntoEnumIterator, RelationTrait

Generated from crates/bookclerk-library at main · View as Markdown