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

Function discussion_voice_stream

Scripts/ButSystem.py:13099–13128  ·  view source on GitHub ↗

Stream a Discussion voice message.

(vid: int)

Source from the content-addressed store, hash-verified

13097"""
13098 require_admin()
13099 try:
13100 log_security_event("admin_action", detail="kick_user", username=current_user(), level="info")
13101 except Exception:
13102 pass
13103 u = (request.form.get("username") or "").strip()
13104 if not u or u == current_user():
13105 return redirect(url_for("admin_panel"))
13106 conn = db_connect()
13107 conn.execute("UPDATE users SET logout_at=? WHERE username=?", (now_z(), u))
13108 conn.commit()
13109 conn.close()
13110 flash(f"Kicked @{u} (forced logout).")
13111 return redirect(url_for("admin_panel"))
13112
13113@app.route("/admin/delete", methods=["POST"])
13114@login_required
13115def admin_delete_user():
13116 """admin_delete_user.
13117
13118Admin-only route handler.
13119
13120This docstring was expanded to make future maintenance easier.
13121
13122Returns:
13123 Varies.
13124"""
13125 require_admin()
13126 try:
13127 log_security_event("admin_action", detail="delete_user", username=current_user(), level="info")
13128 except Exception:
13129 pass
13130 u = (request.form.get("username") or "").strip()
13131 if not u or u == current_user():

Callers

nothing calls this directly

Calls 4

_feature_tables_initFunction · 0.70
db_connectFunction · 0.70
is_encrypted_fileFunction · 0.70
aesgcm_decrypt_generatorFunction · 0.70

Tested by

no test coverage detected