Trojan.PS1.PCASTLE.C

 Analysis by: Arvin Roi Macaraeg

 ALIASES:

Trojan-PSW.PowerShell.Mimikatz.m(KASPERSKY), Trojan:JS/Obfus(MICROSOFT)

 PLATFORM:

Windows

 OVERALL RISK RATING:
 DAMAGE POTENTIAL:
 DISTRIBUTION POTENTIAL:
 REPORTED INFECTION:
 INFORMATION EXPOSURE:

  • Threat Type: Trojan

  • Destructiveness: No

  • Encrypted: Yes

  • In the wild: Yes

  OVERVIEW

Infection Channel:

Downloaded from the Internet, Dropped by other malware

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.

It takes advantage of certain vulnerabilities.

  TECHNICAL DETAILS

File Size:

3,159,314 bytes

File Type:

PS1

Memory Resident:

Yes

Initial Samples Received Date:

25 Mar 2019

Payload:

Connects to URLs/IPs, Steals information

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 adds the following mutexes to ensure that only one of its copies runs at any one time:

  • Global\powerv5

Information Theft

This Trojan gathers the following data:

  • OS Version
  • MAC Address
  • List of AV products from the victim's machine
  • OS Architecture
  • Username
  • Domain Name

Other Details

This Trojan does the following:

  • Uses PingCastle Scanner to determine vulnerable machines to target
  • Capable of performing Brute Force Attack. It uses the following credentials:
    • Username:
      • administrator

    • Password:
      • 123456
      • password
      • PASSWORD
      • football
      • welcome
      • 1
      • 12
      • 21
      • 123
      • 321
      • 1234
      • 12345
      • 123123
      • 123321
      • 111111
      • 654321
      • 666666
      • 121212
      • 000000
      • 222222
      • 888888
      • 1111
      • 555555
      • 1234567
      • 12345678
      • 123456789
      • 987654321
      • admin
      • abc123
      • abcd1234
      • abcd@1234
      • abc@123
      • p@ssword
      • P@ssword
      • p@ssw0rd
      • P@ssw0rd
      • P@SSWORD
      • P@SSW0RD
      • P@$$w0rd
      • P@$$word
      • P@$$w0rd
      • iloveyou
      • monkey
      • login
      • passw0rd
      • master
      • hello
      • qazwsx
      • password1
      • qwerty
      • baseball
      • qwertyuiop
      • superman
      • 1qaz2wsx
      • fuckyou
      • 123qwe
      • zxcvbn
      • pass
      • aaaaaa
      • love
      • administrator

    • Hashes of password:
      • 32ed87bdb5fdc5e9cba88547376818d4
      • 8846f7eaee8fb117ad06bdd830b7586c
      • 7b592e4f8178b4c75788531b2e747687
      • 31fc0dc8f7dfad0e8bd7ccc3842f2ce9
      • 674e48b68c5cd0efd8f7e5faa87b3d1e
      • 69943c5e63b4d2c104dbbcc15138b72b
      • 588feb889288fb953b5f094d47d1565c
      • bcdf115fd9ba99336c31e176ee34b304
      • 3dbde697d71690a769204beb12283678
      • df54de3f3438343202c1dd523d0265be
      • 7ce21f17c0aee7fb9ceba532d0546ad6
      • 7a21990fcd3d759941e45c490f143d5f
      • 579110c49145015c47ecd267657d3174
      • af27efb60c7b238910efe2a7e0676a39
      • 2d7f1a5a61d3a96fb5159b5eef17adc6
      • 4057b60b514c5402dde3d29a1845c366
      • e8cd0e4a9e89eab931dc5338fcbec54a
      • 6920c58d0df184d829189c44fafb7ece
      • 3fa45a060bd2693ae4c05b601d05ca0c
      • ba07ba35933e5bf42dea4af8add09d1e
      • f1351ac828428d74f6da2968089fc91f
      • e84d037613721532e6b6d84d215854b6
      • 2f2d544c53b3031f24d63402ea7fb4f9
      • 328727b81ca05805a68ef26acb252039
      • 259745cb123a52aa2e693aaacca2db52
      • c22b315c040ae6e0efee3518d830362b
      • 162e829be112225fedf856e38e1c65fe
      • 209c6174da490caeb422f3fa5a7ae634
      • f9e37e83b83c47a93c2f09f66408631b
      • b3ec3e03e2a202cbd54fd104b8504fef
      • 4ed91524cb54eaacc17a185646fb7491
      • aa647b916a1fad374df9c30711d58a7a
      • a80c9cc3f8439ada25af064a874efe2d
      • 13b29964cc2480b4ef454c59562e675c
      • de26cce0356891a4a020e7c4957afc72
      • e19ccf75ee54e06b06a5907af13cef42
      • 30fcaa8ad9a496b3e17f7fbfacc72993
      • 41630abb825ca50da31ce1fac1e9f54d
      • f56a8399599f1be040128b1dd9623c29
      • 2e4dbf83aa056289935daea328977b20
      • f56a8399599f1be040128b1dd9623c29
      • b963c57010f218edc2cc3c229b5e4d0f
      • f2477a144dff4f216ab81f2ac3e3207d
      • e6bd4cdb1e447131b60418f31d0b81d6
      • b9f917853e3dbf6e6831ecce60725930
      • 6d3986e540a63647454a50e26477ef94
      • 066ddfd4ef0e9cd7c256fe77191ef43c
      • 152efbcfafeb22eabda8fc5e68697a41
      • 5835048ce94ad0564e29a924a03510ef
      • 2d20d252a479f485cdf5e171d93985bf
      • 320a78179516c385e35a93ffa0b1c4ac
      • 0d757ad173d2fc249ce19364fd64c8ec
      • 72f5cfa80f07819ccbcfb72feb9eb9b7
      • f67f5e3f66efd7298be6acd32eeeb27c
      • 1c4ecc8938fb93812779077127e97662
      • ad70819c5bc807280974d80f45982011
      • a836ef24f0a529688be2af1479a95411
      • 36aa83bdcab3c9fdaf321ca42a31c3fc
      • acb98fd0478427cd18949050c5e87b47
      • 85deeec2d12f917783b689ae94990716
      • a4141712f19e9dd5adf16919bb38a95c
  • Downloads the contents of the following URLs and executes it in memory(However, as of this writing, the said site is inaccessible):
    • http://p.{BLOCKED}h.com/upgrade.php?ver=5&mac={MAC Address}&av={List of AV products}&ver={OS Version}&bit={OS Architecture}
    • http://v.{BLOCKED}.com/ipc?low1
    • http://v.{BLOCKED}.com/wm?smb
  • Capable of performing Pass-the-Hash Attack. If successful, the malware drops the following files:
    • %Application Data%\sign.txt
    • %Application Data%\flashplayer.tmp
    • %User Startup%\run.bat
    • %User Startup%\FlashPlayer.lnk
  • If successful in performing a Brute Force Attack, it proceeds to do the following:
    • Executes the following processes:
      • netsh.exe firewall add portopening tcp 65533 DNS
      • netsh interface portproxy add v4tov4 listenport=65533 connectaddress=1.1.1.1 connectport=53
    • Create scheduled task:
      • Task Name: \Microsoft\windows\Rass
      • Action: powershell -nop -ep bypass -e {Base-64 encoded}
  • Uses the following URL to get the public IP address:
    • https://{BLOCKED}i.{BLOCKED}y.org/
  • It will Scan range of IP addresses available on the machine. If it can connect to the following IP addresses, it will target the following IP using MS17-010(EternalBlue) by creating scheduled task.This scheduled task will connect to a URL to download and execute a file.
  • The use of MS17-010 is to create a scheduled task to download and execute a copy of the malware on the memory.

