YARA · Signature Base (Florian Roth / Nextron)
SIGNATURE_BASE_SUSP_PY_Import_Statement_Apr24_1
Detects suspicious Python import statement and socket usage often found in Python reverse shells
Suspicious / huntingSignature Base (Florian Roth / Nextron)Detection Rule License 1.1Compiles with YARA-X
- Author
- Florian Roth
- Date
- 2024-04-15
- Modified
- 2025-03-21
- Score / Quality
- 65 / 85
What this rule detects
Detects suspicious Python import statement and socket usage often found in Python reverse shells
It defines 1 patterns (1 text, 0 hex, 0 regex).
Summary generated from the rule's metadata and condition.
Rule source
susp-py-import-statement-apr24-1.yarDetection Rule License 1.1
rule SIGNATURE_BASE_SUSP_PY_Import_Statement_Apr24_1
{
meta:
= "Detects suspicious Python import statement and socket usage often found in Python reverse shells"
= "Florian Roth"
= "8e05f9a1-40a8-5d01-9e45-8779b0ff7a45"
= "2024-04-15"
= "2025-03-21"
= "https://www.volexity.com/blog/2024/04/12/zero-day-exploitation-of-unauthenticated-remote-code-execution-vulnerability-in-globalprotect-cve-2024-3400/"
= "https://github.com/Neo23x0/signature-base/blob/94a1c48d7ab499879287ff611dfe7f9c56376030/yara/vuln_paloalto_cve_2024_3400_apr24.yar#L67-L79"
= "https://github.com/Neo23x0/signature-base/blob/94a1c48d7ab499879287ff611dfe7f9c56376030/LICENSE"
= "d5c199d9c3e449ca282f0ca91c94ac783709299b3489f7cec38177a2f843b504"
= 65
= 85
= ""
strings:
$x1 = "import sys,socket,os,pty;s=socket.socket("
condition:
1 of them
}
Strings (1 patterns)
| Identifier | Type | Value | Modifiers |
|---|---|---|---|
| $x1 | text | "import sys,socket,os,pty;s=socket.socket(" |
Condition
1 of themIn plain words (Heuristic)
- At least 1 patterns in the rule must match.
Test this rule in your browser
Drop a file to scan it with this rule using YARA-X compiled to WebAssembly. Nothing is uploaded.
Drop a file here or click to chooseScanned locally with YARA-X. Files up to 200 MB.
Licence & attribution
Author: Florian Roth
Source repository: Signature Base (Florian Roth / Nextron) @ 94a1c48d7a
Licence: Detection Rule License 1.1 (repository licence)
Mirrored via YARA Forge 20260927, which prefixes rule names with the source and adds normalised meta fields.
Rule id: 8e05f9a1-40a8-5d01-9e45-8779b0ff7a45
Related rules
- Suspicious / huntingSignature Base (Florian Roth / Nextron)· Florian Roth· 2024-02-23
- Suspicious / huntingSignature Base (Florian Roth / Nextron)· Florian Roth· 2024-02-23
- Suspicious / huntingSignature Base (Florian Roth / Nextron)· Florian Roth· 2024-10-25
- Suspicious / huntingSignature Base (Florian Roth / Nextron)· Florian Roth· 2024-02-23
- Suspicious / huntingSignature Base (Florian Roth / Nextron)· Florian Roth· 2023-08-04
- Suspicious / huntingSignature Base (Florian Roth / Nextron)· Florian Roth· 2024-02-23
- Suspicious / huntingSignature Base (Florian Roth / Nextron)· Florian Roth· 2025-08-07
- Suspicious / huntingSignature Base (Florian Roth / Nextron)· Florian Roth· 2025-02-14