We usually expect attackers to come from outside of the organization. However, imagine that you now received word of sensitive data about your organization being discovered out in the wild. There was never an external entity accessing any critical systems or data shares. Yes, the attack originated from an employee of your organization. Could you have done anything to gain visibility into this attack while it was happening from the inside?
Insider threat: where and what to look for
There are many ways an insider could exfiltrate data. Thankfully for security teams, the indicators look similar to those of external entities exfiltrating from a compromised account. However, there are other fields that may look “normal” that require some extra research to conclude if it is potentially malicious activity. This document will focus on real examples of exfiltrating data from a common cloud application, SharePoint.
User Agent Strings
User agent strings are contained in HTTP headers and used to identify devices in network traffic. Every operating system and browser show up differently in the user agent string.
For example, a User Agent String for a Firefox browser on a Windows OS would look like:
Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:47.0) Gecko/20100101 Firefox/47.0
A large list of user agent strings for different types can be found here: https://deviceatlas.com/blog/list-of-user-agent-strings.
Identifying the difference between normal and suspicious user agent strings depends on the use case. Scenario 1 below is a real example of a user downloading files through an automated script.
As you can see, the Device Type, which is the User Agent String, displays “Python-urllib/3.6”
From this information, we can conclude that the user is executing Python to download files from their SharePoint. Let’s look to see if there is more activity with the user agent containing “python” from this user.
In this example, there are a total of 18 activities. For the sake of avoiding a lengthy screenshot, we will look at the first three file downloads. Immediately we observe sensitive names in the file paths which would indicate that this user is automating file downloads of proprietary information from projects that he has previously worked on.
Keep in mind that User Agents can be modified to emulate browser settings in order to look “normal.” However, always be aware to look for user agents by applications commonly associated with scripting, such as Python or PowerShell.
As most correlation tools will automatically pull this information, one of the quickest ways towards that next step in verifying anomalous activity is to look at the geolocation of the IP address.
For example, we will look for File Downloaded activity where the company does not conduct business, which means we need to exclude the locations where it does do business:
In Scenario 2 above, you can see that the File Downloaded activity occurred from Romania, which is very unusual for the organization.
Finally, the Internet Service Provider that is associated with the IP address is also an indicator of suspicious intent. If the user agent string appears to be normal, and the geolocation is in an expected area for the user, then an anomalous ISP could be an indicator that the user is on a third-party VPN.
Most organizations will block the installation of third-party applications on their company-issued devices. Therefore, if you see someone with an ISP commonly associated with VPNs, such as Private Layer Inc., M247 Ltd., etc., then it may be a strong indicator that the user is downloading company files to a personal machine.
Let’s take a look at scenario 3 for example:
If you look at the ISP, you will notice that it is “V4escrow, LLC.” A quick Google search on the company will provide the fact that the company is associated with providing VPN services, such as with the application Mullvad VPN.
The ISP may not be provided in typical network traffic logs, but rules that cover activity from threat hosts will often overlap with ISPs used with common VPNs. Alternatively, you can find the ISP by doing a Whois on the IP address.
Detecting insider threat with ReliaQuest GreyMatter
ReliaQuest GreyMatter integrates and normalizes data from disparate technologies including SIEM, EDR, multi-cloud and point tools, on demand, so you always have a unified view to immediately and comprehensively detect and respond to threats from across your environment all within the GreyMatter UI. By aggregating, de-duping, and enriching alerts from across your security ecosystem, ReliaQuest GreyMatter serves up a research package that provides analysts with all of the information they need in one place to detect, investigate, and respond.
Ready to learn more? Download the white paper: Four Proven Steps to Integrating Threat Intel for Higher-Fidelity Detection and Response.