{
  "model_id": "SOC.096",
  "name": "History Symlinked To /dev/null",
  "description": "bash_history symlinked to /dev/null — attacker hiding commands without deleting the file.",
  "threshold": 0.8,
  "evaluations": [
    {
      "name": "Write",
      "type": "comparison",
      "left": "event.type",
      "operator": "==",
      "right": "file.critical.write",
      "weight": 3
    },
    {
      "name": "HistFile",
      "type": "comparison",
      "left": "event.raw.path",
      "operator": "LIKE",
      "right": "%.bash_history%",
      "weight": 4
    },
    {
      "name": "DevNull",
      "type": "comparison",
      "left": "event.raw.target",
      "operator": "==",
      "right": "/dev/null",
      "weight": 5
    },
    {
      "name": "Logic",
      "type": "logical",
      "operator": "AND",
      "operands": [
        "Write",
        "HistFile",
        "DevNull"
      ],
      "weight": 5
    }
  ],
  "actions": [
    {
      "type": "emit_alert",
      "reason": "Bash history symlinked to /dev/null — anti-forensics."
    }
  ],
  "mitre_tactics": [
    "Defense Evasion"
  ],
  "mitre_techniques": [
    "T1562.006",
    "T1070"
  ],
  "severity": "high",
  "observables": [
    "event.raw.path",
    "event.actor.user"
  ]
}
