artisan_keystore 2.1.1

A keystore server designed for AH
Documentation
//! Definitions for key records stored in the key store.
// use dusa_collection_utils::stringy::Stringy;
use serde::{Deserialize, Serialize};

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, PartialOrd, Ord, Eq)]
/// Indicates the current lifecycle stage of a key.
pub enum KeyStatus {
    Active,
    NearExpiration,
    Expired,
    Invalid,
}

#[derive(Serialize, Deserialize, Debug, Clone)]
/// Representation of a cryptographic key and its metadata.
pub struct Key {
    pub id: String,
    pub value: Vec<u8>,
    // pub hash: Stringy,
    pub legnth: usize,
    pub ttl: u64,
    pub created_at: u64,
    pub expires_at: u64,
    pub version: u32,
    pub status: KeyStatus,
}