MCPcopy Create free account
hub / github.com/GoEdgeLab/EdgeNode / SimpleEncryptMap

Function SimpleEncryptMap

internal/utils/encrypt.go:91–98  ·  view source on GitHub ↗
(m maps.Map)

Source from the content-addressed store, hash-verified

89}
90
91func SimpleEncryptMap(m maps.Map) (base64String string, err error) {
92 mJSON, err := json.Marshal(m)
93 if err != nil {
94 return "", err
95 }
96 var data = SimpleEncrypt(mJSON)
97 return base64.StdEncoding.EncodeToString(data), nil
98}
99
100func SimpleDecryptMap(base64String string) (maps.Map, error) {
101 data, err := base64.StdEncoding.DecodeString(base64String)

Callers 1

TestSimpleEncryptMapFunction · 0.92

Calls 1

SimpleEncryptFunction · 0.85

Tested by 1

TestSimpleEncryptMapFunction · 0.74