<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: MohammedEllaithy</title>
    <description>The latest articles on DEV Community by MohammedEllaithy (@mellaithy0).</description>
    <link>https://dev.to/mellaithy0</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F658483%2F91580a7f-2091-4d5c-971b-695b66f7adc1.jpg</url>
      <title>DEV Community: MohammedEllaithy</title>
      <link>https://dev.to/mellaithy0</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/mellaithy0"/>
    <language>en</language>
    <item>
      <title>The Easiest Way to Enable Tls 1.2 and Disable Cipher suits without troubles </title>
      <dc:creator>MohammedEllaithy</dc:creator>
      <pubDate>Mon, 16 Aug 2021 12:00:37 +0000</pubDate>
      <link>https://dev.to/mellaithy0/the-easiest-way-to-enable-tls-1-2-and-disable-cipher-suits-without-troubles-3dj</link>
      <guid>https://dev.to/mellaithy0/the-easiest-way-to-enable-tls-1-2-and-disable-cipher-suits-without-troubles-3dj</guid>
      <description>&lt;p&gt;Both SSL and TLS are cryptographic protocols designed to secure communications over a network . Mainly we Have To Enable TLS 1.2 ONLY and Disable Old Versions of TLS. &lt;br&gt;
I'm Using AWS windows server 2019 EC2 Virtual Machine&lt;br&gt;
and here are steps depending on personal experiment after many many tries and reading articles and watching videos &lt;br&gt;
Here are the easiest way to patch security issues&lt;/p&gt;

&lt;p&gt;1-First You Have To Enable TLS 1.2&lt;br&gt;
*Note Run PowerShell as Administrator and Run the following&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;New-Item 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.2\Server' -Force | Out-Null
New-ItemProperty -path 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.2\Server' -name 'Enabled' -value '1' -PropertyType 'DWord' -Force | Out-Null
New-ItemProperty -path 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.2\Server' -name 'DisabledByDefault' -value 0 -PropertyType 'DWord' -Force | Out-Null    
New-Item 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.2\Client' -Force | Out-Null
New-ItemProperty -path 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.2\Client' -name 'Enabled' -value '1' -PropertyType 'DWord' -Force | Out-Null  
New-ItemProperty -path 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.2\Client' -name 'DisabledByDefault' -value 0 -PropertyType 'DWord' -Force | Out-Null

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;2-Disable TLS 1.0&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;New-Item 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.0\Server' -Force | Out-Null 
New-ItemProperty -path 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.0\Server' -name 'Enabled' -value '0' -PropertyType 'DWord' -Force | Out-Null 
New-ItemProperty -path 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.0\Server' -name 'DisabledByDefault' -value 1 -PropertyType 'DWord' -Force | Out-Null 
New-Item 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.0\Client' -Force | Out-Null 
New-ItemProperty -path 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.0\Client' -name 'Enabled' -value '0' -PropertyType 'DWord' -Force | Out-Null 
New-ItemProperty -path 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.0\Client' -name 'DisabledByDefault' -value 1 -PropertyType 'DWord' -Force | Out-Null
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;3-Disable TLS 1.1&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;New-Item 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.1\Server' -Force | Out-Null 
New-ItemProperty -path 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.1\Server' -name 'Enabled' -value '0' -PropertyType 'DWord' -Force | Out-Null 
New-ItemProperty -path 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.1\Server' -name 'DisabledByDefault' -value 1 -PropertyType 'DWord' -Force | Out-Null 
New-Item 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.1\Client' -Force | Out-Null 
New-ItemProperty -path 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.1\Client' -name 'Enabled' -value '0' -PropertyType 'DWord' -Force | Out-Null 
New-ItemProperty -path 'HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.1\Client' -name 'DisabledByDefault' -value 1 -PropertyType 'DWord' -Force | Out-Null
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;4- How to Disable Weak Ciphers:&lt;br&gt;
we have to Disable Every Weak Cipher found in Testing Report &lt;br&gt;
for example from &lt;a href="https://www.ssllabs.com/ssltest"&gt;Link&lt;/a&gt; we can generate Security report for HTTPS Domain and check &lt;br&gt;
Cipher Suites section to find out &lt;strong&gt;Weak Ciphers&lt;/strong&gt;&lt;br&gt;
For Example i found those 2 weak ciphers &lt;br&gt;
TLS_DHE_RSA_WITH_AES_256_CBC_SHA&lt;br&gt;
TLS_DHE_RSA_WITH_AES_128_CBC_SHA&lt;br&gt;
Using the following Command you can Easily Disable Weak cipher &lt;br&gt;
through powershell as Administrator&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Disable-TlsCipherSuite -Name "TLS_DHE_RSA_WITH_AES_256_CBC_SHA"
Disable-TlsCipherSuite -Name "TLS_DHE_RSA_WITH_AES_128_CBC_SHA"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Important&lt;/strong&gt;&lt;br&gt;
You can also use this site &lt;a href="https://tls.imirhil.fr/"&gt;Link&lt;/a&gt;&lt;br&gt;
Sometimes you Find in security report ((DES3)) as Critical Cipher&lt;br&gt;
so here how to Disable it &lt;br&gt;
First open registry &lt;br&gt;
Follow this path  (HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL)&lt;br&gt;
Add new Key Rename to &lt;strong&gt;RC4 1288/128&lt;/strong&gt;&lt;br&gt;
Then add new DWORD 32 bit &amp;gt;&amp;gt; Rename to &lt;strong&gt;Enabled&lt;/strong&gt; and Value is &lt;strong&gt;0&lt;/strong&gt;&lt;br&gt;
Add new Key Rename to &lt;strong&gt;Triple Des 168&lt;/strong&gt;&lt;br&gt;
Then add new DWORD 32 bit &amp;gt;&amp;gt; Rename to &lt;strong&gt;Enabled&lt;/strong&gt; and Value is &lt;strong&gt;0&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Important Note&lt;/strong&gt;&lt;br&gt;
You have to &lt;strong&gt;Restart&lt;/strong&gt; windows machine after you finish those stpes &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Concluding&lt;/strong&gt;&lt;br&gt;
Get rid of old protocols, cipher suites and hashing algorithms in your Hybrid Identity implementation, so they cannot be used to negotiate the security of the connections down.&lt;/p&gt;

</description>
      <category>security</category>
      <category>aws</category>
      <category>cloud</category>
    </item>
  </channel>
</rss>
