socket.io-client-swift icon indicating copy to clipboard operation
socket.io-client-swift copied to clipboard

`WSS` protocol does not trigger secure config

Open om-ha opened this issue 4 years ago • 0 comments

If protocol is wss instead of https, then secure is not set to true.

https://github.com/socketio/socket.io-client-swift/blob/a1ed825835a2d8c2555938e96557ccc05e4bebf3/Source/SocketIO/Manager/SocketManager.swift#L569-L570

This should be:

 if socketURL.absoluteString.hasPrefix("https://") ||  socketURL.absoluteString.hasPrefix("wss://") { 
     _config.insert(.secure(true)) 

om-ha avatar Feb 05 '22 14:02 om-ha