7
0

delete sign value

This commit is contained in:
liangzy 2020-08-07 19:51:19 +08:00
parent 3c03b841cf
commit e7a20f306b

View File

@ -26,6 +26,7 @@ func signRpcRequest(request requests.AcsRequest, signer Signer) (err error) {
request.SetStringToSign(stringToSign)
signature := signer.Sign(stringToSign, "&")
request.GetQueryParams()["sign"] = signature
debug("grsdk sign %s", signature)
return
}
@ -106,7 +107,7 @@ func unsignRpcRequest(request *http.Request, signer Signer) (err error) {
stringToSign = strings.Replace(stringToSign, "%7E", "~", -1)
stringToSign = url.QueryEscape(stringToSign)
stringToSign = request.Method + "&%2F&" + stringToSign
debug("grsdk singstring %s", stringToSign)
debug("grsdk signstring %s", stringToSign)
if timestamp, err := strconv.ParseInt(signParams["access_time"], 10, 64); err != nil {
return err