hashlib
import binascii
import base64
import json
class Auth():
def __init__(self,Action,SecretId,Secretkey...,Region='ap-guangzhou'):
self.Action,self.SecretId,self.Secretkey,self.Region = Action,SecretId...,Secretkey,Region
self.Timestamp,self.Nonce = int(time.time()),random.randint(0,999999999)...requestUri, ps)
print(source_str)
source_str = bytes(source_str,encoding='utf-8')
secretkey...= bytes(self.Secretkey,encoding='utf-8')
hexstring = hmac.new(secretkey, source_str, hashlib.sha1