<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Omer Zohar on Medium]]></title>
        <description><![CDATA[Stories by Omer Zohar on Medium]]></description>
        <link>https://medium.com/@omerzohar?source=rss-41fecde3ec94------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*gBAsAAWLp3yiLwBD.</url>
            <title>Stories by Omer Zohar on Medium</title>
            <link>https://medium.com/@omerzohar?source=rss-41fecde3ec94------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 29 Nov 2026 18:06:54 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@omerzohar/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Protect yourself against the new ‘Wormable’ vulnerability  in SMBv3 (CVE-2020–0796)]]></title>
            <link>https://medium.com/@omerzohar/protect-yourself-against-the-new-wormable-vulnerability-in-smbv3-cve-2020-0796-3d19ec1a2394?source=rss-41fecde3ec94------2</link>
            <guid isPermaLink="false">https://medium.com/p/3d19ec1a2394</guid>
            <category><![CDATA[windows]]></category>
            <category><![CDATA[vulnerability]]></category>
            <category><![CDATA[smb]]></category>
            <category><![CDATA[cve]]></category>
            <category><![CDATA[microsoft]]></category>
            <dc:creator><![CDATA[Omer Zohar]]></dc:creator>
            <pubDate>Wed, 11 Mar 2020 06:42:48 GMT</pubDate>
            <atom:updated>2020-06-10T05:22:08.937Z</atom:updated>
            <content:encoded><![CDATA[<h3>Protect yourself against the new ‘Wormable’ vulnerability in SMBv3: SMBGhost (CVE-2020–0796) and SMBleed (CVE-2020–1206)</h3><p>Updated 10/06/20 (see history below) technical details and a patch have been published. <strong>Update your system!</strong> The bug was described as “a Buffer Overflow Vulnerability in Microsoft SMB Servers” and <strong>received a maximum severity rating.</strong></p><p>If patching is not an option, one way to protect yourself from CVE-2020–0796 is to run the following command from a powershell command line (admin privileges required):</p><blockquote>Set-ItemProperty -Path “HKLM:\SYSTEM\CurrentControlSet\Services\LanmanServer\Parameters” DisableCompression -Type DWORD -Value 1 -Force</blockquote><p>This Will disable smbv3 compression and it’s a temporary workaround until a patch come out.</p><p>But, since not a lot is known on this bug, a more robust and safe mitigation would be to disable SMB services completely. If your windows workstations or servers that do not host SMB shares, <strong>you can block all inbound SMB traffic using the Windows Defender Firewall to prevent remote connections from malicious or compromised devices</strong>. In the Windows Defender Firewall, it is as simple as creating the following rule:</p><blockquote>Name: Block all inbound SMB 445<br>Description: Blocks all inbound SMB TCP 445 traffic. Not to be applied to domain controllers or computers that host SMB shares.<br>Action: Block the connection<br>Programs: All<br>Remote Computers: Any<br>Protocol Type: TCP<br>Local Port: 445<br>Remote Port: Any<br>Profiles: All<br>Scope (Local IP Address): Any<br>Scope (Remote IP Address): Any<br>Edge Traversal: Block edge traversal</blockquote><p>Let go step by step on how to create the rule using windows defender firewall settings:</p><ol><li><a href="https://www.windowscentral.com/how-open-port-windows-firewall">Open Windows Defender Firewall advanced settings</a></li><li>Click on ‘Inbound Rules’</li><li>Click on ‘New Rule’ on the top right pane</li><li>Follow wizard and fill according to below screenshots:</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/890/1*uG12eBLkcJPDlf69foMSgA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/889/1*cZIfr1cB6XIkHpGbygENpw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/888/1*_5-Gznhxk10S0SU2GAm-pQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/890/1*VKPQlmaFM3So0Yj0lhdstg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/890/1*7VRtA9XYLHwSglcee3RFlw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/890/1*uG12eBLkcJPDlf69foMSgA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/892/1*n7tdSgyt2eAGafzdOY9XyA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/887/1*JXqTlSwdNozwY2nmEr8zRw.png" /></figure><p>That’s it! You’re now protected against any incoming SMB connection attack!</p><p>To check you network for open SMB Servers, you can use the following script:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/13c79575c76dd87e16f1c807c8fe5b46/href">https://medium.com/media/13c79575c76dd87e16f1c807c8fe5b46/href</a></iframe><p>This will check if there’s a SMB v 3.1.1 server in the specified address.</p><p>11/3/20 Update: The folks at <a href="https://www.claroty.com/">Claroty</a> made an Nmap script that will actually test if an SMB server supports compression. Useful if you’ve used the first mitigation and would like to check changed in place.</p><p><a href="https://github.com/ClarotyICS/CVE2020-0796">https://github.com/ClarotyICS/CVE2020-0796</a></p><p>12/3/20 update 1:</p><p>Microsoft finally released a patch: <a href="https://portal.msrc.microsoft.com/en-US/security-guidance/advisory/CVE-2020-0796">https://portal.msrc.microsoft.com/en-US/security-guidance/advisory/CVE-2020-0796</a></p><p>12/3/20 Update 2:</p><p>Synacktiv made a great root cause analysis of the bug:</p><p><a href="https://twitter.com/Synacktiv/status/1238126780734754816">https://twitter.com/Synacktiv/status/1238126780734754816</a></p><p>Tl;dr “OriginalCompressedSegmentSize and OffsetOrLength are 32-bit values, and srv2!Srv2DecompressData add them before allocating the new buffer, indicating a potential integer overflow.”</p><p>10/06/20 Update 3:<br>Security firm ZecOps released a new vulnerability based on this one, dubbed SMBleed. More details here: <a href="https://thehackernews.com/2020/06/SMBleed-smb-vulnerability.html">https://thehackernews.com/2020/06/SMBleed-smb-vulnerability.html</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3d19ec1a2394" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Hacking public DNS providers for Total Privacy]]></title>
            <link>https://medium.com/@omerzohar/hacking-public-dns-providers-for-total-privacy-27dbdb958c75?source=rss-41fecde3ec94------2</link>
            <guid isPermaLink="false">https://medium.com/p/27dbdb958c75</guid>
            <category><![CDATA[privacy]]></category>
            <category><![CDATA[dns]]></category>
            <category><![CDATA[dnscrypt]]></category>
            <category><![CDATA[not]]></category>
            <category><![CDATA[cloudflare]]></category>
            <dc:creator><![CDATA[Omer Zohar]]></dc:creator>
            <pubDate>Fri, 20 Apr 2018 18:08:18 GMT</pubDate>
            <atom:updated>2018-04-22T12:55:56.361Z</atom:updated>
            <content:encoded><![CDATA[<p>The competition in the free DNS service has became more fierce as Cloudflare with 1.1.1.1 had joined google’s 8.8.8.8, Cisco’s OpenDns, Quad9’s 9.9.9.9 and <a href="https://dnscrypt.info/public-servers">many more</a> Providers and ISPs resolvers out there.</p><p>Cloudflare main claim to fame is their speed, and indeed <a href="https://medium.com/@nykolas.z/dns-resolvers-performance-compared-cloudflare-x-google-x-quad9-x-opendns-149e803734e5">recent benchmarks</a> had shown that other than your own ISP servers, they’re true to their word.</p><p>Another often disregarded feature that was emphasized with this release is the support for <a href="https://developers.cloudflare.com/1.1.1.1/dns-over-tls/">DNS over TLS</a> and <a href="https://developers.cloudflare.com/1.1.1.1/dns-over-https/">DNS over HTTPS (DOH)</a>, which allows for increased privacy from anyone snooping on your queries, either the local internet cafe or your own ISP (or state?). It also provides protection from attacks such as the all-too-easy DNS Man-In-the-Middle, cache poisoning and <a href="https://www.networkworld.com/article/2886283/security0/top-10-dns-attacks-likely-to-infiltrate-your-network.html#slide1">many others</a>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ePCsLiHijQWbMcbDzR0nBg.jpeg" /></figure><p>But what is the price for these services? No free service is actually free. As the saying goes “When you don’t know what is the product, YOU are the product”. Even though in its <a href="https://developers.cloudflare.com/1.1.1.1/commitment-to-privacy/privacy-policy/privacy-policy/">privacy policy</a> Cloudflare promise it will not keep any identifiable data, they do save some aggregated data. Of course, Cloudflare is not alone in this. All vendor collect some of their data to their usage, see the below table or <a href="https://www.damsky.tech/single-post/2018/04/02/The-Rising-Of-The-Alternative-DNS-Services">read this comparison to dig deeper</a>:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rOBqq-hPCEkjJ9ZkfBO_cg.jpeg" /><figcaption>Comparison between the main free public DNS Services</figcaption></figure><p>It is apparent that no service is fully TNO (Trust No One) compliant. So what does one who wants to keep his full DNS usage from reaching one of these vendors? There are few options that comes to mind:</p><ol><li>Use a local ISP DNS Resolver. This of course will put all data in hands of the ISP, which might or not use that data. It is certainly been the case in recent years that ISPs use this data as a mean of added income, like placing ads and redirects on non existing lookups, or just sell the data to other vendors.</li><li>Run your own DNS Resolver. This will probably put your mind at ease in regards to the usage of data of the local resolver, but keep in mind as that as a sole user on that server the DNS Resolvers upstream will still get your queries. It is also quite difficult technically to properly and securely maintain a DNS resolver (think hosting, bandwidth, security updates, configurations…)</li><li>Split your queries across multiple vendors. This way, none of them will have your entire DNS activity. For the paranoid: create some background queries of random domains to further skew your profile.</li></ol><p>Obviously we prefer № 3. But how is it done? It is actually quite easy to do using <a href="https://github.com/jedisct1/dnscrypt-proxy">DNScrypt-Proxy</a> — A flexible DNS proxy, with support for modern encrypted DNS protocols such as <a href="https://dnscrypt.info/protocol">DNSCrypt v2</a> and <a href="https://tools.ietf.org/html/draft-ietf-doh-dns-over-https-05">DNS-over-HTTPs</a>.</p><p>Once installed and configured as our main DNS resolver, we’ll use DNScrypt to randomly select a different DNS server for every query we make. The resolvers will be selected from a list of vetted DNS list according to a criteria that we’ll select: Resolvers who claim not to save any logs, does not filter any data and are either using DNSCrypt, DoT or DoH.</p><p>Sounds easy right? it surprisingly is.</p><p>Lets get started by installing DNScrypt-Proxy by <a href="https://github.com/jedisct1/dnscrypt-proxy/wiki/installation">following the instruction on their wiki page</a>. They provide a <a href="https://github.com/jedisct1/dnscrypt-proxy/releases/tag/2.0.9">list of binaries</a> to choose from according to the platform you’re using on.</p><p>Once that’s done, we’ll configure it according to our needs. We’ll start with the example config file:</p><pre>cp example-dnscrypt-proxy.toml dnscrypt-proxy.toml</pre><p>The example script is actually pretty well configured for our needs. we really need to change very few things. First is the load balancing strategy, which will determine which server will be elected for every query. we will go with random:</p><pre>lb_strategy = &#39;random&#39;</pre><p>We want to make sure no UDP plaintext protocol will be used:</p><pre>force_tcp = true</pre><p>Disable tls session tickets to make it harder for <a href="https://blog.filippo.io/we-need-to-talk-about-session-tickets/">passive tls decryption</a> on continuous connections:</p><pre>tls_disable_session_tickets = true</pre><p>Make sure the configured system dns never get used:</p><pre>ignore_system_dns = true</pre><p>We let DNScrypt know what kind of restrictions we want for the DNS resolvers it connects to, to make sure we only connect to resolver that meet out demands (no filtering, no logging, use only secure connection):</p><pre>dnscrypt_servers = true</pre><pre>doh_servers = true</pre><pre># Enforcing DNSSEC is optional at your discretion<br>require_dnssec = false</pre><pre>require_nolog = true</pre><pre>require_nofilter = true</pre><p>DNScrypt will use these lists of resolvers (<a href="https://raw.githubusercontent.com/DNSCrypt/dnscrypt-resolvers/master/v2/public-resolvers.md">one</a>, <a href="https://download.dnscrypt.info/resolvers-list/v2/public-resolvers.md">two</a>) and will filter them according to your selection. You can of course manually add or remove resolvers as you see fit.</p><p>Finally, if you plan on using the proxy on any other machine other the one its currently running on, change the listening address:</p><pre>֫listen_addresses = [&#39;XX.XX.XX.XX:53&#39;, &#39;[::XX]:53&#39;]</pre><p>now we’re ready to run DNScrypt:</p><pre>root@kali:~/linux-x86_64# ./dnscrypt-proxy <br>[2018-04-19 15:32:35] [INFO] Loading source information from URL [<a href="https://raw.githubusercontent.com/DNSCrypt/dnscrypt-resolvers/master/v2/public-resolvers.md">https://raw.githubusercontent.com/DNSCrypt/dnscrypt-resolvers/master/v2/public-resolvers.md</a>]<br>[2018-04-19 15:32:35] [INFO] Loading source information from URL [<a href="https://raw.githubusercontent.com/DNSCrypt/dnscrypt-resolvers/master/v2/public-resolvers.md.minisig">https://raw.githubusercontent.com/DNSCrypt/dnscrypt-resolvers/master/v2/public-resolvers.md.minisig</a>]<br>[2018-04-19 15:32:35] [NOTICE] Source [public-resolvers.md] loaded<br>[2018-04-19 15:32:35] [NOTICE] dnscrypt-proxy 2.0.9<br>[2018-04-19 15:32:35] [NOTICE] Now listening to 127.0.0.1:53 [UDP]<br>[2018-04-19 15:32:35] [NOTICE] Now listening to 127.0.0.1:53 [TCP]<br>[2018-04-19 15:32:35] [NOTICE] Now listening to [::1]:53 [UDP]<br>[2018-04-19 15:32:35] [NOTICE] Now listening to [::1]:53 [TCP]<br>[2018-04-19 15:32:36] [NOTICE] [arvind-io] OK (crypto v2) - rtt: 196ms<br>...<br>...<br>...<br>18-04-19 15:32:53] [NOTICE] [soltysiak] OK (crypto v1) - rtt: 77ms<br>[2018-04-19 15:32:53] [NOTICE] [trashvpn] OK (crypto v2) - rtt: 88ms<br>[2018-04-19 15:32:54] [NOTICE] [ventricle.us] OK (crypto v2) - rtt: 153ms<br>[2018-04-19 15:32:54] [NOTICE] Server with the lowest initial latency: cloudflare (rtt: 62ms)<br><strong>[2018-04-19 15:32:54] [NOTICE] dnscrypt-proxy is ready - live servers: 30</strong></pre><p>DNScrypt will choose resolvers that answer your criteria and will try to establish a connection with them, measuring their speed and checking the connection to them. Once done, it will announce the fastest server (Cloudflare, no surprises here) and the number of servers it was able to contact and validate. <br>Now, set you local machine DNS to the ip address DNScrypt is listening on, and you’re done! Every DNS query your machine makes will go out thru one of the 30 (!) different resolvers. How’s that for extra layer of privacy?</p><p>Not happy with running DNScrypt-proxy as a service on your local machine? no worries. <a href="https://www.flashrouters.com/blog/2017/05/19/what-is-dnscrypt/">It can easily be enabled</a> in DD-WRT or Tomato firmwares of various popular routers.</p><p>So Here we are. The most secure and private DNS setup that I know of. Hopefully this short guide was helpful for you privacy nutters out there. If you have any comments or remarks please comment below!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=27dbdb958c75" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>