{"id":3688,"date":"2019-07-09T21:02:05","date_gmt":"2019-07-10T02:02:05","guid":{"rendered":"http:\/\/toddsingleton.net\/chronicle\/?p=3688"},"modified":"2020-02-08T08:39:36","modified_gmt":"2020-02-08T13:39:36","slug":"vulnerability-port-8443-is-a-ransomware-invitation-close-it","status":"publish","type":"post","link":"https:\/\/toddsingleton.net\/chronicle\/2019\/07\/09\/vulnerability-port-8443-is-a-ransomware-invitation-close-it\/","title":{"rendered":"Details of a ransomware attack and a way to thwart the ransom.  Don&#8217;t plan to pay.   Plan to recover."},"content":{"rendered":"<h3>Here are the basic steps included in\u00a0a ransomware attack and how vulnerable people and ports are used\u00a0to accommodate the attacker.\u00a0\u00a0Conditions must be met.<\/h3>\n<ol>\n<li>The attacker relies on stolen credentials.\u00a0 The credentials are harvested\u00a0by viruses delivering malware.\u00a0 Specifically in recent attacks Emotet as the delivery agent for the Trickbot trojan.\u00a0 All too easy with users susceptible to social engineering.<\/li>\n<li>Trickbot\u00a0moves laterally\u00a0across systems, relying on SMB to navigate the network as it steals passwords, mail files, registry keys and more.\u00a0 It communicates the stolen material back to the bad actor, the Black Hat.<\/li>\n<li>Next Trickbot might launch the Empire Powershell backdoor and download the Ryuk virus upon the black hat&#8217;s command.\u00a0 Armed with harvested credentials, the black hat is now ready to execute Ryuk and encrypt files at will.<\/li>\n<li>The black hat scans for any vulnerable port of entry on an external interface.<\/li>\n<\/ol>\n<p><span style=\"color: #000080;\">\u250c\u2500[blackhat@parrot]\u2500[~]<\/span><\/p>\n<div><span style=\"color: #000080;\">\u2514\u2500\u2500\u257c $nmap -Pn -p 8443\u00a0xxx.123.xxx.456<\/span><\/div>\n<div><span style=\"color: #000080;\">Starting Nmap 7.70 ( https:\/\/nmap.org ) at 2019-07-09 16:47 EDT<\/span><\/div>\n<div><span style=\"color: #000080;\">Nmap scan report for system.contoso.com (xxx.123.xxx.456)<\/span><\/div>\n<div><span style=\"color: #000080;\">Host is up (0.029s latency).<\/span><\/div>\n<div><\/div>\n<div><span style=\"color: #000080;\">PORT \u00a0 \u00a0 STATE SERVICE<\/span><\/div>\n<div><span style=\"color: #000080;\">8443\/tcp open \u00a0https-alt<\/span><\/div>\n<p>Once a port of entry is found, in this case a very common and vulnerable port used as a remote access interface, the black hat can use the stolen credentials to log in to the network and rely on protocols such as SMB and RDP to access and exploit systems on the network, launching Ryuk to encrypt files on select systems, typically all of them.\u00a0 Azure?\u00a0 Too bad, encrypted.\u00a0 Active directory authenticated AWS?\u00a0 Ouch.ryk, every file owned.\u00a0 Once the damage is found you&#8217;ll need to recover.<\/p>\n<h3>So how can you protect systems and most importantly backups so that <a href=\"https:\/\/www.techradar.com\/news\/why-rapid-recovery-is-key-to-minimising-the-ransomware-threat\"><span style=\"color: #008000;\">rapid recovery<\/span><\/a>, the best\u00a0response\u00a0to a live attack, remains possible?<\/h3>\n<ul>\n<li>The obvious first step in recovery is to neutralize all exploits.\u00a0 It can also be the most time consuming.\u00a0 Use Windows firewalls to block all SMB traffic and stop lateral movement across systems.\u00a0 Deploy through domain level group policy.\u00a0 Open only the ports necessary to deliver anti-malware utilities to clean all machines of any sign of exploits.\u00a0 Windows 7 systems remain highly vulnerable to SMB attacks without proper patching and configuration.\u00a0 <em>Update 02\/07\/20: Windows 7 is depreciated, insecure and should not be used.<\/em>\u00a0 Best to get them off your network regardless of how annoyed some end users are by the thought of Windows 10.<\/li>\n<li>Always\u00a0<strong>be certain\u00a0backup files and database backups reside on systems that are not authenticated to the network using domain level authentication<\/strong>.\u00a0 Make sure they cannot be accessed using SMB or RDP protocols at all.<\/li>\n<li>Of extreme importance is to\u00a0make sure EVERYONE,\u00a0especially your domain administrators are forced to change their login credentials routinely.\u00a0 IT staff have a bad habit of being prime offenders of exempting themselves from password changes.\u00a0 Take a stand.\u00a0 Everyone changes their passwords and password complexity rules must be adhered to by every single account on the network.\u00a0 Use 2 Factor Authentication 2FA every time possible, especially mailboxes and cloud accounts.<\/li>\n<li>Make sure you have machine images that are <strong>not accessible using domain level authentication<\/strong> or credentials.\u00a0 If you run a VMware environment make sure you administer VCenter only through local Vsphere credential logins, not AD authentication.\u00a0 This serves not only to protect your production images,\u00a0more importantly it protects your snapshots.\u00a0 Hyper-V environments, God help you.\u00a0 When you are solely reliant on Windows authentication to manage your virtual servers, you&#8217;re vulnerable.\u00a0 I&#8217;d have to do more research on exactly how to stop propagation to all systems in a Hyper-V environment.\u00a0 My first inclination would be spend some money on VMware or a Citrix XEN Hypervisor, Nutanix if you must.<\/li>\n<li>Have snapshots.\u00a0 Have recent snapshots.\u00a0 If you don&#8217;t run virtual servers at least have Windows bare metal restore backups for physical machines.\u00a0 Again these are to be written to appliances that are <strong>not<\/strong> connected to the network with domain level authentication.\u00a0 Snapshot and bare metal backup files should remain recent enough to take into account all hardware and operating system changes that have been implemented.<\/li>\n<li>Close vulnerable ports on your public interfaces or at minimum set them to random port numbers.\u00a0 Obvious ports like 8443 are gonna get hit.<\/li>\n<li>If you are a heavy transaction environment then you will also want to incorporate more more redundancy at the database server and application server level, such as SQL database replication with incremental transaction log offloads to drive space that is again, not domain authenticated.<\/li>\n<\/ul>\n<p><em>Note: I did not specify anything related to archiving and compliance backups because while essential for certain industries and disaster situations they are not specific to rapid recovery in the event of any malicious disaster in which physical hardware assets are not compromised.\u00a0\u00a0<\/em><\/p>\n<p>Once you are able to quickly restore a virtual machine or physical system from a recent snapshot or bare metal recover file copies of data files and database backups can be moved into place for restoration to the most current backup set.\u00a0 Daily is usually the best most small to medium &#8220;enterprises&#8221; can achieve.\u00a0 With added expense in resources and configuration backups can be run with more frequency.\u00a0 \u00a0Unfortunately even hourly database log shipping won&#8217;t save a database from an encryption attack.\u00a0 As my last point emphasized, unless log files are being off loaded in hourly increments to storage appliances that are <strong>not<\/strong> connected with domain level authentication they aren&#8217;t safe.\u00a0 As always, the question of investment becomes: How much can you afford to lose?<\/p>\n<p>The best defense against Ransomware is a good offence in the form of rapid recovery.\u00a0 Since these exploits rely on social engineering (gullible people) you can never pretend your network is free of any vulnerability.\u00a0 Don&#8217;t just design your backup and recovery environment in case something happens.\u00a0 Make sure it&#8217;s tested\u00a0it for when it happens.<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Here are the basic steps included in\u00a0a ransomware attack and how vulnerable people and ports are used\u00a0to accommodate the attacker.\u00a0\u00a0Conditions must be met. The attacker relies on stolen credentials.\u00a0 The credentials are harvested\u00a0by viruses delivering malware.\u00a0 Specifically in recent attacks Emotet as the delivery agent for the Trickbot trojan.\u00a0 All too easy with users susceptible &hellip; <a href=\"https:\/\/toddsingleton.net\/chronicle\/2019\/07\/09\/vulnerability-port-8443-is-a-ransomware-invitation-close-it\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Details of a ransomware attack and a way to thwart the ransom.  Don&#8217;t plan to pay.   Plan to recover.<\/span> <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[],"class_list":["post-3688","post","type-post","status-publish","format-standard","hentry","category-technology"],"_links":{"self":[{"href":"https:\/\/toddsingleton.net\/chronicle\/wp-json\/wp\/v2\/posts\/3688","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/toddsingleton.net\/chronicle\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/toddsingleton.net\/chronicle\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/toddsingleton.net\/chronicle\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/toddsingleton.net\/chronicle\/wp-json\/wp\/v2\/comments?post=3688"}],"version-history":[{"count":16,"href":"https:\/\/toddsingleton.net\/chronicle\/wp-json\/wp\/v2\/posts\/3688\/revisions"}],"predecessor-version":[{"id":3771,"href":"https:\/\/toddsingleton.net\/chronicle\/wp-json\/wp\/v2\/posts\/3688\/revisions\/3771"}],"wp:attachment":[{"href":"https:\/\/toddsingleton.net\/chronicle\/wp-json\/wp\/v2\/media?parent=3688"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/toddsingleton.net\/chronicle\/wp-json\/wp\/v2\/categories?post=3688"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/toddsingleton.net\/chronicle\/wp-json\/wp\/v2\/tags?post=3688"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}