Hi Frank. Are you sure you're using the same device cert, same private key, same root CA, same endpoint and same client ID as what you used on your workstation?
- asked a year ago
- asked 5 years ago
- asked 4 years ago
- AWS OFFICIALUpdated 8 months ago
- Do Classic Load Balancers, Application Load Balancers, and Network Load Balancers support SSL/TLS session resumption?AWS OFFICIALUpdated 3 years ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated 3 years ago
- EXPERTpublished 8 months ago
- EXPERTpublished 5 months ago
Yes, I double-checked all of those things. Could it be some sort of a permissions issue where the EC2 user doesn't have permission to open the required TCP ports?
TLS negotiation occurs after the TCP connection is established. So if the error can be taken it face value, it strongly suggests a problem with one of the certificates or with the private key. TLS handshake can also fail due to a timeout, but if your EC2 instance and IoT Core are in the same region, this should not be a factor. What timeout are you using?
Ten seconds, but the error appears much sooner than that. I'll check the certificates again. Maybe it's a permissions issue on the certificate files.
I tried renaming my certificate and key files to see if this would produce a different error, and it did. So that tells me that Java is able to read the files. I also tried editing the files and changing one of the characters in the key or certificate itself, and this again produced a different error. So that tells me it's probably interpreting the key and certificate correctly.
I also tried running the Java command as superuser, figuring the issue might be related to permissions, but that didn't help.