Main¶
Main CLI module.
- crypto_condor.cli.main.method(primitive, out=None)¶
Command to get a method guide in Markdown.
- Parameters:
primitive (Annotated[str, <typer.models.ArgumentInfo object at 0x7f86b7e0e6d0>]) – The method guide to get.
out (Annotated[Path | None, <typer.models.OptionInfo object at 0x7f86b7e0e790>]) – Where to save the guide.
- crypto_condor.cli.main.list_command()¶
List the currently supported primitives.
- crypto_condor.cli.main.wrap(
- primitive,
- directory=None,
- language='',
- show_languages=False,
- force=False,
- wrapper_example=0,
Fetches a wrapper template.
- Parameters:
primitive (Annotated[str, <typer.models.ArgumentInfo object at 0x7f86b7e0ea50>]) – The primitive to get a wrapper of.
directory (Annotated[str | None, <typer.models.OptionInfo object at 0x7f86b7e0ead0>]) – Where to copy the template to, current working directory by default.
language (Annotated[str, <typer.models.OptionInfo object at 0x7f86b7e0ebd0>]) – The programming language of the wrapper.
show_languages (Annotated[bool, <typer.models.OptionInfo object at 0x7f86b7e0ecd0>]) – An option to display a list of primitives and the languages that have corresponding wrappers available. It’s an eager option that uses the
list_languages()
callback, so the argument is not used in the function itself.force (Annotated[bool, <typer.models.OptionInfo object at 0x7f86b7e0edd0>]) – Whether to overwrite existing templates in the given directory.
wrapper_example (Annotated[int, <typer.models.OptionInfo object at 0x7f86b7e0eed0>]) – Number of the example to get.
- crypto_condor.cli.main.testu01(file, bit_count=0, where=False, filename='', no_save=False)¶
Tests the output of a PRNG using TestU01.
- Parameters:
file (Annotated[Path, <typer.models.ArgumentInfo object at 0x7f86b7e0f090>]) – The name of the file to use.
bit_count (Annotated[int, <typer.models.OptionInfo object at 0x7f86b7e0f110>]) – The number of bits to test. Must be less or equal to the actual size of the file.
where (Annotated[bool, <typer.models.OptionInfo object at 0x7f86b7e0f210>]) – Calls
crypto_condor.cli.callbacks.print_testu01_install_dir()
.filename (Annotated[str, <typer.models.OptionInfo object at 0x7f86b7e0f310>]) – Name of the file to save results.
no_save (Annotated[bool, <typer.models.OptionInfo object at 0x7f86b7e0f410>]) – Do not save results or prompt the user.
- crypto_condor.cli.main.main(verbose=0, version=False)¶
Main function.
- Parameters:
verbose (Annotated[int, <typer.models.OptionInfo object at 0x7f86b81e8550>]) – The level of verbosity. Typer counts the number of occurrences of ‘-v’ when using the CLI.
version (Annotated[bool, <typer.models.OptionInfo object at 0x7f86b7e0f610>]) – Displays the version and exits. It’s an eager option that uses the
print_version()
callback.