Posts

Showing posts with the label Hardening

Remote Desktop Protocol (RDP) Security

Image
Common Remote Desktop Protocol (RDP) Vulnerabilities Terminal Services Encryption Level is Medium or Low Microsoft Windows Remote Desktop Protocol Server Man-in-the-Middle Weakness Terminal Services Doesn't Use Network Level Authentication (NLA) Only Terminal Services Encryption Level is Medium or Low Vulnerability Assessment: Host Assessment: Remediation: Local Computer Policy/Computer Configuration/Administrative Templates/Windows Components/Remote Desktop Services/Remote Desktop Session Host/Security/Set client connection encryption level Set client connection encryption level to High Note: High: The High setting encrypts data sent from the client to the server and from the server to the client by using strong 128-bit encryption. Use this encryption level in environments that contain only 128-bit clients (for example, clients that run Remote Desktop Connection). Clients that do not support this encryption level cannot connect to RD S...

Server Message Block (SMB) Security

Image
Common SMB related vulnerabilities Microsoft Windows SMBv1 Multiple Vulnerabilities SMB Signing Disabled Microsoft Windows SMB NULL Session Authentication Microsoft Windows SMB Shares Unprivileged Access Network Discovery: TCP port 5357 - Web Services on Devices API (WSDAPI) File and Printer Sharing: TCP port 135 - Remote Procedure Call (RPC) TCP port 139 - NETBIOS Session Service TCP port 445 - Server Message Block (SMB) By disable NetBIOS over TCP/IP (TCP Port 139), NETBIOS name discovery will be prevented Microsoft Windows SMBv1 Multiple Vulnerabilities Vulnerability Assessment: NSE script smb-protocols can be used to check if the server supported NT LM 0.12 (SMBv1) . Host Assessment: Get-ItemProperty HKLM:\SYSTEM\CurrentControlSet\Services\LanmanServer\Parameters | ForEach-Object {Get-ItemProperty $_.pspath} Remediation: Set-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Services\LanmanServer\Parameters...

Web Server Hardening - Apache Tomcat

Image
Reference: https://tomcat.apache.org/tomcat-8.0-doc/security-howto.html 1. Remove Extraneous Resources Removing sample resources C:\xampp\Tomcat\webapps\docs C:\xampp\Tomcat\webapps\examples Removing Manager Application if not using C:\xampp2\Tomcat\webapps\host-manager C:\xampp2\Tomcat\webapps\manager C:\xampp2\Tomcat\conf\Catalina\localhost\manager.xml Disable unused Connector C:\xampp2\tomcat\conf\server.xml cat server.xml | grep "Connector" 2. Limit Server Platform Information Leaks Alter the Advertised server information Audit: cd $CATALINA_HOME/lib jar xf catalina.jar org/apache/catalina/util/ServerInfo.properties grep server.info org/apache/catalina/util/ServerInfo.properties Remediation: server.info=<SomeWebServer> server.number=<someversion> server.built= Disable X-Powered-By HTTP Header and Rename the Server Value for all Connectors Turn off TRACE Affected file: $CATALINA_HOME/conf/server.xml Remediation:...

Web Server Hardening - MySQL

Image
MySQL Security In order to understand the possible attack can be done on MySQL, please read our write up for SQL Injection at http://www.axcelsec.com/2018/02/penetration-testing-with-owasp-top-10.html . SHOW DATABASES; USE MYSQL; SELECT * FROM user; SELECT Host,User,Password FROM user; CIS Benchmark 3. File System Permissions SHOW VARIABLES WHERE variable_name = 'datadir' OR variable_name = 'plugin_dir' OR #Plugin Directory variable_name LIKE 'log_bin_basename' OR variable_name LIKE 'log_error' OR variable_name LIKE 'slow_query_log_file' OR variable_name LIKE 'relay_log_basename' OR variable_name LIKE 'general_log_file' OR variable_name = 'ssl_key'; #SSL Key Files 4. General SHOW VARIABLES WHERE variable_name LIKE "version"; SHOW VARIABLES LIKE 'have_symlink'; #Ensure the Value returned is DISABLED. SHOW DATABASES LIKE 'test'; #Ensure that no rows are returned (Ensure the ...

SSL Security

Image
Updated on 20180912 Creating SSL Certification  https://letsencrypt.org/ https://www.instantssl.com/ssl-certificate-products/free-email-certificate.html SSL Security Scanner DigiCert® SSL Installation Diagnostics Tool ( https://www.digicert.com/help/ ) Qualys - SSL Server Test ( https://www.ssllabs.com/ssltest/ ) SSLScan IISCrypto ( https://www.nartac.com/Products/IISCrypto ) Common SSL Vulnerability  Heartbleed HTTPS Level Up! ⚠️ SSL Connection will break if SSLStrip in place ✔️ HTTP Strict Transport Security (HSTS) https://www.globalsign.com/en/blog/what-is-hsts-and-how-do-i-use-it/ https://www.owasp.org/index.php/HTTP_Strict_Transport_Security_Cheat_Sheet Abuse HSTS Protection: Tracking browser history * HTML5 Canvas Fingerprint * Embed non-existent images from various HSTS-protected domains over HTTP Test your browser with browserleaks.com and  Sniffly ! ✔️ HTTP Public Key Pinning (HPKP) aka. Cert P...

Popular posts from this blog

Remote Desktop Protocol (RDP) Security

Penetration Testing - Network

Damn Vulnerable Web Services (DVWS) - Walkthrough

Server Message Block (SMB) Security

Offensive Security Testing Guide

Host Configuration Assessment - Windows

Web Server Hardening - Apache Tomcat

Content Page

Mobile Penetration Testing - Android

Penetration Testing with OWASP Top 10 - 2017 A7 Cross-Site Scripting (XSS)