From 5945ed41252b487a0c4d4486e57fdf6fb02ce768 Mon Sep 17 00:00:00 2001 From: tiedu Date: Fri, 4 May 2018 11:34:44 +0800 Subject: [PATCH] modify get_auth --- qcloud_cos/cos_auth.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qcloud_cos/cos_auth.py b/qcloud_cos/cos_auth.py index de6af792..d1f10c49 100644 --- a/qcloud_cos/cos_auth.py +++ b/qcloud_cos/cos_auth.py @@ -54,7 +54,7 @@ def __call__(self, r): path = self._path uri_params = self._params headers = filter_headers(r.headers) - uri_params = dict([(k.lower(), v.lower()) for k, v in uri_params.items()]) + uri_params = dict([(k.lower(), v) for k, v in uri_params.items()]) # reserved keywords in headers urlencode are -_.~, notice that / should be encoded and space should not be encoded to plus sign(+) headers = dict([(k.lower(), quote(v, '-_.~')) for k, v in headers.items()]) # headers中的key转换为小写,value进行encode format_str = "{method}\n{host}\n{params}\n{headers}\n".format(