Skip to main content

Module key_provider

Module key_provider 

Source
Expand description

Service discovery client key providers.

Re-exportsยง

use crate::config::restricted_discovery::HsClientNickname; ๐Ÿ”’
use derive_more::From; ๐Ÿ”’
use std::collections::BTreeMap; ๐Ÿ”’
use std::fs::DirEntry; ๐Ÿ”’
use derive_more::AsRef; ๐Ÿ”’
use derive_more::Into; ๐Ÿ”’
use fs_mistrust::CheckedDir; ๐Ÿ”’
use fs_mistrust::Mistrust; ๐Ÿ”’
use fs_mistrust::MistrustBuilder; ๐Ÿ”’
use amplify::Getters; ๐Ÿ”’
use serde_with::DisplayFromStr; ๐Ÿ”’
use tor_config::define_list_builder_helper; ๐Ÿ”’
use tor_config::extend_builder::extend_with_replace; ๐Ÿ”’
use tor_config::mistrust::BuilderExt as _; ๐Ÿ”’
use tor_config_path::CfgPath; ๐Ÿ”’
use tor_config_path::CfgPathError; ๐Ÿ”’
use tor_config_path::CfgPathResolver; ๐Ÿ”’
use tor_error::warn_report; ๐Ÿ”’
use tor_hscrypto::pk::HsClientDescEncKeyParseError; ๐Ÿ”’
use tor_persist::slug::BadSlug; ๐Ÿ”’
use crate::internal_prelude::*; ๐Ÿ”’
use tor_config::derive::prelude::*; ๐Ÿ”’

Structsยง

DirectoryKeyProvider
A directory containing the client keys, each in the descriptor:x25519:<base32-encoded-x25519-public-key> format.
DirectoryKeyProviderBuilder
A builder to create an instance of DirectoryKeyProvider.
DirectoryKeyProviderListBuilder
Wrapper struct to help derive_builder find the right types and methods
StaticKeyProvider
A static mapping from HsClientNickname to client discovery keys.
StaticKeyProviderBuilder
Wrapper struct to help derive_builder find the right types and methods

Enumsยง

DirectoryKeyProviderError ๐Ÿ”’
Error type representing an invalid DirectoryKeyProvider.

Functionsยง

build_static ๐Ÿ”’
Helper for building a StaticKeyProvider out of a list of client keys.
read_key_file ๐Ÿ”’
Read the client key at path.

Type Aliasesยง

DirectoryKeyProviderList
The serialized format of a DirectoryKeyProviderListBuilder: