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 0x7f1bf5a95250>]) – The method guide to get.

  • out (Annotated[Path | None, <typer.models.OptionInfo object at 0x7f1bf5a95110>]) – 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 0x7f1bf5a95790>]) – The primitive to get a wrapper of.

  • directory (Annotated[str | None, <typer.models.OptionInfo object at 0x7f1bf5a95810>]) – Where to copy the template to, current working directory by default.

  • language (Annotated[str, <typer.models.OptionInfo object at 0x7f1bf5a95910>]) – The programming language of the wrapper.

  • show_languages (Annotated[bool, <typer.models.OptionInfo object at 0x7f1bf5a95a10>]) – 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 0x7f1bf5a95b10>]) – Whether to overwrite existing templates in the given directory.

  • wrapper_example (Annotated[int, <typer.models.OptionInfo object at 0x7f1bf5a95c50>]) – 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 0x7f1bf5a95e10>]) – The name of the file to use.

  • bit_count (Annotated[int, <typer.models.OptionInfo object at 0x7f1bf5a95e90>]) – 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 0x7f1bf5a95f90>]) – Calls crypto_condor.cli.callbacks.print_testu01_install_dir().

  • filename (Annotated[str, <typer.models.OptionInfo object at 0x7f1bf5a96090>]) – Name of the file to save results.

  • no_save (Annotated[bool, <typer.models.OptionInfo object at 0x7f1bf5a96150>]) – 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 0x7f1bf65bfc90>]) – The level of verbosity. Typer counts the number of occurrences of ‘-v’ when using the CLI.

  • version (Annotated[bool, <typer.models.OptionInfo object at 0x7f1bf5a96350>]) – Displays the version and exits. It’s an eager option that uses the print_version() callback.