The RandomGenerator class

The security.RandomGenerator class includes methods for creating random strings or numbers.

This class is provided in the security C-Extension library; To use this class, import the security package with:
IMPORT security