Skip to content

Commonly used functions #6

@AppleMangoOrange

Description

@AppleMangoOrange

Functions that are most commonly used should be in an easily-accessible module (such as src/cryptobible/__init__.py). Functions which are already part of the dependencies of this module should not be included here. Same goes for functions that are not useful in a script by themselves and can be achieved using online tools (like xor key length or frequency analysis). Some functions include:

  • bytes_to_int() (This can already easily be achieved in Python using int.from_bytes(...))
  • int_to_bytes()
  • pad()
  • unpad()
  • base_convert() : Should work with lists and strings
  • str_to_dict: combination of json.loads() and sage_eval() for lists of numbers
  • dict_to_str()
  • xor(): Similar to pwn.xor()
    Please do recommend more if they come to mind

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions