TLS connection using SSLSocket is slow in Android OS

后端 未结 4 1066
感动是毒
感动是毒 2020-12-28 22:33

I\'m developing an Android app which uses SSLSocket to connect to a server. This is the code I\'m using:

// Connect
if (socket == null || socket.isClosed() |         


        
4条回答
  •  攒了一身酷
    2020-12-28 23:11

    I have done something similar to this and it is slower than an unsecured connection. Granted my case was https vs http and it is a little different the SSL/TLS factor will add slowness to the deal.

    I have two identical apps that comunicate with the same protocol to the same server, one in android and one in iPhone, both using https. When I tested them both in http I would see more or less the same response time, in https iOS was slightly faster in my case, but not terribly.

提交回复
热议问题