signature should be base64
This commit is contained in:
parent
9757609d61
commit
2bf0517c3f
@ -2,6 +2,7 @@ package proxyd
|
||||
|
||||
import (
|
||||
"context"
|
||||
"encoding/base64"
|
||||
"encoding/json"
|
||||
"strings"
|
||||
"sync"
|
||||
@ -21,7 +22,7 @@ type StaticMethodHandler struct {
|
||||
|
||||
func (e *StaticMethodHandler) key(req *RPCReq) string {
|
||||
// signature is a cache-friendly base64-encoded string with json.RawMessage param contents
|
||||
signature := string(req.Params)
|
||||
signature := base64.StdEncoding.EncodeToString(req.Params)
|
||||
return strings.Join([]string{"cache", req.Method, signature}, ":")
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user