MCPcopy Index your code
hub / github.com/sqlmapproject/sqlmap / cookie_encode

Function cookie_encode

thirdparty/bottle/bottle.py:3458–3465  ·  view source on GitHub ↗

Encode and sign a pickle-able object. Return a (byte) string

(data, key, digestmod=None)

Source from the content-addressed store, hash-verified

3456
3457
3458def cookie_encode(data, key, digestmod=None):
3459 """ Encode and sign a pickle-able object. Return a (byte) string """
3460 depr(0, 13, "cookie_encode() will be removed soon.",
3461 "Do not use this API directly.")
3462 digestmod = digestmod or hashlib.sha256
3463 msg = base64.b64encode(pickle.dumps(data, -1))
3464 sig = base64.b64encode(hmac.new(tob(key), msg, digestmod=digestmod).digest())
3465 return tob('!') + sig + tob('?') + msg
3466
3467
3468def cookie_decode(data, key, digestmod=None):

Callers

nothing calls this directly

Calls 2

deprFunction · 0.85
tobFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…