How to use .key and .pem file to create SSL socket in Android?

My .key file is like: ----- START RSA PRIVATE KEY ----- MIIEpAIBAAKCAQEA1j6eGXbHpqigZ1K // wnuyr5v / L2jFm7dzTtHJx8ZoMQ4CbsG

My .pem file, for example: ----- START CERTIFICATE ----- MIIE4zCCA8ugAwIBAgIDBOziMA0GCSqGSIb3DQEBBQUAMDwxCzAJBgNVBAYTAlVT

I do not know how many authentication steps are here. I just want to create an ssl socket for IP and port and send / receive data on this socket. I tried to use the cache, but maybe I do not understand it deeply, I am always mistaken.

Please give me a guide or sample code.

Many thanks.

+5
source share
2 answers

, .key .pem , HTTPS. , Java/Android , BKS.

BKS .key + .pem , KeyStore Explorer. KeyStore Explorer → → BKSv1. → .pem. KeyStore Explorer .key.

, .

BKSv1 BKSv1 Android. ., , , : / SSL Android

+9

SSL- , , . SSL X509, , .

X.509.

0

All Articles