Remove Trojan Patched.AO and Fix DNSAPI.dll Missing Error

This article is dedicated to helping users remove Trojan Patched.AO and fix the DNSAPI.dll missing  error, which may be connected to the trojan virus family, as users commonly refer to them. The DNSAPI.dll Missing Error can also be displayed on its own, but much of the time it is “broken” by the trojan in question.


Again, if you are here for the dnsapi.dll missing error, this may be related to a trojan virus called Win32/Patched.AO. The removal guide will provide solutions for both the error and the virus, if there is one.

Despite being predominantly called Viruses by most users, in reality Trojans are not, as surprising as this sounds. They are still very much malicious and dangerous, but the fine distinction between viruses and malware is that viruses can replicate and regenerate themselves even if you delete them. They have in-built capabilities to do so. Trojan Win32/Patched.AO and DNSAPI.dll Missing Error can not. Facts point that if you manage to remove them once, they will not come back to bother you again. That is why there is an entirely different classification called “malware” and this is the one the trojan belongs to.

dnsapi dll missing error

What is a Trojan?

The simplest explanation is the classical one. Just as the famous trojan horse it was named after, this type of malware serves as a front or back door, depending how you look at it. They basically get in and leak information to whoever created them, as well as serve as a weak point in the security system of your computer. If a Trojan is associated with another virus it can help that virus install itself on your machine without your authorization or knowledge. Hackers who create Trojans are often paid by hackers who make other viruses in order to use the network of infected computers to distribute their malicious work.

How does DNSAPI.dll Missing Error factor in the work of the Trojan?

The DNSAPI.dll file is a library file used by Windows in task related to internet access and for this reason it is often targeted by threats like Trojan Win32/Patched.AO. It is used by Window’s DNS Client API and if it has been tampered with or corrupted Windows cannot process the settings inside, thus causing a variety of DNS Client error files to pop up. A list of these errors include:

  • This application failed to start because DNSAPI.DLL was not found. Re-installing the application may fix this problem.
  • Dnsapi.dll not found.
  • The file Dnsapi.dll is missing.
  • Dnsapi.dll Access Violation.
  • Cannot register dnsapi.dll.
  • Cannot find C:WindowsSystem32\dnsapi.dll.

These errors will most often pop during start-up after a system power-on/reboot, but they can also appear when another program on your computer tries to access Dnsapi.dll. These errors are a sure sign you have a serious Trojan-related problem.

DO NOT try to simply replace Dnsapi.dll on your computer without dealing with the Trojan! It will remain installed on your compter and also there are many fake sites that offer manipulated .dll files. Even if the error disappears it could be because the .dll file is written more cleverly and Windows cannot recognize that the file is not the original one.

If you are seeing any of these errors on your computer then you must take adequate action against Trojan Win32/Patched.AO. The fact that Dnsapi.dll has been changed renders your computer vulnerable and also makes any firewall you have impotent in adequately dealing with attempts to install viruses on your computer. The more you wait the greater the chances you will have a bigger collection of other threats to deal with.


Name Patched.AO and DNSAPI.dll
Type Potentially Unwanted Programs and Files
Danger Level Medium.
Symptoms Unwanted Ads and Toolbars, search engine redirects.
Distribution Method Software bundles, Email attachments, online Ads, infected torrent files.
Detection Tool

Remove Trojan Patched.AO and DNSAPI.dll

Things readers are interested in:


Our first step here is a reboot in Safe Mode. If you already know how to do it, just skip this and proceed to Step 2. If you do not know how to do it, continue reading:

For Windows 98, XP, Millenium and 7 Users:

Restart your computer. To be sure you don’t miss the time when you need to press it, just spam F8 as soon as the PC starts booting. In the new menu, choose Safe Mode With Networking.

Proceed to Step 2.

For W. 8 and 8.1 Users:

Click the Start button ,then Control Panel —> System and Security —> Administrative Tools —> System Configuration.Administrator permission required


Then check the Safe Boot option and click OK.  Click  Restart in the new pop-up.

Proceed to Step 2.

For Windows 10 Users:

  1. Open the Start menu.
  2. Click the power button icon in the right corner of the new Start menu to show the power options menu.
  3. Press and hold down the SHIFT key on the keyboard and click the Restart option while still holding down the SHIFT key.

Windows 10 will perform the reboot. Next do the following:

Click the Troubleshoot icon, then Advanced options —> Startup Settings. Click Restart.
After the reboot click on Enter Safe Mode With Networking (Fifth Option).

Continue with Step 2.

 STEP 2:

