Query: detect Detects the use of Python's base64 decoding functions in command line executions on Linux systems. Malicious scripts oft in logs
Matching passage: Sigma rule: Detects the use of Python's base64 decoding functions in command line executions on Linux systems. Malicious scripts oft. Logsource: linux / process_creation. Rule: title: Python One-Liners with Base64 Decoding - Linux id: 55e862a8-dd9c-4651-807a-f21fcad56716 related: - id: 50a0aa3d-ab16-4594-a8aa-5145a6e6792b type: similar status: experimental description: 'Detects the use of Python''s base64 decoding functions in command line executions on Linux systems. Malicious scripts often use python one-liners to decode and execute base64-encoded payloads, which is a common technique for obfuscation and evasion. ' references: - https://docs.python.org/3/library/base64.html - https://www.virustotal.com/gui/file/bc43e925d7b4b74319f6e74e836a96f1997ba404e14ac566cf12a21e9da463db/behavior - https://cloud.google.com/blog/topics/threat-intelligence/cybercriminals-weaponize-fake-ai-websites author: Hugh Ryan (HueCodes), Swachchhanda Shrawan Poudel (Nextron Systems) date: 2026-03-09 tags: - attack.execution - attack.stealth - attack.t1059.006 - attack.t1027.010 logsource: category: process_creation product: linux detection: selection_img: Image|contains: /python selection_cli: CommandLine|contains|all: - import - base64 - ' -c' CommandLine|contains: - .decode - b16decode - b32decode - b32hexdecode - b64decode - b85decode - z85decode condition: all of selection_* falsepositives: - Legitimate use of Python for decoding data, which is uncommon in typical enterprise environments but possible in development or data analysis contexts. level: high
Near-miss passage: Sigma rule: Detects if the push protection feature is disabled for an organization, enterprise, repositories or custom pattern rules. Logsource: github / audit. Rule: title: Github Push Protection Disabled id: ccd55945-badd-4bae-936b-823a735d37dd status: test description: Detects if the push protection feature is disabled for an organization, enterprise, repositories or custom pattern rules. references: - https://docs.github.com/en/enterprise-cloud@latest/code-security/secret-scanning/push-protection-for-repositories-and-organizations - https://thehackernews.com/2024/03/github-rolls-out-default-secret.html author: Muhammad Faisal (@faisalusuf) date: 2024-03-07 tags: - attack.defense-impairment - attack.t1685 logsource: product: github service: audit definition: 'Requirements: The audit log streaming feature must be enabled to be able to receive such logs. You can enable following the documentation here: https://docs.github.com/en/enterprise-cloud@latest/admin/monitoring-activity-in-your-enterprise/reviewing-audit-logs-for-your-enterprise/streaming-the-audit-log-for-your-enterprise#setting-up-audit-log-streaming' detection: selection: action: - business_secret_scanning_custom_pattern_push_protection.disabled - business_secret_scanning_push_protection.disable - business_secret_scanning_push_protection.disabled_for_new_repos - org.secret_scanning_custom_pattern_push_protection_disabled - org.secret_scanning_push_protection_disable - org.secret_scanning_push_protection_new_repos_disable - repository_secret_scanning_custom_pattern_push_protection.disabled condition: selection falsepositives: - Allowed administrative activities. level: high