Android about HTTPS SSL handshake aborted problem Lookup
Document the location process and problem location of this problem
1, Problem Description:
The project was changed to use the HTTPS protocol, and the error code was found when accessing:
域名:https://sandbox.api.xxx.com
错误:SSL handshake aborted: ssl=0x5ef8e720: I/O error during system call, Connection reset by peer
Error description: HTTPS handshake aborted (handshake failed) when using SSL, causing the TCP connection to be reset. So what is the reason for this?
2, search problem keyword find solutions:
Explanation of Reason on stackoverflow.com: click link stackoverflow
3, possible problems analysis and troubleshooting SSL protocol issues?
such as: The Android version is different to the use of SSL Support protocol version (TLS1.1 TLS1.2, etc.) is not the same
Click to view sslsocket instructions
Protocols Client Socket
Protocol |
supported (API levels) |
Enabled By default (API levels) |
SSLv3 |
1 + |
1 + |
TLSv1 |
1 + |
1 + |
TLSv1.1 |
16+ |
20+ |
TLSv1.2 |
16+ |
20+ |
Server Socket:
Protocol |
supported (API levels) |
Enabled By default (API levels) |
SSLv3 |
1 + |
1–22 |
TLSv1 |
1 + |
1 + |
TLSv1.1 |
16+ |
16+ |
TLSv1.2 |
16+ |
16+ |
* Port issues?
4, auxiliary positioning method:
Assist with server-side analysis through packet capture the final discovery is the server Nagix
(1) Packet capture analysis process
Android TCP dump Capture packet analysis
Command Memo:
/data/local/tcpdump -p -vv -s 0 -w /sdcard/ThinkDrive.pcap
Pull Thinkdrive.pcap file to PC using Wireshark analysis, (my analysis of this problem found that the client sends the clients Hello service side does not return clinet Hello and public key so there is a problem with server-side processing
(2) How to modify the host and other file information auxiliary service side (operation and maintenance) debugging
Unable to chmod ***: Read-only file system
How to solve the problem
- 1.ROOT your phone
- 2. After login with adb shell, switch to root user with Su root and display # number after switching, indicating successful switchover
- 3. Reload the file system with the Mount command: Mount-o rw,remount Yaffs2/system
Note :
Hosts file format problem, if the encoding format is not possible to cause the hosts to fail, recommend the way directly on Android echo "ip domain" >> /system/ects/hosts
.
Last: found that the operation of the configuration nginx in the negotiation of the SSL symmetric encryption algorithm is a problem.
Android about HTTPS SSL handshake aborted problem Lookup