Once you have rebooted in Safe Mode (if you skipped the previous step, go back and do it) type cmd in the Search Field. Righ Click on it and choose Run as Administrator. In the new window that will appear type sfc /scannow and press Enter. Wait for the verification process to finish. You should get the following message:

DNSAPI dll removal

At this point, you successfully removed the DNSAPI.dll missing error. The error can manifest on its, but it’s often caused by the presence of a trojan. It’s time to check if there is a trojan in your system and deal with it. More than likely it should be Trojan Win32/Patched.AO


To remove parasite, you may have to meddle with system files and registries. Making a mistake and deleting the wrong thing may damage your system.
Avoid this by using SpyHunter - a professional Parasite removal tool.

Keep in mind, SpyHunter’s malware detection tool is free. To remove the infection, you'll need to purchase its full version. More information about SpyHunter and steps to uninstall.

Hold the Windows Key and R and copy + paste the following, then click OK:

notepad %windir%/system32/Drivers/etc/hosts

A .txt file will open – don’t touch anything there. If you are hacked and someone has access to your PC, there will be a bunch of other IPs connected to you at the bottom. This is what a hosts file looks like:

hosts_opt (1)

If there are a bunch of strange IPs connecting to you below “Localhost” you may be hacked, and it’s best to ask us in the comments for directions.

Now hold the windows Key and R again but type %temp% in the field and hit enter. Delete everything in that directory.

 STEP 4:

Right click on each of the malware processes separately and select Open File Location. Also, End the process after you open the folder. Just to make sure we don’t delete any programs you mistakenly took for a malware, copy the folders somewhere, then delete the directories you were sent to. There’s a good chance Trojan Win32/Patched.AO is hiding somewhere in here.


This is perhaps the most important and difficult step, so be extremely careful. Doing this can damage your PC significantly if you make a big mistake. If you are not feeling comfortable, we advise you to download a professional rojan Win32/Patched.AO remover. Additionally, accounts connected to your credit cards, or important information, may be exposed to the virus.



Take a look at the following things:

Type msconfig in the search field and hit enter: you will be transported to a new window. 


Go in the Startup tab and Uncheck anything that has “Unknown” as Manufacturer.

Type Regedit in the windows search field and press Enter.

Once inside, press CTRL and F together and type the malware’s Name. Right click and delete any entries you find with a similar name. If you can’t find them this way, look in these directories, and delete the registries manually:

  • HKEY_CURRENT_USER—-Software—–Random Directory. It could be any one of them – ask us if you can’t discern which ones are malicious, but bear in mind they are always different.
    HKEY_CURRENT_USER—-Software—Microsoft—-Windows—CurrentVersion—Run– Random
    HKEY_CURRENT_USER—-Software—Microsoft—Internet Explorer—-Main—- Random


