WKWebView Using Custom DNS

Hello,

In an iOS app, using Swift, I'd like to use WKWebView and load a host which isn't defined on public DNS servers, instead I have my own private DNS server that resolves that host.

Is there a way to define a custom DNS resolver, or alternatively define a specific host IP, similar to /etc/hosts?

If your app deployed to normal uses via the App Store? Or to managed environments?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

Private app, it won't be on the App Store.

Private app, it won't be on the App Store.

Does that means it’s deployed into a managed environment? That is, can you use MDM to push configurations to the devices running this app?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

No dear Eskimo, I'm not using MDM - it's just manual installation of the app using X-Code.

We're not all using the same router and would like this to also work outdoors.

So, there’s no way to configure WKWebView with a custom DNS, nor is there a way to intercept all of its network traffic (although that’s a much-requested feature, r. 20545691). In a managed environment you could potentially do this using per-app VPN, but that requires that your app be installed by MDM.

We're not all using the same router and would like this to also work outdoors.

I don’t understand this. Who is “we”, how does the specific router come into play, and what does this have to do with being outdoors?

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

WKWebView Using Custom DNS
 
 
Q