This is a “Hazardous Materials” module. You should ONLY use it if you’re 100% absolutely sure that you know what you’re doing because this module is full of land mines, dragons, and dinosaurs with laser guns.


Getting a backend

cryptography was originally designed to support multiple backends, but this design has been deprecated.

You can get the default backend by calling default_backend().

Returns:An object that provides at least CipherBackend, HashBackend, and HMACBackend.