MCPcopy Create free account
hub / github.com/Fadi002/de4py / d1

Method d1

de4py/engines/onyx/string_decoder.py:276–280  ·  view source on GitHub ↗
(m)

Source from the content-addressed store, hash-verified

274 r'(?:\.decode\s*\([^)]*\))?'
275 )
276 def d1(m):
277 try:
278 return repr(bytes.fromhex(m.group(1).replace(' ','').replace('\n','')).decode('utf-8', errors='replace'))
279 except Exception:
280 return m.group(0)
281 source = p1.sub(d1, source)
282 p2 = re.compile(
283 r'codecs\.decode\s*\(\s*b?["\']([0-9a-fA-F]+)["\']\s*,\s*["\']hex(?:_codec)?["\']\s*\)'

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected