def _stub_urandom(n):
 randomData = [random.randrange(256) for n in xrange(n)]
 return ''.join(map(chr, randomData))

def _stub_urandom ( n ) : randomData = [ random . randrange ( 256 ) for n in xrange ( n ) ] return '' . join ( map ( chr , randomData ) )
provide random data in versions of python prior to 2 .