Detectionhightest

Vim GTFOBin Abuse - Linux

Detects the use of "vim" and it's siblings commands to execute a shell or proxy commands. Such behavior may be associated with privilege escalation, unauthorized command execution, or to break out from restricted environments.

Open in Detection LabConvert ruleBuild Package
Nasreddine Bencherchali, Luc GénauxCreated 2022-12-28Updated 2026-06-057ab8f73a-fcff-428b-84aa-6a5ff7877dealinux
Log Source
LinuxProcess Creation
ProductLinux← raw: linux
CategoryProcess Creation← raw: process_creation

Events generated when a new process is spawned on the system. Covers command-line arguments, parent/child relationships, and process metadata.

Detection Logic
Detection Logic2 selectors
detection:
    selection_img:
        Image|endswith:
            - '/rvim'
            - '/vi'
            - '/vim'
            - '/vimdiff'
        CommandLine|contains:
            - ' --cmd '
            - ' -c'
    selection_cli:
        CommandLine|contains:
            - ':!/'
            - ':!$'
            - ':!..'
            - ':lua '
            - ':py '
            - ':shell'
            - '/bin/bash'
            - '/bin/dash'
            - '/bin/fish'
            - '/bin/sh'
            - '/bin/csh'
            - '/bin/ksh'
            - '/bin/zsh'
            - '/bin/tmux'
    condition: all of selection_*
False Positives
Unknown

False positive likelihood has not been assessed. Additional context may be needed during triage.

Rule Metadata
Rule ID
7ab8f73a-fcff-428b-84aa-6a5ff7877dea
Status
test
Level
high
Type
Detection
Created
2022-12-28
Modified
2026-06-05
Path
rules/linux/process_creation/proc_creation_lnx_vim_shell_execution.yml
Raw Tags
attack.executionattack.discoveryattack.t1059attack.t1083
View on GitHub