Generate new random Bitcoin private key, using os.urandom and
    double-sha256.

def genkey(outcompressed=True,prefix='80'):
    '''
    Generate new random Bitcoin private key, using os.urandom and
    double-sha256.
    '''

    key = prefix + genkeyhex()
    if outcompressed:
        key = key + '01'
    return b58e(key)