MCPcopy Create free account
hub / github.com/supabase/auth / ParseEncryptedString

Function ParseEncryptedString

internal/crypto/crypto.go:96–112  ·  view source on GitHub ↗
(str string)

Source from the content-addressed store, hash-verified

94}
95
96func ParseEncryptedString(str string) *EncryptedString {
97 if !strings.HasPrefix(str, "{") {
98 return nil
99 }
100
101 var es EncryptedString
102
103 if err := json.Unmarshal([]byte(str), &es); err != nil {
104 return nil
105 }
106
107 if !es.IsValid() {
108 return nil
109 }
110
111 return &es
112}
113
114func (es *EncryptedString) String() string {
115 out := must(json.Marshal(es))

Callers 9

performVerifyFlowFunction · 0.92
GetClientSecretMethod · 0.92
GetSecretMethod · 0.92
AuthenticateMethod · 0.92
GetOtpCodeMethod · 0.92

Calls 2

IsValidMethod · 0.95
UnmarshalMethod · 0.45

Tested by 4

performVerifyFlowFunction · 0.74