- This topic has 0 replies, 1 voice, and was last updated 10 years, 4 months ago by hackerman1.
- AuthorPosts
-
- 26th May 2014 at 19:22 #44828
How to enable the DNS-cache only when needed
For security-reasons it´s a good idea to disable the DNS-cache in order to prevent DNS-cache poisoning.
But what if you have a program fx. a VPN that needs to have the DNS-cache enabled ?
In the example below I´m using CyberGhost VPN.You need two bat-files, the first starts the CyberGhost-service & the DNS-cache, the second stops them.
Start CyberGhost.bat
SC START Dnscache
SC START CGVPNCliService
START "CYBERGOST" "E:PROGRAM FILESCyberGhost 5CyberGhost.lnk"
Note: the 2nd line is to the service that CyberGhost uses.
The 3rd line is a shortcut to the “main” program (GUI) of CyberGhost,
so if you are using some other VPN-program then of course you will have to modify those 2 lines,
by changing the service & path to the program you are using,Stop CyberGhost.bat
SC STOP CGVPNCliService
SC STOP Dnscache
Note: you have to run those 2 bat-files elevated (as ADMIN).
If you set the CGVPNCliService to start automatically then you can run the start-file without elevation.But if you have used the stop-file and then wants to run the start-file again,
then it needs elevation because CGVPNCliService needs ADMIN-privileges.Put the bat-files in in your program-folder, create 2 shortcuts on your desktop.
Then for both shortcuts: under Properties → Advanced, mark “Run as Administrator”.
- AuthorPosts
- You must be logged in to reply to this topic.