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
Leverage OS support (such as Windows' CryptoAPI) for Ncat SSL cert verification instead of out-of-date cert bundle #42
D. Accept or reject the connection based on the OS result.
This produces correct platform-native trust decisions, but it is external to OpenSSL’s verification mechanism. OpenSSL never uses the OS trust store internally; you simply ignore its built-in verdict and substitute your own.
changed the title [-]Leverage Windows' CryptoAPI for cert verification in Ncat[/-][+]Leverage OS support (such as Windows' CryptoAPI) for Ncat SSL cert verification instead of out-of-date cert bundle[/+]on Apr 13, 2026
Activity
dmiller-nmap commentedon Oct 13, 2020
From the Nmap todo file:
dmiller-nmap commentedon Apr 13, 2026
Potential way ahead, per ChatGPT:
A. Perform the TLS handshake with OpenSSL but skip or minimize OpenSSL’s own cert validation.
Set verification mode to SSL_VERIFY_PEER, but provide a verify_callback that ignores OpenSSL’s verdict.
B. Extract the presented certificate chain from the OpenSSL session.
Use SSL_get_peer_cert_chain() or related calls.
C. Pass that chain into the system’s trust API:
macOS: Security.framework (SecTrustCreateWithCertificates, SecTrustEvaluateWithError).
Windows: CryptoAPI (CertCreateCertificateChainEngine, CertGetCertificateChain).
D. Accept or reject the connection based on the OS result.
This produces correct platform-native trust decisions, but it is external to OpenSSL’s verification mechanism. OpenSSL never uses the OS trust store internally; you simply ignore its built-in verdict and substitute your own.
[-]Leverage Windows' CryptoAPI for cert verification in Ncat[/-][+]Leverage OS support (such as Windows' CryptoAPI) for Ncat SSL cert verification instead of out-of-date cert bundle[/+]