'Get a random hex string of the specified length.'

def _get_random_string(self, length):

    rndstr = ''
    while (len(rndstr) < length):
        rndstr += hashlib.sha224(os.urandom(255)).hexdigest()
    return rndstr[0:length]
