Presentation is loading. Please wait.

Presentation is loading. Please wait.

SSH/SSL Attacks not on tests, just for fun. SSH/SSL Should Be Secure Cryptographic operations are secure SSL uses certificates to authenticate servers.

Similar presentations


Presentation on theme: "SSH/SSL Attacks not on tests, just for fun. SSH/SSL Should Be Secure Cryptographic operations are secure SSL uses certificates to authenticate servers."— Presentation transcript:

1 SSH/SSL Attacks not on tests, just for fun

2 SSH/SSL Should Be Secure Cryptographic operations are secure SSL uses certificates to authenticate servers How can one attack such strong protocols? – Misconfiguration – Vulnerabilities in server code – Weak passwords

3 SSH Brute Force Attacks Find a weak password on SSH server Doesn’t have to be root, just any user’s password will do Log on, attempt to escalate privileges – If this works, great – If it doesn’t work, OK – Perform some malicious activity

4 SSH Brute Force Attacks From https://blog.sucuri.net/2013/07/ssh- brute-force-the-10-year-old-attack-that-still- persists.htmlhttps://blog.sucuri.net/2013/07/ssh- brute-force-the-10-year-old-attack-that-still- persists.html 10 years of running SSH honeypots – servers that serve no real content but are there just to be exploited and to log these exploits – These log all attempted username/pass combinations and all commands the attacker types

5 Frequently Attempted Usernames #attempts #username 9012 root (58%) 179 test (1%) 116 oracle (< 1%) 87 admin 82 info 70 user 69 postgres 68 mysql 68 backup 55 guest 49 web 49 tomcat

6 Frequently Attempted Passwords 365 123456 (2%) 201 password (1%) 114 12345 (<1%) 105 1234 92 root 92 123 84 qwerty 76 test 75 1q2w3e4r 72 1qaz2wsx 66 qazwsx 65 123qwe 58 12 55 123qaz 55 0000 52 oracle 50 1234567 47 123456qwerty 45 password123

7 SSH Brute Force Attacks What do attackers do when they log in? Try sudo for the account they have Create a directory with space for the name in /tmp (so it is invisible when user runs ls) – Download IRC server code – Run IRC server (as regular user)

8 SSL Heartbleed attack Bug in OpenSSL in 2014 It can be exploited on both servers and clients Bug is in handling of Heartbeat Extension – Heartbeats are sent periodically to help keep open SSL connections alive, avoid lengthy certificate and key exchange – A PhD student implemented the code and asked for it to become part of OpenSSL – A developer reviewed the code but didn’t notice a bug in input validation – Google discovered it 2 years later Bug results in memory-overrun Attacker can get contents from memory of the other party, which could be keys, user passwords, etc.

9 `

10 Frankencerts SSL certificates contain a lot of information in addition to key and identity – E.g., certificate version, validity period, name of issuer, purpose of certificate – There are many different implementations for certificate validation – Do different implementations result in different, potentially invalid outputs, for the same certificate? C. Brubaker et al., “Using Frankencerts for Automated Adversarial Testing of Certificate Validation in SSL/TLS Implementations”, Proceedings of 2014 IEEE Symposium on Security and Privacy

11 SSL Certificate Chain All these should be sent to the client for verification, along with leaf certificate

12 Validation Steps Check all the issuer fields in the certificate chain – Check that the root is in client’s “root of trust” Check that certificate has not expired Check that it is version 3 certificate. Otherwise, verify through out of band means. Check that CA bit is set in all but leaf cert Check that path length has not been exceeded between the leaf cert. and the current cert. Check that all critical extensions are supported

13 Validation Steps - Examples Check all the issuer fields in the certificate chain – Check that the root is in client’s “root of trust” Check that certificate has not expired Check that it is version 3 certificate. Otherwise, verify through out of band means. Check that CA bit is set in all but leaf cert Check that path length has not been exceeded between the leaf cert. and the current cert. Check that all critical extensions are supported Check for revocation

14 Findings 208 differences between SSL implementations Some accept version 1 or 2 certs they cannot validate Some don’t check the purpose of the certificate, allowing leaf certificates to be used to issue other certificates Some accept certificates with critical extensions that they don’t support Some also report wrong errors, e.g., “cert expired” instead of “invalid cert”


Download ppt "SSH/SSL Attacks not on tests, just for fun. SSH/SSL Should Be Secure Cryptographic operations are secure SSL uses certificates to authenticate servers."

Similar presentations


Ads by Google