Trojan.PS1.POWTRAN.A
PowerShell/Agent.MA trojan (NOD32)
Windows
Threat Type: Trojan
Destructiveness: No
Encrypted: Yes
In the wild: Yes
OVERVIEW
This Trojan arrives on a system as a file dropped by other malware or as a file downloaded unknowingly by users when visiting malicious sites.
TECHNICAL DETAILS
9,134,997 bytes
PS1
Yes
20 Feb 2020
Arrival Details
This Trojan arrives on a system as a file dropped by other malware or as a file downloaded unknowingly by users when visiting malicious sites.
Installation
This Trojan drops the following files:
- %System%\WindowsPowerShell\v1.0\WinRing0x64.sys ->Allows XMRig to boost mining capability
- %System%\mue.exe -> Detected as Coinminer.Win64.MALXMR.TDI
(Note: %System% is the Windows system folder, where it usually is C:\Windows\System32 on all Windows operating system versions.)
It adds the following processes:
- powercfg /CHANGE -standby-timeout-ac 0
- powercfg /CHANGE -hibernate-timeout-ac 0
- powercfg -SetAcValueIndex 381b4222-f694-41f0-9685-ff5bb260df2e 4f971e89-eebd-4455-a8de-9e59040e7347 5ca83367-6e45-459f-a27b-476b1d01c936 000
- powershell -NoP -NonI -W Hidden -exec bypass `"`$fun={base-64 encoded script};`$defun=[System.Text.Encoding]::ASCII.GetString([System.Convert]::FromBase64String(`$fun));iex `$defun;iex ([System.Text.Encoding]::ASCII.GetString([System.Convert]::FromBase64String('$EncodedScript'))) - For Windows 10
- powershell -NoP -NonI -W Hidden -exec bypass -E {base-64 encoded script} - For Windows 7
- netstat -anop tcp
- %System%\schtasks.exe
(Note: %System% is the Windows system folder, where it usually is C:\Windows\System32 on all Windows operating system versions.)
It injects codes into the following process(es):
- %System%\schtasks.exe
(Note: %System% is the Windows system folder, where it usually is C:\Windows\System32 on all Windows operating system versions.)
Other System Modifications
This Trojan deletes the following files:
- %Temp%\gpt.ps1
(Note: %Temp% is the Windows temporary folder, where it usually is C:\Windows\Temp on all Windows operating system versions.)
Process Termination
This Trojan terminates the following processes if found running in the affected system's memory:
- Processes that have an ESTABLISHED network connection via port 3333, 5555, 7777
- Processes that have an ESTABLISHED network connection via port 49636, 14444, 14433, 80, 443
Download Routine
This Trojan accesses the following websites to download files:
- http://{BLOCKED}.net/bannerl
- http://{BLOCKED}.net/sync
- https://raw.{BLOCKED}.com/{BLOCKED}up/master/domtar
Other Details
This Trojan does the following:
- It may connect to the following mining pool:
- xmr-{BLOCKED}.org:14444
- xmr-asia1.{BLOCKED}.org:14444
- xmr-us-west1.{BLOCKED}.org:14444
- xmr-us-east1.{BLOCKED}.org:14444
- xmr-eu2.{BLOCKED}.org:14444
- mine.{BLOCKED}.net:80
- pool.{BLOCKED}.com:80
- It is capable of propagating in the local network via the following means:
- Mimikatz
It uses Windows Management Instrumentation (WMI) to do the following:
- WMI Event Subscription:
- For Windows 10:
- It creates the following WMI Classes under ROOT\subscription to achieve persistence in the system:
- __FilterToConsumerBinding
- Filter: SCM Event6 Log Filter
- Consumer: SCM Event6 Log Consumer
- __EventFilter
- Name: SCM Event6 Log Filter
- QueryLanguage: WQL
- Query: SELECT * FROM __InstanceModificationEvent WITHIN 13600 WHERE TargetInstance ISA 'Win32_PerfFormattedData_PerfOS_System'
- __CommandLineEventConsumer:
- Name: SCM Event6 Log Consumer
- CommandLineTemplate: powershell -NoP -NonI -W Hidden -exec bypass `"`$fun={base64 encoded command};`$defun=[System.Text.Encoding]::ASCII.GetString([System.Convert]::FromBase64String(`$fun));iex `$defun;`$mon = ([WmiClass] 'root\default:systemcore_Updater6').Properties['mon'].Value;`$funs = ([WmiClass] 'root\default:systemcore_Updater6').Properties['funs'].Value ;iex ([System.Text.Encoding]::ASCII.GetString([System.Convert]::FromBase64String(`$funs)));Invoke-Command -ScriptBlock `$RemoteScriptBlock -ArgumentList @(`$mon, `$mon, 'Void', 0, '', '')`"
- __FilterToConsumerBinding
- Filter: SCM Event6 Log Filter2
- Consumer: SCM Event6 Log Consumer2
- __EventFilter
- Name: SCM Event6 Log Filter2
- QueryLanguage: WQL
- Query: SELECT * FROM __InstanceModificationEvent WITHIN 60 WHERE TargetInstance ISA 'Win32_PerfFormattedData_PerfOS_System' AND TargetInstance.SystemUpTime >= 240 AND TargetInstance.SystemUpTime < 301
- __CommandLineEventConsumer:
- Name: SCM Event6 Log Consumer2
- CommandLineTemplate: : powershell -NoP -NonI -W Hidden -exec bypass `"`$fun='{base64 encoded command}';`$defun=[System.Text.Encoding]::ASCII.GetString([System.Convert]::FromBase64String(`$fun));iex `$defun;`$mon = ([WmiClass] 'root\default:systemcore_Updater6').Properties['mon'].Value;`$funs = ([WmiClass] 'root\default:systemcore_Updater6').Properties['funs'].Value ;iex ([System.Text.Encoding]::ASCII.GetString([System.Convert]::FromBase64String(`$funs)));Invoke-Command -ScriptBlock `$RemoteScriptBlock -ArgumentList @(`$mon, `$mon, 'Void', 0, '', '')`"
- It creates the following WMI Classes under ROOT\subscription to achieve persistence in the system:
- __FilterToConsumerBinding
- Filter: SCM Event6 Log Filter
- Consumer: SCM Event6 Log Consumer
- __EventFilter
- Name: SCM Event6 Log Filter
- QueryLanguage: WQL
- Query: SELECT * FROM __InstanceModificationEvent WITHIN 13600 WHERE TargetInstance ISA 'Win32_PerfFormattedData_PerfOS_System'
- __CommandLineEventConsumer:
- Name: SCM Event6 Log Consumer
- CommandLineTemplate: powershell -NoP -NonI -W Hidden -exec bypass -E {base-64 encoded script}"
- __FilterToConsumerBinding
- Filter: SCM Event6 Log Filter2
- Consumer: SCM Event6 Log Consumer2
- __EventFilter
- Name: SCM Event6 Log Filter2
- QueryLanguage: WQL
- Query: SELECT * FROM __InstanceModificationEvent WITHIN 60 WHERE TargetInstance ISA 'Win32_PerfFormattedData_PerfOS_System' AND TargetInstance.SystemUpTime >= 240 AND TargetInstance.SystemUpTime < 301"
- __CommandLineEventConsumer:
- Name: SCM Event6 Log Consumer2
- CommandLineTemplate: powershell -NoP -NonI -W Hidden -exec bypass -E {base-64 encoded script}
- For Windows 7:
- systemcore_Updater6
- WMI objects:
- mon - base-64 encoded Monero Executable
- mons – base-64 encoded Monero Executable
- ring – base-64 encoded Monero module
- funs -{base64-encoded script}
SOLUTION
9.850
15.706.05
25 Feb 2020
15.707.00
26 Feb 2020
Step 1
Before doing any scans, Windows 7, Windows 8, Windows 8.1, and Windows 10 users must disable System Restore to allow full scanning of their computers.
Step 2
Note that not all files, folders, and registry keys and entries are installed on your computer during this malware's/spyware's/grayware's execution. This may be due to incomplete installation or other operating system conditions. If you do not find the same files/folders/registry information, please proceed to the next step.
Step 3
Restart in Safe Mode
Step 4
Search and delete these files
- %System%\WindowsPowerShell\v1.0\WinRing0x64.sys
- %System%\mue.exe
Step 5
Restart in normal mode and scan your computer with your Trend Micro product for files detected as Trojan.PS1.POWTRAN.A. If the detected files have already been cleaned, deleted, or quarantined by your Trend Micro product, no further step is required. You may opt to simply delete the quarantined files. Please check this Knowledge Base page for more information.
NOTES:
Do this after step 3:
Cleaning WMI Objects
- Run the command prompt (cmd.exe) as administrator.
- Remove the WMI objects mentioned above found in root\default namespace by typing the following commands: powershell.exe -noprofile -executionpolicy bypass -command "if(Get-WMIObject -namespace root\default -query \"SELECT * FROM meta_class WHERE __class ='systemcore_Updater6'\"|Select-Object -Property Properties -ExpandProperty properties|Where{$_.Name -match \"funs\" -or $_.Name -match \"mons\"}){Get-WMIObject -namespace root\default -query \"SELECT * FROM meta_class WHERE __class ='systemcore_Updater6'\"|Remove-WMIObject -Verbose}"
- Remove the WMI objects mentioned above found in root\Subscription namespace by typing and executing the following commands:
- powershell.exe -noprofile -executionpolicy bypass -command "Get-WMIObject -Namespace root\Subscription -Class __FilterToConsumerBinding -Filter \""__Path LIKE '%SCM Event6 Log Filter%'\"" | remove-WMIObject -Verbose"
- powershell.exe -noprofile -executionpolicy bypass -command "Get-WMIObject -Namespace root\Subscription -Class __EventFilter -Filter \""Name= 'SCM Event6 Log Filter'\"" |remove-WMIObject -Verbose"
- powershell.exe -noprofile -executionpolicy bypass -command "Get-WMIObject -Namespace root\Subscription -Class __EventFilter -Filter \""Name= 'SCM Event6 Log Filter2'\"" |remove-WMIObject -Verbose"
- powershell.exe -noprofile -executionpolicy bypass -command "Get-WMIObject -Namespace root\Subscription -Class CommandLineEventConsumer -Filter \""CommandLineTemplate LIKE '%powershell -NoP -NonI -W Hidden -exec bypass -E %'\"" | Remove-WMIObject -Verbose"
Did this description help? Tell us how we did.