MCPcopy Index your code
hub / github.com/dataease/SQLBot / xor_decrypt

Function xor_decrypt

backend/apps/system/middleware/auth.py:229–233  ·  view source on GitHub ↗
(encrypted_str: str, key: int = 0xABCD1234)

Source from the content-addressed store, hash-verified

227 return False, e
228
229def xor_decrypt(encrypted_str: str, key: int = 0xABCD1234) -> int:
230 encrypted_bytes = base64.urlsafe_b64decode(encrypted_str)
231 hex_str = encrypted_bytes.hex()
232 encrypted_num = int(hex_str, 16)
233 return encrypted_num ^ key

Callers 1

validateEmbeddedMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected