MCPcopy Create free account
hub / github.com/dedsec1121fk/DedSec / _ensure_device_fp_cookie

Function _ensure_device_fp_cookie

Scripts/ButSystem.py:1378–1388  ·  view source on GitHub ↗

Ensure a stable per-device fingerprint id (random) stored in a cookie. This is *not* hardware fingerprinting; it's a per-browser random id.

(resp=None)

Source from the content-addressed store, hash-verified

1376 nick = u
1377 try:
1378 if r["nickname_enc"]:
1379 nick = aesgcm_decrypt_text(r["nickname_enc"]) or u
1380 except Exception:
1381 nick = u
1382 pic_path = r["pic_path"]
1383 has_pic = bool(pic_path and os.path.exists(pic_path))
1384 on = is_online(u, scope)
1385 cards.append({"username": u, "nickname": nick, "has_pic": has_pic, "online": on})
1386
1387 # Sort: online first, then nickname/username
1388 cards.sort(key=lambda c: (0 if c["online"] else 1, str(c["nickname"]).lower(), c["username"].lower()))
1389
1390 online_count = sum(1 for c in cards if c["online"])
1391 offline_count = len(cards) - online_count

Callers 2

_security_headersFunction · 0.70
device_accessFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected