APT_Backdoor_PS1_BASICPIPESHELL_1

YARA-2025-0929 High general Active
No description available for this rule
APT_Backdoor_PS1_BASICPIPESHELL_1.yar Valid Syntax
// Copyright 2020 by FireEye, Inc.
// You may not use this file except in compliance with the license. The license should have been received with this file. You may obtain a copy of the license at:
// https://github.com/fireeye/red_team_tool_countermeasures/blob/master/LICENSE.txt
import "pe"
rule APT_Backdoor_PS1_BASICPIPESHELL_1
{
    meta:
        author = "FireEye"
    strings:
        $s1 = "function Invoke-Client()" ascii nocase wide
        $s2 = "function Invoke-Server" ascii nocase wide
        $s3 = "Read-Host 'Enter Command:'" ascii nocase wide
        $s4 = "new-object System.IO.Pipes.NamedPipeClientStream(" ascii nocase wide
        $s5 = "new-object System.IO.Pipes.NamedPipeServerStream(" ascii nocase wide
        $s6 = " = iex $" ascii nocase wide
    condition:
        all of them
}

Rule Metadata

author
FireEye

String Definitions

{"name":"$s1","value":"\"function Invoke-Client()\" ascii nocase wide"}
{"name":"$s2","value":"\"function Invoke-Server\" ascii nocase wide"}
{"name":"$s3","value":"\"Read-Host 'Enter Command:'\" ascii nocase wide"}
{"name":"$s4","value":"\"new-object System.IO.Pipes.NamedPipeClientStream(\" ascii nocase wide"}
{"name":"$s5","value":"\"new-object System.IO.Pipes.NamedPipeServerStream(\" ascii nocase wide"}
{"name":"$s6","value":"\" = iex"}

Threat Analysis

This YARA rule is designed to detect general threats.

Severity Level: High

The rule uses pattern matching to identify specific byte sequences, strings, or behavioral patterns associated with malicious activity.

Detection Capabilities

  • File-based detection for executables and documents
  • Memory scanning for running processes
  • Network traffic analysis support

Command Line Usage

# Scan a single file
yara APT_Backdoor_PS1_BASICPIPESHELL_1.yar /path/to/suspicious/file

# Scan a directory recursively
yara -r APT_Backdoor_PS1_BASICPIPESHELL_1.yar /path/to/directory/

# Scan with metadata output
yara -m APT_Backdoor_PS1_BASICPIPESHELL_1.yar target_file

# Scan process memory (Linux)
yara APT_Backdoor_PS1_BASICPIPESHELL_1.yar /proc/[pid]/exe

Integration Examples

Python (yara-python)

import yara
rules = yara.compile(filepath='APT_Backdoor_PS1_BASICPIPESHELL_1.yar')
matches = rules.match('/path/to/file')

ClamAV Integration

clamscan --yara-rules=APT_Backdoor_PS1_BASICPIPESHELL_1.yar /path/to/scan

Rule Information

YARA ID
YARA-2025-0929
Author
Created
August 19, 2025
Last Updated
August 19, 2025
Last Imported
Never

Threat Intelligence

Risk Level High
Category general
Detection Confidence Analysis Pending
False Positive Rate Not Available
Last Seen in Wild No Data

Export Options