{"id":1440,"date":"2020-06-24T08:44:51","date_gmt":"2020-06-24T08:44:51","guid":{"rendered":"https:\/\/partnernews.sophos.com\/en-us\/?p=1440"},"modified":"2020-06-24T08:46:12","modified_gmt":"2020-06-24T08:46:12","slug":"sophos-endpoint-detection-and-response-ama-ask-machines-anything","status":"publish","type":"post","link":"https:\/\/partnernews.sophos.com\/en-us\/2020\/06\/products\/sophos-endpoint-detection-and-response-ama-ask-machines-anything\/","title":{"rendered":"Sophos Endpoint Detection and Response: AMA &#8211; Ask Machines Anything"},"content":{"rendered":"<p>You may have seen the acronym AMA used on Reddit and various other social platforms out there. Normally, it\u2019s used for developers and people of interest that host a round of open questions, like &#8220;Question Time,&#8221; but more intense! AMA, in those scenarios, means \u201cask me anything.\u201d Well with the latest version of EDR (v3), we give you the power to \u201cask machines anything.\u201d Currently, we support Windows endpoints, Windows Server, and Linux machines. Mac support will be added soon too.<\/p>\n<p>EDR v3 uses <a href=\"https:\/\/osquery.io\/schema\/4.2.0\" target=\"_blank\" rel=\"noopener noreferrer\">OSQuery<\/a> to enable us to poll devices for information. The great thing about OSQuery is that it tries to be OS agnostic; the same queries work on different platforms. The slightly odd thing about it, is that it\u2019s all based around SQL. Personally, I\u2019ve not had much need to be throwing SQL queries about since I left tech support nearly eight years ago. I guess that\u2019s going to have to change now!<\/p>\n<p>If you&#8217;re like me, and your SQL-fu is a little &#8230; aged, you might want to start with the built-in queries. Thankfully, there are loads of them, and the majority have come from our elite MTR team (who are constantly running threat-hunting activities on customer devices).<\/p>\n<p>Since there are a lot of queries in there already, it can be a little daunting at first. But, my aim with this article is to help you get a leg up with using it.<\/p>\n<p><strong>Getting Started &#8211; Selecting Devices<\/strong><br \/>\nJump into the Threat Analysis Center &gt; Live Discover. From here, you\u2019ll get a list of all EDR-protected devices, use the filters to narrow down the list, and select those devices you wish to learn more about:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1443\" src=\"https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-1.png\" alt=\"\" width=\"640\" height=\"238\" srcset=\"https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-1.png 800w, https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-1.png?resize=300,111 300w, https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-1.png?resize=768,285 768w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/p>\n<p>Tick the boxes, and then click &#8216;update selected devices list.&#8221; It\u2019s a little like shopping online: you select the items you want to buy and then they appear in the basket, or in our case the &#8220;selected devices&#8221; basket. Click on &#8220;selected devices&#8221; to see what you have in the basket. If this is your first time, I would recommend that you just select a single device for starters; some of the queries we can grab a lot of data.<\/p>\n<p>Scroll down to the Query section and we&#8217;ll have a run through it:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1444\" src=\"https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-2.png\" alt=\"\" width=\"640\" height=\"302\" srcset=\"https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-2.png 800w, https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-2.png?resize=300,141 300w, https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-2.png?resize=768,362 768w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/p>\n<p><strong>Getting Started &#8211; Queries<\/strong><br \/>\nThere are load of queries in here, arranged in subcategories to help you find the ones you are after. You can also search for a query and create your own.<br \/>\nSo, what can we use this for?<\/p>\n<p><strong>Threat Hunting<\/strong><br \/>\nLet\u2019s start off with a look at threat hunting using EDR v3 as the base. As mentioned above, our EDR system uses OSQuery. In fact, at the time of writing, we are using version 4.2. The schema can be found here: <a href=\"https:\/\/osquery.io\/schema\/4.2.0\" target=\"_blank\" rel=\"noopener noreferrer\">https:\/\/osquery.io\/schema\/4.2.0<\/a>. It gives a list of all the native OSQueries available, but of course we have supplemented these native queries with our own.<\/p>\n<p>The Sophos queries can be found on the <a href=\"https:\/\/community.sophos.com\/products\/intercept\/early-access-program\/m\/files\/9491\" target=\"_blank\" rel=\"noopener noreferrer\">community forums<\/a>.<\/p>\n<p>Generally speaking, the native OSQueries will look at live, current data, like running processes or the value of a defined registry key. The Sophos journal tables on the other hand can query our data recorder which records for about 30 days, capturing all processes, registry values, file actions, and network connections.<\/p>\n<p>Truly there is a lot of data that can be obtained, but thankfully you don\u2019t have to go it alone. We\u2019ve created a large collection of useful queries for you, and there is an ever-increasing number of them on the community forum.<\/p>\n<p>Here\u2019s an example of the query \u201cNew processes that run automatically\u201d which shows various load points used by software to run when a machine is booted. Can you spot the suspicious entry?<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1445\" src=\"https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-3.png\" alt=\"\" width=\"640\" height=\"111\" srcset=\"https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-3.png 800w, https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-3.png?resize=300,52 300w, https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-3.png?resize=768,133 768w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/p>\n<p>All results can be exported from the console, and they are even cached for up to two hours. You can get back into a previous query from Threat Analysis Center &gt; Dashboard &gt; Recent Live Discover queries.<\/p>\n<p>With this query it\u2019s easy to find malicious or suspicious load points for software, but there are so many more queries to play with. Here\u2019s a few of my personal recommendations:<\/p>\n<ul>\n<li>New processes that run automatically<\/li>\n<li>PowerShell events suspected of using encoded or encrypted data<\/li>\n<li>Processes listening on ports<\/li>\n<li>Scheduled tasks<\/li>\n<li>Remote authentication attempts<\/li>\n<\/ul>\n<p><strong>Auditing and Other Information<\/strong><br \/>\nIt\u2019s true, EDR was designed with threat hunting in mind. But since it can access so much information from the devices, it can be used for all manner of other data collection.<br \/>\nIn the list of pre-made queries there are plenty that have nothing to do with threat hunting and can be easily used to aid an IT team in finding useful information about their machines. A couple of handy ones that spring to mind are:<\/p>\n<p><strong>Hardware and Operating System Details<\/strong><br \/>\nShows the hardware information, like the CPU type, amount of RAM, hardware vendor, and other information too.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1446\" src=\"https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-4.png\" alt=\"\" width=\"640\" height=\"70\" srcset=\"https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-4.png 800w, https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-4.png?resize=300,33 300w, https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-4.png?resize=768,84 768w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/p>\n<p><strong>Patches Applied<\/strong><br \/>\nShows the installed patches on devices, as well as who triggered the installation and when it happened. Very handy if you want to know whether all machines have installed their Windows updates or not.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1447\" src=\"https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-5.png\" alt=\"\" width=\"640\" height=\"237\" srcset=\"https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-5.png 800w, https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-5.png?resize=300,111 300w, https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-5.png?resize=768,284 768w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/p>\n<p><strong>Interface MACs<\/strong><br \/>\nOK, I\u2019m cheating. This one doesn\u2019t exist normally, I created it. It\u2019s a very simple query. Just click on &#8220;create new query,&#8221; give it a name and a description, and then paste the following into the query box:<\/p>\n<p>SELECT<\/p>\n<p style=\"padding-left: 40px;\">description &#8220;Desc&#8221;,<\/p>\n<p style=\"padding-left: 40px;\">mac &#8220;MAC&#8221;<\/p>\n<p>FROM interface_details<\/p>\n<p>WHERE MAC &gt;1;<\/p>\n<p>\/* This removes the loopback adapters and Microsoft tunnels *\/<\/p>\n<p>When you are ready, click &#8220;run query&#8221; and beyond a list of your MAC addresses. It should work on all supported operating systems.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-1448\" src=\"https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-6.png\" alt=\"\" width=\"640\" height=\"308\" srcset=\"https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-6.png 800w, https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-6.png?resize=300,144 300w, https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/06\/tech-news-sophos-endpoint-detection-and-response-6.png?resize=768,370 768w\" sizes=\"auto, (max-width: 640px) 100vw, 640px\" \/><\/p>\n<p><strong>Useful Resources<\/strong><br \/>\nBelow is a list of places I\u2019ve found useful whilst creating queries. Hopefully, you\u2019ll find it handy too:<\/p>\n<ul>\n<li><a href=\"https:\/\/osquery.io\/schema\/4.2.0\" target=\"_blank\" rel=\"noopener noreferrer\">OSQuery Schema<\/a><\/li>\n<li><a href=\"https:\/\/community.sophos.com\/products\/intercept\/early-access-program\/m\/files\/9491\" target=\"_blank\" rel=\"noopener noreferrer\">Sophos Live Discover Schema<\/a><\/li>\n<li><a href=\"https:\/\/www.w3schools.com\/sql\/\" target=\"_blank\" rel=\"noopener noreferrer\">W3 Schools SQL<\/a><\/li>\n<li><a href=\"https:\/\/community.sophos.com\/products\/intercept\/early-access-program\/#pi2521=2\" target=\"_blank\" rel=\"noopener noreferrer\">Sophos Community Forum for EDRv3<\/a><\/li>\n<\/ul>\n<p><strong>A Note From Andy<\/strong><br \/>\nI hope this encourages you to get playing with EDR v3. It\u2019s a very powerful tool that allows admins to \u201cask machines anything.\u201d<\/p>\n","protected":false},"excerpt":{"rendered":"<p>You may have seen the acronym AMA used on Reddit and various other social platforms. AMA in those scenarios means \u201cask me anything\u201d. Well with EDRv3 we give you the power to \u201cask machines anything\u201d.<\/p>\n","protected":false},"author":48,"featured_media":1190,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"advanced_seo_description":"","jetpack_seo_html_title":"","jetpack_seo_noindex":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[2],"tags":[30,105,16],"coauthors":[68],"class_list":["post-1440","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-products","tag-intercept-x","tag-sophos-edr","tag-technical-news"],"jetpack_featured_media_url":"https:\/\/partnernews.sophos.com\/en-us\/wp-content\/uploads\/sites\/3\/2020\/04\/featured-image-UKI-tech-update-Partner-app-icon-1600x960-1.png","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/partnernews.sophos.com\/en-us\/wp-json\/wp\/v2\/posts\/1440","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/partnernews.sophos.com\/en-us\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/partnernews.sophos.com\/en-us\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/partnernews.sophos.com\/en-us\/wp-json\/wp\/v2\/users\/48"}],"replies":[{"embeddable":true,"href":"https:\/\/partnernews.sophos.com\/en-us\/wp-json\/wp\/v2\/comments?post=1440"}],"version-history":[{"count":7,"href":"https:\/\/partnernews.sophos.com\/en-us\/wp-json\/wp\/v2\/posts\/1440\/revisions"}],"predecessor-version":[{"id":1460,"href":"https:\/\/partnernews.sophos.com\/en-us\/wp-json\/wp\/v2\/posts\/1440\/revisions\/1460"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/partnernews.sophos.com\/en-us\/wp-json\/wp\/v2\/media\/1190"}],"wp:attachment":[{"href":"https:\/\/partnernews.sophos.com\/en-us\/wp-json\/wp\/v2\/media?parent=1440"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/partnernews.sophos.com\/en-us\/wp-json\/wp\/v2\/categories?post=1440"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/partnernews.sophos.com\/en-us\/wp-json\/wp\/v2\/tags?post=1440"},{"taxonomy":"author","embeddable":true,"href":"https:\/\/partnernews.sophos.com\/en-us\/wp-json\/wp\/v2\/coauthors?post=1440"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}