Mobile app version of vmapp.org
Login or Join
Kristi941

: Firefox Addon to override system name resolution for certain host names? Is there any Firefox plugin that allows to change how Firefox perform name resolution? I want to override the system-wide

@Kristi941

Posted in: #Dns #Firefox

Is there any Firefox plugin that allows to change how Firefox perform name resolution? I want to override the system-wide hostname resolver to attach some IP to certain hostnames.

Let me explain. Let's say I'm developing a new website and I want to test using the actual hostname but my site is run by a local webserver, I'd like to do this:

System-wide resolver: domain.com ---> 10.20.30.40
Ovveride by addon: domain.com ---> 127.0.0.1


Is there anything like this? Thank you.

10.02% popularity Vote Up Vote Down


Login to follow query

More posts by @Kristi941

2 Comments

Sorted by latest first Latest Oldest Best

 

@Cooney921

There are many Firefox add-ons that do just this:


HostAdmin
ChangeHosts
SwitchHosts


A search for "Firefox hosts add-on" will yield a whole lot more.

10% popularity Vote Up Vote Down


 

@Megan663

You don't even need a plugin to do that. You can do it with the proxy settings. Specifically, you can use the proxy auto-configuration option with a PAC file that you create. The PAC file is written in javascript. For you it might look something like this:

function FindProxyForURL(url, host) {
if (host=='www.domain.com'){
return 'PROXY 127.0.0.1:80';
}
// All other domains should connect directly without a proxy
return "DIRECT";
}


Save this as my-proxy.pac file and point the proxy auto-configuration at it.

For more information on proxy autoconfiguration, see wikipedia: en.wikipedia.org/wiki/Proxy_auto-config

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme