I am trying to scan an endpoint to see what TLS version it is running and I am seeing some discrepancy between the nmap scan and the openssl scan. Scanning the same host I see only TLSv1.0 from nmap (7.40) and I can see TLSv1.2 with openssl (1.0.1e). I also scan the same host with Qualys SSL Labs and it seem to be getting TLSv1.2 also. So I was wondering why nmap is only showing TLSv1.0? (result of scan below)
nmap scan:
localhost:~ localuser$ nmap -sV --script ssl-enum-ciphers -p 443 example.com
Starting Nmap 7.40 ( https://nmap.org ) at 2017-02-11 13:13 PST
Nmap scan report for example.com (###.###.###.###)
Host is up (0.016s latency).
PORT STATE SERVICE VERSION
443/tcp open ssl/http Apache Tomcat/Coyote JSP engine 1.1
|_http-server-header: Apache-Coyote/1.1
| ssl-enum-ciphers:
| TLSv1.0:
| ciphers:
| TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA (secp192r1) - D
| TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA (secp192r1) - A
| TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA (secp192r1) - A
| TLS_RSA_WITH_3DES_EDE_CBC_SHA (rsa 2048) - C
| TLS_RSA_WITH_AES_128_CBC_SHA (rsa 2048) - A
| TLS_RSA_WITH_AES_256_CBC_SHA (rsa 2048) - A
| compressors:
| NULL
| cipher preference: client
| warnings:
| 64-bit block cipher 3DES vulnerable to SWEET32 attack
| Key exchange (secp192r1) of lower strength than certificate key
|_ least strength: D
Service detection performed. Please report any incorrect results at https://nmap.org/submit/ .
Nmap done: 1 IP address (1 host up) scanned in 24.51 seconds
localhost:~ localuser$
openssl scan
SSL handshake has read 8589 bytes and written 453 bytes
---
New, TLSv1/SSLv3, Cipher is ECDHE-RSA-AES256-GCM-SHA384
Server public key is 2048 bit
Secure Renegotiation IS supported
Compression: NONE
Expansion: NONE
SSL-Session:
Protocol : TLSv1.2
Cipher : ECDHE-RSA-AES256-GCM-SHA384
Session-ID: 589F81CE166178A7DA49EC4EF9F86412FA161E6B4C54CB65E7111784B48A2054
Session-ID-ctx:
Master-Key: 94179213B34A8DCA54A4AD23661E2C8EBF3E46BC0E251426DC377FD27513584B9C978357CAE0663AF77B488AC6158887
Key-Arg : None
Krb5 Principal: None
PSK identity: None
PSK identity hint: None
Start Time: 1486848462
Timeout : 300 (sec)
Verify return code: 0 (ok)
---