Thank you for reaching out. Please find the steps below.
Registry Configuration (Enable TLS 1.3): Run in Command Prompt as Admin or save as .reg
file and double-click:
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.3\Client]
"Enabled"=dword:00000001
"DisabledByDefault"=dword:00000000
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.3\Server]
"Enabled"=dword:00000001
"DisabledByDefault"=dword:00000000
After applying, reboot your system.
Enable TLS 1.3 Cipher Suites\ Run in PowerShell as Administrator:
Enable-TlsCipherSuite -Name "TLS_AES_256_GCM_SHA384"
Enable-TlsCipherSuite -Name "TLS_AES_128_GCM_SHA256"
Enable-TlsCipherSuite -Name "TLS_CHACHA20_POLY1305_SHA256"
Alternatively, set via registry:
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Cryptography\Configuration\SSL\00010002]
"Functions"="TLS_AES_256_GCM_SHA384,TLS_AES_128_GCM_SHA256,TLS_CHACHA20_POLY1305_SHA256"
Reboot after applying changes.
Enable SChannel Logging for Debugging\ Run in PowerShell as Administrator:
New-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL" `
-Name "EventLogging" -Value 7 -PropertyType "DWord" -Force
Logs will appear in Event Viewer → Applications and Services Logs → Microsoft → Windows → Schannel
C++ Code Using SCH_CREDENTIALS for TLS 1.3
#
#
#
#
int main() {
SCH_CREDENTIALS schCred = {};
schCred.dwVersion = SCH_CREDENTIALS_VERSION;
schCred.dwFlags = SCH_CRED_NO_DEFAULT_CREDS | SCH_CRED_MANUAL_CRED_VALIDATION;
CredHandle hCred;
TimeStamp tsExpiry;
SECURITY_STATUS status = AcquireCredentialsHandle(
NULL,
UNISP_NAME,
SECPKG_CRED_OUTBOUND,
NULL,
&schCred,
NULL,
NULL,
&hCred,
&tsExpiry
);
if (status != SEC_E_OK) {
printf("TLS handshake failed with error: 0x%08lx\n", status);
return 1;
}
printf("TLS credentials acquired successfully.\n");
return 0;
}
Note:\ Do not set grbitEnabledProtocols
unless debugging.\ To temporarily allow TLS 1.2 during development, add:
schCred.grbitEnabledProtocols = SP_PROT_TLS1_3 | SP_PROT_TLS1_2;
Remove TLS 1.2 once TLS 1.3 works reliably.
Testing TLS 1.3 Connection
Use OpenSSL to verify TLS 1.3 handshake:
openssl s_client -connect yourserver.com:443 -tls1_3
Use Wireshark to inspect TLS versions in Client Hello and Server Hello packets.
Let us know if the issue persists after following these steps. We’ll be happy to assist further if needed.
If this helps, please mark as Answered.