import hashlib
h6=hashlib.md5()ctime=time.time()h6.update(bytes(str(ctime),encoding='utf-8'))token=h6.hexdigest()#digest()返回的是b格式