1use std::path::PathBuf;
2
3use clap::{ArgGroup, Parser};
4
5#[derive(Parser, Debug)]
7#[command(name = "sub-solver")]
8pub struct Args {
9 #[clap(flatten)]
10 pub ciphertext: Ciphertext,
11
12 #[arg(short, long)]
14 pub wordlist: Option<String>,
15
16 #[arg(short, long)]
18 pub key: Option<String>,
19
20 #[arg(short = 'F', long)]
22 pub fill_key: bool,
23
24 #[arg(short, long)]
26 pub no_cache: bool,
27}
28
29#[derive(Parser, Debug)]
30#[clap(group = ArgGroup::new("ciphertext").required(true).multiple(false))]
31pub struct Ciphertext {
32 #[clap(group = "ciphertext", short, long)]
34 pub string: Option<String>,
35
36 #[clap(group = "ciphertext", short, long)]
38 pub file: Option<PathBuf>,
39}