If these things fail to help you find rojan Win32/Patched.AO you need to resort to a professional scanner – obviously this is a malware that was created to steal your credentials and credit cards – meaning the people who created it spent a lot of resources to make it as dangerous as possible.

  • HowToRemove.Guide Team

    Hello fran,
    Happy New Year! 🙂 What was difficult for you in Step 2? Maybe I can walk you through the process.
    In step 3, can you tell me which IPs are you seeing? Some of them are safe, many of them are not, but I can’t really know until you tell me what they are.

  • HowToRemove.Guide Team

    Can you share these IPs? Some may be safe, while others are definitely part of the virus.
    If you have difficulties, download the scanner from one of our apps and it will help you locate the infected files.

  • narendran rajaram

    hai HowToRemove.Guide Team I do get these IP’s below the localhost…… Is that safe? down.baidu2016).com 123.sogou(.com http://www.czzsyzgm.)com http://www.czzsyzxl.)com

    • HowToRemove.Guide Team

      Delete them. They are all part of the infection.

      • narendran rajaram

        Thanks guys for a quick reply!!! Please also say how to remove them.

        • HowToRemove.Guide Team

          Just delete them from the file. You erase the the IPs and close the file. They’ll, you just save it and it’s done. Tell me if this helped you 🙂

          • narendran rajaram

            Guys that somehow helped me… But, every time when I start/restart my pc, the balloon appears (see the image). But, when I run the scan it shows no virus… On startup only it is appearing.. Help me Guys!!!!

          • HowToRemove.Guide Team


            Just to be clear you removed the suspicious IPs completely? Did you execute all others Steps in our guide as described? It is possible the virus might come back if it is not completely eradicated from your system.

  • HowToRemove.Guide Team

    Try downloading the scanner from our ads. It’s likely it can help you detect the infected files and you can hunt them down manually.

  • HowToRemove.Guide Team

    In theory this should have fixed the error, but apparently in your case, it didn’t. Download the scanner from one of our ads and try to hunt down the infected files. Destroy the root infection, then go back and attempt to fix the error with the same steps.
    Did that help?

  • HowToRemove.Guide Team

    To be honest, I haven’t encountered this scenario before. This shouldn’t happen. Try doing the same thing I told Josephie Vanspall to do (the comment below this one) and tell me if it worked. I honestly want to help, I’ll go research the issue, but I hope what I proposed works.

  • HowToRemove.Guide Team

    You just delete it from the lines in the hosts file. Just press backspace or delete and save the file.

  • HowToRemove.Guide Team

    Hi Diego,

    Are you sure you ran the scan with administrator rights? This is very important.

    Please confirm you did before we explore other venues.

  • HowToRemove.Guide Team

    Hello again Diego,

    To be honest i am really stumped. This kind of message should NOT be occurring if you are in Safe Mode and running the operation as an administrator.

    One thing you can do is download a copy of Windows and try to repair your installation. It is slow and cumbersome solution, but it may also fix your DNSAPI.DLL problem.

    I’d very much like to hear from you if this works.

  • HowToRemove.Guide Team

    I definitely think it’s part of the infection.

  • HowToRemove.Guide Team

    Hello Maison,

    I am not sure I understand you completely. Can you explain your issue in details and why do you believe it is related to the Trojan Patched.AO and DNSAPI.dll Missing Error?

  • HowToRemove.Guide Team

    Hi Mike,

    Those are real .dll files needed by windows, but apparently they have been modified by the virus (or rather the original file was replaced). You can fix this by doing a system repair with a Windows DVD. You can also try to manually replace them, but only if you can find a trustworthy source for the files.

  • HowToRemove.Guide Team

    Delete all ips that have susupicious chinese names next to them, then save teh file.

  • HowToRemove.Guide Team

    Hi there, try running the command prompt directly from the run menu, Win+R

  • HowToRemove.Guide Team

    Hi Velson,
    can you post us some of the IPs you think suspicious ? To open the list you can Right click on your Task Bar (usually can be found on the bottom of the desktop) and then click Task Manager or the easiest way is to click Ctrl+Shift+Esc. Then when you have the list of the processes in front of you, each one you think suspicious you can Right click it and then click Open file location. There you can delete it manually. Keep us posted for further assistance .

  • HowToRemove.Guide Team

    You are most welcome James. Remember we are here and we will help you the best way we can :).

  • Kira

    I found some hackers’ DNS in my hosts notepad thing, how do I get rid of them?

    • HowToRemove.Guide Team

      Hi Kira,
      can you please post them here so we can check them?

  • HowToRemove.Guide Team

    Hi Ph,
    you are most welcome! Remember next time to search here first. We will be glad to help you 🙂

  • TJ

    Heya, found a list of unknown IPs underneath mine. To list out the pages here:

    All of the above appeared twice in the list.

    How can I get rid of them?

    • HowToRemove.Guide Team

      Hi TJ,
      you should definitely remove these IPs. Treat the file like a word file just highlight the IPs and click Backspace or Delete.

  • DarkraiKeeper

    How would I remove these guys in my list

    All the same ip

    • HowToRemove.Guide Team

      Hi DarkraiKeeper,
      you should delete these entries.

  • HowToRemove.Guide Team

    Hi Jh7021,
    do you have Administrative Rights ?

  • Sesh

    Under “localhost” Ips there are 8 IPs- directly below my localhost IP, there are 5 copies of my IP but with different host names. Those host names are
    “” And below those 5, there are 3 with the same IP, but different from the one that is associated with the above 5.
    How do I rid of these, permanently?

    • HowToRemove.Guide Team

      Hi Sesh,
      i would suggest to you to delete these IPs. Treat the hosts file like a normal text file and just delete these entries.

  • HowToRemove.Guide Team

    Hi again,
    at this point i would suggest to you to download our software from one of our banners above and use the free scan feature. The scanner will locate any infected file where you can delete manually. Keep us posted if you need further help.

  • HowToRemove.Guide Team

    Hi Adrianti,
    are you executing the steps in Safe Mode ?

  • male

    question. how did I get this virus. I was in the middle playing in online game and I got booted off-line for three hours. I followed the steps you did after I was able to connect the Internet on my phone and when I realized the Internet was working again I followed most of the steps that has to do with CMD. I did not do the rest because you said it is risky and could ruin the computer. So far the CMD thing has worked but the problem is it reverts back to the PC having the same issue after I log off and I have to repeat this instruction over again when I want to get on my PC and connect to the Internet. Is there anyway to fix it?

    • HowToRemove.Guide Team

      Hi male,
      i would suggest to you to complete the guide. Remember every step you execute has to be in Safe Mode.