cryptography - ghdrako/doc_snipets GitHub Wiki

obraz On hard mathematical problems, such as factorization, cryptographers built primitives, let us say the textbook RSA. Algorithms are then built to give algorithmic details, for example how to perform modular exponentiations or how to avoid weak keys. Then, modes or encapsulations define a real message processing, as in RSA-OAEP RFC8017(https://blog.quarkslab.com/status-of-post-quantum-cryptography-implementation.html#rfc8017). The encrypted messages are part of a cryptographic mechanism which defines among other the encoding of the inputs and outputs, and this mechanism is part of protocols, TLS for example. At the top of our stack stays the cryptosystem, which gathers several protocols, as OpenSSL or MbedTLS may provide. They are also one of the main components to allow the calls to the OS internals and the support of various microarchitectures, which are dependent of the system designs. The legal context may restrict some usage, because of patents or constraints to security parameters, which impact the security context an organization may deploy on their infrastructures. To better take into account all the best implementation practices, a specification work is needed. Ultimately, the standard is deployed in a variety of systems (from smartcard to server), requiring sometimes hardware optimizations to address physical constraints (memory, efficiency, etc.).

The example we gave with RSA can also be done with AES where:

  • inverting AES is the hard mathematical problem;
  • AES is the primitive;
  • arithmetic in finite fields of characteristic two is a component of the algorithm details;
  • AES-GCM is a mode.