-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Charles Proxy is not tracking wss: traffic #756
Comments
Hey @KonstantinEfimenko. Charles works totally fine with wss and Starscream. Maybe try to check your SSL settings? You need to add your host address to SSL settings and install Charles certificate on your device/simulator to be able to read the traffic. More info here. |
The change you abovementioned was merged to master but at some point removed. I don't think it's needed anymore. |
@michalcichon thanks! |
Yes, it is really strange. I use Starscream with https://github.com/apollographql/apollo-ios and can track only HTTP. On mobile device wss intercepts fine if I set it as mentioned in code.Emulator doesn't intercept at all. In device I set https://chls.pro/192.168.88.XXX:8889.socks.pac in automatic poxy mode. Also set it up in charlesproxy. |
For version 3.1.1, you do need the change @KonstantinEfimenko suggested to match the default socks proxy settings used by Charles. |
Here is the issue: apollographql/apollo-ios#1030 They should update their dependencies in apollo project. |
With current solution b074c6c
Charles Proxy is not tracking wss: traffic, but works fine if we use next solution:
if enableSOCKSProxy {
let socksConfig = CFDictionaryCreateMutableCopy(nil, 0, CFNetworkCopySystemProxySettings()!.takeRetainedValue())
let propertyKey = CFStreamPropertyKey(rawValue: kCFStreamPropertySOCKSProxy)
let dict = socksConfig as? [String: Any]
if let ip = dict?["HTTPSProxy"] as? String, let port = dict?["HTTPSPort"] as? Int {
let customSocksConfig = ["SOCKSProxy": ip, "SOCKSPort": port + 1, "SOCKSEnable": 1] as CFDictionary?
CFWriteStreamSetProperty(outputStream, propertyKey, customSocksConfig)
CFReadStreamSetProperty(inputStream, propertyKey, customSocksConfig)
}
}
in Charles Proxy setting Socks Proxy is enabled on port 8889 and HTTP Proxy on port 8888
Could it be taken in to build?
The text was updated successfully, but these errors were encountered: