pub struct OutputConfig { /* private fields */ }Expand description
Configuration for ceremony output directory structure.
All ceremony outputs (artifacts and transcript) are written to a structured directory layout:
ceremony-name-20251229T143022/
├── transcript.jsonl
└── artifacts/
├── wrapped_key.bin
├── public_key.pem
└── share_1.txtImplementations§
Source§impl OutputConfig
impl OutputConfig
Sourcepub fn new(base_dir: PathBuf) -> Self
pub fn new(base_dir: PathBuf) -> Self
Create a new output configuration with the given base directory.
Sourcepub fn for_ceremony(parent: Option<PathBuf>, ceremony_name: &str) -> Self
pub fn for_ceremony(parent: Option<PathBuf>, ceremony_name: &str) -> Self
Create output configuration for a ceremony run.
Generates a timestamped directory name from the ceremony name:
<parent>/<ceremony-slug>-<YYYYMMDDTHHMMSS>/
§Arguments
parent- Parent directory (defaults to current directory if None)ceremony_name- Human-readable ceremony name to slugify
Sourcepub fn artifacts_dir(&self) -> PathBuf
pub fn artifacts_dir(&self) -> PathBuf
Returns the path to the artifacts subdirectory.
Sourcepub fn transcript_path(&self) -> PathBuf
pub fn transcript_path(&self) -> PathBuf
Returns the path to the transcript file.
Uses JSONL format (transcript.jsonl) for hash-chained event log.
Sourcepub fn evidence_dir(&self) -> PathBuf
pub fn evidence_dir(&self) -> PathBuf
Returns the path to the evidence subdirectory.
Sourcepub fn artifact_path(
&self,
id: &str,
extension: &str,
) -> Result<PathBuf, PathSafetyError>
pub fn artifact_path( &self, id: &str, extension: &str, ) -> Result<PathBuf, PathSafetyError>
Returns the path for an artifact with the given ID and extension.
The id is treated as untrusted: it becomes a filename directly inside the
artifacts directory, so this rejects any id that contains a path
separator or .. traversal. The resolver already validates artifact ids
at load time; this is the defense-in-depth check at the filesystem
boundary so a future code path cannot reintroduce a traversal.
§Errors
Returns PathSafetyError if id is not a safe single filename.
Trait Implementations§
Source§impl Clone for OutputConfig
impl Clone for OutputConfig
Source§fn clone(&self) -> OutputConfig
fn clone(&self) -> OutputConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more