vaultrs/api/ssh/
responses.rsuse std::collections::HashMap;
use serde::{Deserialize, Serialize};
#[derive(Deserialize, Debug, Serialize)]
pub struct ReadRoleResponse {
pub algorithm_signer: String,
pub allow_bare_domains: bool,
pub allow_host_certificates: bool,
pub allow_subdomains: bool,
pub allow_user_certificates: bool,
pub allow_user_key_ids: bool,
pub allowed_user_key_lengths: Option<HashMap<String, u64>>,
pub allowed_critical_options: Option<String>,
pub allowed_domains: String,
pub allowed_extensions: String,
pub allowed_users: String,
pub allowed_users_template: bool,
pub admin_user: Option<String>,
pub cidr_list: Option<String>,
pub default_critical_options: Option<HashMap<String, String>>,
pub default_extensions: Option<HashMap<String, String>>,
pub default_extensions_template: Option<bool>,
pub default_user: String,
pub key_bits: u64,
pub key_id_format: String,
pub key_type: String,
pub max_ttl: u64,
pub ttl: u64,
}
#[derive(Deserialize, Debug, Serialize)]
pub struct ListRolesResponse {
pub keys: Vec<String>,
pub key_info: HashMap<String, KeyInfo>,
}
#[derive(Deserialize, Debug, Serialize)]
pub struct KeyInfo {
pub key_type: String,
}
#[derive(Deserialize, Debug, Serialize)]
pub struct ListZeroAddressRolesResponse {
pub roles: Vec<String>,
}
#[derive(Deserialize, Debug, Serialize)]
pub struct GenerateSSHCredsResponse {
pub allowed_users: Option<String>,
pub admin_user: Option<String>,
pub cidr_list: Option<String>,
pub default_user: Option<String>,
pub exclude_cidr_list: Option<String>,
pub install_script: Option<String>,
pub key: String,
pub key_bits: Option<u64>,
pub key_option_specs: Option<String>,
pub key_type: String,
pub port: u64,
}
#[derive(Deserialize, Debug, Serialize)]
pub struct ListRolesByIPResponse {
pub roles: Vec<String>,
}
#[derive(Deserialize, Debug, Serialize)]
pub struct VerifySSHOTPResponse {
pub ip: String,
pub username: String,
}
#[derive(Deserialize, Debug, Serialize)]
pub struct SubmitCAInfoResponse {
pub public_key: String,
}
#[derive(Deserialize, Debug, Serialize)]
pub struct ReadPublicKeyResponse {
pub public_key: String,
}
#[derive(Deserialize, Debug, Serialize)]
pub struct SignSSHKeyResponse {
pub serial_number: String,
pub signed_key: String,
}