getting there Posted February 24, 2009 Report Share Posted February 24, 2009 HiI have a .reg file that introduces information from an ad server list to the registry.[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\DNS\Zones][HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\DNS\Zones\101com.com]"Type"=dword:00000001"DatabaseFile"="adservers.dns""SecureSecondaries"=dword:00000001"NotifyLevel"=dword:00000001"AllowUpdate"=dword:00000000[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\DNS\Zones\101order.com]"Type"=dword:00000001"DatabaseFile"="adservers.dns""SecureSecondaries"=dword:00000001"NotifyLevel"=dword:00000001"AllowUpdate"=dword:00000000ETC and it goes on, I just include to show that the format/layout continues for each new introduced “key” if that is the “right terminology?”After reading on the net I see to delete a key rather than add a key one would ad “-“ to the front of the key! EG. [-HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\DNS\Zones\101com.com]Still trying to take in what part exactly this deletes and will make sure I understand more before going any further!What I am attempting to do is make a second modified version of the .reg file that would reverse the actions of the first file only removing the new keys or parts of.If I keep reading I will work it out, at this stage I do not have a good enough understanding to use this without backing up the entire registry which would likely not be limited to this files changes alone depending on when you made the restore.I would most likely only want to remove the actual sites from the blocked list, with this I have assumed that remaining sub directories left after the blocked site key was removed will cause no registry problems?If someone can give me an example how the above information could be modified to correctly reverse the action specific to only reverting the first files additions or make any comment helping comments it is appreciated.Am I right in thinking?[-HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\DNS\Zones]Would delete blocked site as well, just thought if they did not have a directory \Zones than Zones\101com.com for example could not exist as it is part of \Zones?My handle here is literal but I work to change it!Getting there Quote Link to comment Share on other sites More sharing options...
ɹəuəllıʍ ʇɐb Posted February 25, 2009 Report Share Posted February 25, 2009 Welcome to the Windows Forum.I don't know where you got that .reg file from, but if you are not 100% sure what it does, or what your own reverse file will do, I would not recommend you to use it.But first things first - whatever you do: make sure that you take a backup of your registry before you make any manual or automatic registry modifications! ERUNT is a proven tool to backup your registry, and allow restore if anything goes wrong.To remove registry keys via a .reg file, you do indeed place a '-' in front of a key, as in your examle[-HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\DNS\Zones\101com.com]This will remove the key 101com.com and all its values and data from the higher-up key HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\DNS\ZonesIf you edit the reverse .reg file with Notepad, you can use the Ctrl+H command to replace all occurrences of '[' by '[-'. But you will have to manually remove all the values and data ("Type"=dword:00000001 ...); if the file is very large, that would be quite a task!What are you actually trying to achieve - blocking certain websites from being accessed? This can be much easier be achieved by using Spybot Search & Destroy. Update it every week on Thursday, then Immunize, and you will have all the "bad" zones blocked. Quote Link to comment Share on other sites More sharing options...
getting there Posted February 25, 2009 Author Report Share Posted February 25, 2009 Hi PatThank you, and glade to be here with the good folk like yourself.My questions here were to cement my understanding; I just wanted to make sure on a specific point which you have described nicely. And the warnings, I could not agree more.It could not be emphasized enough that you should understand and be very confident before making changes to the registry.Thanks for your “-“insertion shortcut, it will be a very handy bit of knowledge in the future.I have ad muncher which works OK and the experience here relates to this particular method but all have limitations.My observation in practice:In practice, blocking ads results in various unintended consequences along with advantages and would seem to be very dependent on the individual’s use of the net so there is no right or wrong answer or one size fits all solution!I find some sites were my browser stalls for a set period which seems indicative of a set minimum period for some ads regardless of whether you see the adAlthough less frequent there are sites were the page will stall indefinitely unless you disable this specific programI Copy and paste from the internet to word frequently to save only specific information rather than WebPages, in many cases this takes a lot longer than when the program is disabled and in some cases will not proceed until the program is disabled.There are a few less annoying consequences that are of little botherEven with the above negative consequences I still see some gain and reduce my data for an already quite internet limited quota only having the more expensive satellite available. For a comparison, only for my own conditions and use patterns I am going to try a few variations, mix and match to see what setup gives the best compromise of function and reduce data.I have installed SimpleServer and placed a small html, a custom error 404 and 1x1 gif in the server directory for a few experiments!The next step I will try the suggestions of Wolfram Kraushaar!Quote:With Microsoft's internal DNS cache. You will need a null zone file (similar to the one provided for use with Bind 8) which he also provided: adservers.dns. This file should go in %SystemRoot%\system32\dns (so, C:\WinNT\system32\dns for most people). • modify the adservers.dns file for your needs • stop the DNS service • download the list of ad servers as a system registry file and save with the extension ".reg" • double click the file and confirm the updates to your system registry to add the servers • restart the DNS service It is the registry knowledge that I needed to understand more confidently before going any further, not that for me it would be the end of the world, worst case scenarios I am quite experienced reformatting and have a fully updated streamed disk with SP3 and Ryan post SP3 updates so might be out of action for a few hours. Love to keep the thread going if you want to discuss my or your opinion/experienceBest getting there Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.