I used Ktor as the server to exchange ICE and SDP.
Then, I developed two apps: a SERVER and a CLIENT. The SERVER creates a hotspot, and the CLIENT connects to this hotspot. After exchanging SDP, they exchange ICE candidates. The ICE candidates are successfully added on both sides, but the connection ultimately fails. Both the SERVER and CLIENT have added each other's ICE candidates with the correct IP addresses, and they can successfully ping each other.
The ICE candidate sent from the SERVER to the CLIENT:
0:0:candidate:183835596 1 tcp 1518149375 192.168.43.1 9 typ host tcptype active generation 0 ufrag jC0z network-id 6 network-cost 10::UNKNOWN
The ICE candidate sent from the CLIENT to the SERVER:
0:0:candidate:4235452027 1 udp 2122194688 192.168.43.240 49403 typ host generation 0 ufrag tVLL network-id 3 network-cost 10::UNKNOWN
I've been struggling with this issue for several days and sincerely hope to find a solution. Thank you very much!