Browse Source

Merge branch 'master' of http://git.shengws.com/csx/gdyb

csx 3 years ago
parent
commit
1fb6f3f0b3
1 changed files with 10 additions and 0 deletions
  1. 10 0
      utils/csbhttp/signutil.go

+ 10 - 0
utils/csbhttp/signutil.go View File

23
 	"crypto/hmac"
23
 	"crypto/hmac"
24
 	"crypto/sha1"
24
 	"crypto/sha1"
25
 	"encoding/base64"
25
 	"encoding/base64"
26
+	"fmt"
26
 	"hash"
27
 	"hash"
27
 	"io"
28
 	"io"
28
 	"sort"
29
 	"sort"
76
 
77
 
77
 // 做签名处理
78
 // 做签名处理
78
 func doSign(params map[string]string, secretKey string) string {
79
 func doSign(params map[string]string, secretKey string) string {
80
+	fmt.Println("params")
81
+	fmt.Println(params)
82
+
83
+	fmt.Println("secretKey")
84
+	fmt.Println(secretKey)
85
+
79
 	hs := newParamsSorter(params)
86
 	hs := newParamsSorter(params)
80
 
87
 
88
+	fmt.Println("hs")
89
+	fmt.Println(hs)
90
+
81
 	// Sort the temp by the Ascending Order
91
 	// Sort the temp by the Ascending Order
82
 	hs.Sort()
92
 	hs.Sort()
83
 
93