{"id":"7f734ed0-4f47-46c0-837f-6ee62505abd9","title":"Potential Netcat Reverse Shell Execution","description":"Detects execution of netcat with the \"-e\" flag followed by common shells. This could be a sign of a potential reverse shell setup.","author":"@d4ns4n_, Nasreddine Bencherchali (Nextron Systems)","status":"test","level":"high","date":"2023-04-07","modified":"","tags":["attack.execution","attack.t1059"],"technique_ids":["T1059"],"logsource":{"category":"process_creation","product":"linux"},"falsepositives":["Unlikely"],"references":["https://pentestmonkey.net/cheat-sheet/shells/reverse-shell-cheat-sheet","https://www.revshells.com/","https://www.hackingtutorials.org/networking/hacking-netcat-part-2-bind-reverse-shells/","https://www.infosecademy.com/netcat-reverse-shells/","https://man7.org/linux/man-pages/man1/ncat.1.html"],"source_path":"rules/linux/process_creation/proc_creation_lnx_netcat_reverse_shell.yml","source_sha256":"b3d8c9ea4b7cc26165ca8f16f3d988aecd84c0c6cede8e346c5f6f27569d5c56","source_url":"https://github.com/anpa1200/sigma/blob/b249e9683190cffdcaf188ccbfb90bf4759844e1/rules/linux/process_creation/proc_creation_lnx_netcat_reverse_shell.yml","license":"Detection Rule License 1.1","license_url":"https://github.com/SigmaHQ/Detection-Rule-License/blob/main/LICENSE.Detection.Rules.md","yaml":"title: Potential Netcat Reverse Shell Execution\nid: 7f734ed0-4f47-46c0-837f-6ee62505abd9\nstatus: test\ndescription: Detects execution of netcat with the \"-e\" flag followed by common shells. This could be a sign of a potential reverse shell setup.\nreferences:\n    - https://pentestmonkey.net/cheat-sheet/shells/reverse-shell-cheat-sheet\n    - https://www.revshells.com/\n    - https://www.hackingtutorials.org/networking/hacking-netcat-part-2-bind-reverse-shells/\n    - https://www.infosecademy.com/netcat-reverse-shells/\n    - https://man7.org/linux/man-pages/man1/ncat.1.html\nauthor: '@d4ns4n_, Nasreddine Bencherchali (Nextron Systems)'\ndate: 2023-04-07\ntags:\n    - attack.execution\n    - attack.t1059\nlogsource:\n    category: process_creation\n    product: linux\ndetection:\n    selection_nc:\n        Image|endswith:\n            - '/nc'\n            - '/ncat'\n    selection_flags:\n        CommandLine|contains:\n            - ' -c '\n            - ' -e '\n    selection_shell:\n        CommandLine|contains:\n            - ' ash'\n            - ' bash'\n            - ' bsh'\n            - ' csh'\n            - ' ksh'\n            - ' pdksh'\n            - ' sh'\n            - ' tcsh'\n            - '/bin/ash'\n            - '/bin/bash'\n            - '/bin/bsh'\n            - '/bin/csh'\n            - '/bin/ksh'\n            - '/bin/pdksh'\n            - '/bin/sh'\n            - '/bin/tcsh'\n            - '/bin/zsh'\n            - '$IFSash'\n            - '$IFSbash'\n            - '$IFSbsh'\n            - '$IFScsh'\n            - '$IFSksh'\n            - '$IFSpdksh'\n            - '$IFSsh'\n            - '$IFStcsh'\n            - '$IFSzsh'\n    condition: all of selection_*\nfalsepositives:\n    - Unlikely\nlevel: high\n","validation":"yaml_parsed_not_backend_compiled_or_live_validated","techniques":[{"key":"enterprise/T1059","id":"T1059","name":"Command and Scripting Interpreter","page":"techniques/enterprise/T1059/"}],"data_path":"data/detection-rules/7f734ed0-4f47-46c0-837f-6ee62505abd9.json","kind":"sigma"}
