Use dnsagent to intercept specific domain names

Source: Internet
Author: User

When developing the program, it is necessary to send the data sent to ABC.com to the local to facilitate testing.

The simplest method is to modify the abc.com directly in the program and modify it to the desired address.

However, when committing the code, it is easy to submit the debug address to the server.

or embedded device is not convenient to modify the address.

So think of it from the DNS above.

1. Run dnsagent on the PC to enable the DNS proxy feature.

2. Modify the router configuration, use a custom DNS address, point to the machine running DNS server.

Connect the device that needs to be debugged to the modified router so that the router assigns the custom DNS to the device via DHCP.

The device then queries the DNS server for the domain name, modifies dnsagent's rules.cfg to specify the domain name that needs to be debugged as a custom address.

Use dnsagent to intercept specific domain names

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.