Revert "#319 Fix OVH Invalid Signature (#414)" (#426)

This reverts commit eaa7200734.
This commit is contained in:
Frederic R
2023-02-02 00:37:38 +00:00
committed by GitHub
parent eaa7200734
commit 228fc507a7

View File

@@ -20,8 +20,8 @@ func (p *Provider) setHeaderAuth(header http.Header, timestamp int64,
header.Add("X-Ovh-Consumer", p.consumerKey)
sha1Sum := sha1.Sum([]byte(
p.appSecret + "+" + p.consumerKey + "+" + httpMethod + "+" +
url.String() + "+" + string(body) + "+" + strconv.Itoa(int(timestamp)),
p.appSecret + "+" + p.consumerKey + "+" + httpMethod + "+" + p.apiURL.String() + "+" +
url.Path + "+" + string(body) + "+" + strconv.Itoa(int(timestamp)),
))
header.Add("X-Ovh-Signature", fmt.Sprintf("$1$%x", sha1Sum))