It takes advantage of the following vulnerabilities:

  SOLUTION

Minimum Scan Engine:

9.850

FIRST VSAPI PATTERN FILE:

14.930.06

FIRST VSAPI PATTERN DATE:

10 Apr 2019

VSAPI OPR PATTERN File:

14.931.00

VSAPI OPR PATTERN Date:

11 Apr 2019

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

Identify and terminate files detected as Trojan.PS1.PCASTLE.C

[ Learn More ]
  1. Windows Task Manager may not display all running processes. In this case, please use a third-party process viewer, preferably Process Explorer, to terminate the malware/grayware/spyware file. You may download the said tool here.
  2. If the detected file is displayed in either Windows Task Manager or Process Explorer but you cannot delete it, restart your computer in safe mode. To do this, refer to this link for the complete steps.
  3. If the detected file is not displayed in either Windows Task Manager or Process Explorer, continue doing the next steps.

Step 4

Deleting Scheduled Tasks

The following {Task Name} - {Task to be run} listed should be used in the steps identified below:

  • \Microsoft\windows\Rass- powershell -nop -ep bypass -e {base-64 encoded}

For Windows 2000, Windows XP, and Windows Server 2003:

  1. Open the Windows Scheduled Tasks. Click Start>Programs>Accessories>
    System Tools>Scheduled Tasks.
  2. Locate each {Task Name} values listed above in the Name column.
  3. Right-click on the said file(s) with the aforementioned value.
  4. Click on Properties. In the Run field, check for the listed {Task to be run}.
  5. If the strings match the list above, delete the task.

For Windows Vista, Windows 7, Windows Server 2008, Windows 8, Windows 8.1, and Windows Server 2012:

  1. Open the Windows Task Scheduler. To do this:
    • On Windows Vista, Windows 7, and Windows Server 2008, click Start, type taskschd.msc in the Search input field, then press Enter.
    • On Windows 8, Windows 8.1, and Windows Server 2012, right-click on the lower left corner of the screen, click Run, type taskschd.msc, then press Enter.
  2. In the left panel, click Task Scheduler Library.
  3. In the upper-middle panel, locate each {Task Name} values listed above in the Name column.
  4. In the lower-middle panel, click the Actions tab. In the Details column, check for the {Task to be run} string.
  5. If the said string is found, delete the task.

Step 5

Search and delete these files

[ Learn More ]
There may be some files that are hidden. Please make sure you check the Search Hidden Files and Folders checkbox in the "More advanced options" option to include all hidden files and folders in the search result.
  • %Application Data%\sign.txt
  • %Application Data%\flashplayer.tmp
  • %User Startup%\run.bat
  • %User Startup%\FlashPlayer.lnk

Step 6

Scan your computer with your Trend Micro product to delete files detected as Trojan.PS1.PCASTLE.C. 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 the following Trend Micro Support pages for more information:

Step 7

Download and apply this security patch Refrain from using these products until the appropriate patches have been installed. Trend Micro advises users to download critical patches upon release by vendors. Microsoft Security Bulletin MS17-010


Did this description help? Tell us how we did.