6 ms·
# secret_key = random.randrange(1, bitcoin_gen.n) # this is how you _would_ do it I know the article is mainly for learning purposes but someone should point o
by cf499 5y ago
# secret_key = random.randrange(1, bitcoin_gen.n) # this is how you _would_ do it
I know the article is mainly for learning purposes but someone should point out that the `random` module in python is not meant for cryptography. Please use the built-in `secrets` module or `os.urandom` instead.