You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
ncat - buffer overflow when -u and --ssl options are specified #1543
Thanks for this report. I can't tell from the information here whether your version of OpenSSL supports DLTS (SSL over UDP) or what exactly the problem might be. Can you provide a bit more information? Specifically:
The version of OpenSSL that Ncat is using. If you have Nmap from the same build, output of nmap --version is helpful.
Output of the crashing command with -vvvv added for extra debugging.
If possible, output of strace -e socket ncat -u --ssl -vvvv 127.0.0.1 8080
Great, thanks! The problem is that some of the code paths related to handling SSL connections are assuming that the connection is TCP, so there is a mismatch between the socket type (SOCK_STREAM) and the protocol (IPPROTO_UDP). We'll work on resolving this. Can you tell us whether there is a DTLS server on port 8080 UDP? In other words, where would you expect the error to be coming from: a closed port, a DTLS protocol error, or something else?
Activity
dmiller-nmap commentedon Apr 8, 2019
Thanks for this report. I can't tell from the information here whether your version of OpenSSL supports DLTS (SSL over UDP) or what exactly the problem might be. Can you provide a bit more information? Specifically:
nmap --versionis helpful.-vvvvadded for extra debugging.strace -e socket ncat -u --ssl -vvvv 127.0.0.1 8080Thanks again!
jabedude commentedon Apr 8, 2019
Certainly:
Verbose output:
strace output:
dmiller-nmap commentedon Apr 8, 2019
Great, thanks! The problem is that some of the code paths related to handling SSL connections are assuming that the connection is TCP, so there is a mismatch between the socket type (SOCK_STREAM) and the protocol (IPPROTO_UDP). We'll work on resolving this. Can you tell us whether there is a DTLS server on port 8080 UDP? In other words, where would you expect the error to be coming from: a closed port, a DTLS protocol error, or something else?
jabedude commentedon Apr 8, 2019
Awesome! There was no service listening on 8080
Don't try to reconnect SSLv2 over DTLS (UDP). Fixes nmap#1543