Skip to content

YARA · SEKOIA.IO Community

SEKOIA_Tool_Htran_Strings

Detects HTran based on strings

Hack toolHtranSEKOIA.IO CommunityDetection Rule License 1.1Compiles with YARA-X
Author
Sekoia.io
Date
2022-09-09
Modified
2024-12-19
Score / Quality
75 / 80

What this rule detects

Detects HTran based on strings

Associated malware family: Htran.

Targets: Windows PE.

It defines 6 patterns (6 text, 0 hex, 0 regex).

Summary generated from the rule's metadata and condition.

Rule source

tool-htran-strings.yarDetection Rule License 1.1
rule SEKOIA_Tool_Htran_Strings : FILE
{
	meta:
		description = "Detects HTran based on strings"
		author = "Sekoia.io"
		id = "0184937e-eefa-4c6d-ae00-9b0af80dc7db"
		date = "2022-09-09"
		modified = "2024-12-19"
		reference = "https://github.com/SEKOIA-IO/Community"
		source_url = "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/yara_rules/tool_htran_strings.yar#L1-L22"
		license_url = "https://github.com/SEKOIA-IO/Community/blob/a438a5901a211c2abdf75da9c93921ef187473d1/LICENSE.md"
		logic_hash = "6a414cec8ad623c735779b9005074f88b07d88b29b23918d98a541a2612a3fa0"
		score = 75
		quality = 80
		tags = "FILE"
		version = "1.0"
		classification = "TLP:CLEAR"

	strings:
		$ = "-slave <ConnectHost> <ConnectPort> <TransmitHost> <TransmitPort>"
		$ = "-tran <ConnectPort> <TransmitHost> <TransmitPort>"
		$ = "-listen <ConnectPort> <TransmitPort>"
		$ = "[-] There is a error...Create a new connection."
		$ = "[+] Start Transmit (%s:%d <-> %s:%d) ......"
		$ = "[+] Accept a Client on port %d from %s"

	condition:
		uint16be( 0 ) == 0x4d5a and filesize < 1MB and 3 of them
}

Strings (6 patterns)

IdentifierTypeValueModifiers
$text"-slave <ConnectHost> <ConnectPort> <TransmitHost> <TransmitPort>"
$text"-tran <ConnectPort> <TransmitHost> <TransmitPort>"
$text"-listen <ConnectPort> <TransmitPort>"
$text"[-] There is a error...Create a new connection."
$text"[+] Start Transmit (%s:%d <-> %s:%d) ......"
$text"[+] Accept a Client on port %d from %s"

Condition

uint16be( 0 ) == 0x4d5a and filesize < 1MB and 3 of them

In plain words (Heuristic)

  • The file must start with “MZ” — a Windows executable (PE).
  • The file must be smaller than 1MB (a cheap guard that skips large files).
  • At least 3 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.

Open in editor

References

Licence & attribution

Author: Sekoia.io

Source repository: SEKOIA.IO Community @ a438a5901a

Licence: Detection Rule License 1.1 (repository licence)

Original rule

Mirrored via YARA Forge 20260927, which prefixes rule names with the source and adds normalised meta fields.

Rule id: 0184937e-eefa-4c6d-ae00-9b0af80dc7db

Metadata

version1.0
classificationTLP:CLEAR

Tags:FILE