How to use the mnemonic.prepare_seed function in mnemonic

To help you get started, we’ve selected a few mnemonic examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github UlordChain / Ulord-platform / Uwallet / uwallet / ulord.py View on Github external
def is_new_seed(x, prefix=version.SEED_PREFIX):
    import mnemonic
    x = mnemonic.prepare_seed(x)
    s = hmac_sha_512("Seed version", x.encode('utf8')).encode('hex')
    return s.startswith(prefix)
github UlordChain / Uwallet / uwallet / unet.py View on Github external
def is_new_seed(x, prefix=version.SEED_PREFIX):
    import mnemonic
    x = mnemonic.prepare_seed(x)
    s = hmac_sha_512("Seed version", x.encode('utf8')).encode('hex')
    return s.startswith(prefix)