Dépollution Base Vectorielle
Delete all vector points tagged with session_id and timestamp >= injection_timestamp.
Répond aux attaques d’injection de prompt indirectes où un agent ingère du texte non fiable détournant ses instructions système. Isole la session, identifie les jetons malveillants, restaure la mémoire vectorielle et renforce le prompt système.
Isoler la Session Conversationnelle et Geler les Canaux Entrants
Environnement Cible : Redis / Session Store | Réversibilité : FAST
# Mark session status as quarantined in session registryredis-cli HSET "session:$SESSION_ID" "state" "QUARANTINED"redis-cli HSET "session:$SESSION_ID" "quarantine_reason" "INDIRECT_PROMPT_INJECTION"Extraire l’Artefact Malveillant et Restaurer le Point de Contrôle Mémoire
Environnement Cible : Python 3 / Qdrant CLI | Réversibilité : NON_DESTRUCTIVE
# Identify step index where untrusted document was ingestedBAD_STEP=$(grep -n '"role":"user"' /var/log/agents/$AGENT_ID/session_$SESSION_ID.jsonl | tail -n 1 | cut -d: -f1)# Roll back episodic vector embeddings inserted after BAD_STEP timestamppython3 scripts/agent_memory_rollback.py \ --agent-id $AGENT_ID \ --session-id $SESSION_ID \ --before-step $BAD_STEP \ --vector-db-url http://qdrant:6333Dépollution Base Vectorielle
Delete all vector points tagged with session_id and timestamp >= injection_timestamp.
Purge Fenêtre de Contexte
Rebuild context window containing only verified user messages prior to injection payload.
Réancrage Constitutionnel
Prepend cryptographically sealed constitutional safety prompts into system context.