What I want to do is be able to intercept all DNS requests a user would make. After intercepting the request, I would then send the request to my server which would then check if the domain name matches one in it's list. If it does match I want to send back another domain name or IP address.
I've looked briefly at NEDNSProxyManager. Will I be able to intercept DNS requests with this? Are there any other libraries I can use to intercept DNS requests?
- User tries to access "test.fakedomain.com"
- Intercept DNS request and send request to Server (through established web socket connection)
- Server responds with "not in list go to testsite.com" message if the domain name is not in it's list and the User can continue to proceed to the specified URL
- If the Server responds with "in list" message the User does not proceed to go to "test.fakedomain.com" and the user will go to the specified URL in the Server's message instead.