Block network activity for all exe files with a firewall. How to block program access to the Internet correctly? How to find out who is online

Many software products require an Internet connection in order to function. You do not pay attention to this fact until the connection deteriorates - sites open slowly, everything slows down. And the applications themselves begin to update, download ads, etc. This can seriously complicate the work at the computer. Therefore, it is good to know how to prevent the program from accessing the Internet.

The ability to deny access will remove many problems. Even if the software is not running, it may be listed at startup. Then you do not know about its work at all, but you are surprised at some slowdown of your PC.

How to find out who is online

We will use the system windows tool - "Resource Monitor". The easiest way to find it is through a search. Click on the magnifying glass and enter a title.

Click on the found application and a window will open in which you can observe all the activity of your PC. Go to the "Network" tab.

Look carefully. Are you using Skype now? No? Then you can close it. This will save resources. You will also see other services that access the network without your knowledge.
Naturally, Skype should not be denied access to the Internet. But other programs can be completely prohibited. For example, unlicensed. This will prevent unnecessary downloads of updates.

How to block access to the Internet program

This requires an application called a firewall or firewall. If you use these apps, customize them. If you have an antivirus that allows you to deny it, you can specify it in its parameters. But the easiest way to deny access is to use the built-in Windows firewall. We will tell you how to block the program from accessing the Internet using Windows 10 as an example.

To launch the settings, you can use the search or the main context menu (right button mouse on the "Start" button). We need a control panel.

Switch to the "Categories" view and select "System and Security".

Here you will find what you are looking for. Open up.

A green shield means that the firewall is on.

If you see red, turn on the service. To do this, click on the option "Turn Windows Firewall on or off" on the left and select "Enable".

Attention! If you use a different firewall, then it is better not to enable the built-in one, but to make all the settings in a third-party. Otherwise, conflicts may arise.

Here we need to set up the rules.

To prevent a specific program from accessing the Internet in Windows 10 Firewall, you need to set up inbound and outbound rules.
Let's start with the inbox. Click on "Rules for Inbound Connections". On the right side of the window, you will see "Create Rule". Click.

In the window select "For the program" and click "Next".

Please select the desired programby clicking the Browse button.

Select the option to deny the connection and click Next.

Come up with a name for the rule so you don't get confused later. And click done.

The rule will appear in the list. Its purpose is to prevent applications from receiving data from the network.

Create a rule.

We managed to block the program's access to the Internet with a firewall. These simple steps will help you control the access of programs to the Internet.

Have a great day!

Firewall is software or hardware, which checks incoming information from the Internet or the network, and either blocks it or allows it to pass through the computer, depending on the settings of the firewall itself.

Firewall can help users to protect themselves from hacker attacks or malicious softwarethat can access your computer through your network. The firewall can also help stop malicious files from being sent from your computer to other PCs.

All of the above also applies to Windows Firewall. Some applications require a network connection from time to time. However, the firewall has control over which .exe and dll on your computer connect to public, private, or domain networks.

By default, all applications are blocked by the Firewall. If some application or program is prohibited from communicating with the network, then the Firewall blocks its access. These programs may also include your games that require an Internet connection to run.

In order to set the desired settings in Windows Firewall, you can:

  • Press the buttons simultaneously Win + R.
  • Then enter the query in the "Run" utility line firewall.cpl and press Enter.
  • Select "Allow communication with an application or component in Windows Firewall."

In this window, you can grant permissions to certain programs or add new executable files.

However, when you need to block or unblock more than one executable file on your computer (or if you are developing an application that requires firewall permission), then you need to do a lot of repetitive work for this.

Now we are going to show you how to block multiple files at the same time or even entire folders in Windows Firewall. For demonstration purposes, we will show this method on the Program folder Files.

  • Press the combination of Win + R, write wf.msc and press Enter to open Windows Firewall with Advanced Security.
  • In the very right corner of the window, click on "Export Policies ..." and save them to a file. If something happens during the steps below, you can use this .wfw file to restore policy states.

Blocking multiple .exe files with a BAT file

Through netsh (a scripting tool that allows the Command Line to change settings network connection), you can use the power of the Command Line to change the settings of your Firewall. Since Firewall controls incoming and outgoing connections, you must disable both for your files. To do this, do the following:

  • Open Notepad and copy the following lines into it:

    for %% G in (“C: \\ Program Files (x86) \\ Test Folder \\ *. exe”) do (netsh advfirewall firewall add rule name \u003d ”Blocked With Batchfile %% G” dir \u003d in action \u003d block program \u003d ” %% G ”enable \u003d yes profile \u003d anynetsh advfirewall firewall add rule name \u003d” Blocked With Batchfile %% G ”dir \u003d out action \u003d block program \u003d” %% G ”enable \u003d yes profile \u003d any)

  • Then save text file and change its extension to .bat.
  • Run the created BAT file and you will lock all the files that were specified in the script. Accordingly, replace the line in the script C: \\ Program Files (x86) \\ Test Folder \\ to the one you need.
  • Besides the generated BAT file, you can also use an advanced script that can search for exe files and add them to the block list for Windows Firewall.
  • Again, create a text file and paste the following script into it:

@ echo off
@setlocal enableextensions
@cd / d "% ~ dp0"
color F0
title Exe blocker
echo.
echo. \u003d\u003d Welcome to .exe blocker \u003d\u003d
echo. \u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d
echo.
Echo Current location:% cd%
echo.
CHOICE / C YN / M "Do you want to search in the current location?"
IF Errorlevel 2 goto END
IF Errorlevel 1 goto Yes
:: ——————— CHECK and searching files ——————
: Yes
set location \u003d% cd%
cls
echo.
Echo. Searching for .exe files in% location%
echo.
set / a count \u003d 0
echo.Found:
echo.
FOR %% i in (* .exe) do (echo. %% i & set / a count + \u003d 1)
echo .___________________________________________
echo.
title Exe blocker% count% Files found
echo. Number of files found with .exe extention:% count%
echo.
echo.
set add2 \u003d
CHOICE / C YN / M "Do you want to add aditional information?"
IF Errorlevel 2 goto block
IF Errorlevel 1 goto ADD
:: —————— ADD additional info —————
: ADD
Set / p add \u003d Please type the additonal information for the name:
Set add2 \u003d% add%
:: —————— Add files to firewall —————
: block
cls
title Exe blocker - Blocking Rules
set / a countt \u003d 0
echo.
echo .___________________________________________
echo. Inbound rules
echo .___________________________________________
FOR / r %% B in (* .exe) do (set / a countt + \u003d 1 & echo.% Countt%. %% ~ nxB blocking ... & netsh advfirewall firewall add rule name \u003d "% add2 %%% ~ nxB" dir \u003d in action \u003d block program \u003d "%% ~ dpfnxB")
echo .___________________________________________
echo. OutBound rules
set / a coun \u003d 0
echo .___________________________________________
FOR / r %% B in (* .exe) do (set / a coun + \u003d 1 & echo.% Coun%. %% ~ nxB blocking ... & netsh advfirewall firewall add rule name \u003d "% add2 %%% ~ nxB" dir \u003d out action \u003d block program \u003d "%% ~ dpfnxB")
echo .___________________________________________
Echo. Added files to Firewall
echo.
title Exe blocker - Rules Blocked
Pause
:: ———————— END ———————
: END
cls
ECHO.
Echo. Thanks for using .exe blocker
Echo.
CHOICE / C YN / T 10 / D n / M “Do you want to open firewall? (10 seconds) "
IF Errorlevel 2 goto EXIT
IF Errorlevel 1 goto OPEN
:: —————— Open Firewall —————
: OPEN
start "C: \\ Windows \\ System32" rundll32.exe shell32.dll, Control_RunDLL firewall.cpl

Windows firewall (the same firewall) is responsible for security operating system and protects it from external malicious attacks. To effectively protect their computer, each user should know how to work with a firewall and what alternatives can be applied to it.

Do I need Windows 10 firewall

Definitely needed. Here simplest example: in the last windows versions (starting with 7) joint device management in one local network... This is why multiple computers in offices can access the same printer or any other device. When you disconnect your PC from the network, you don't even think about the dangers of "unsafe disconnection". The fact is that attackers can easily connect to a computer in order to realize their dirty intentions. It is worth making a reservation that they cannot, but could. They could if the firewall was not built into the system. The firewall does not allow “dangerous” inbound and outbound traffic and blocks suspicious activity, which helps keep you and your device safe.

Why does it block applications

The firewall blocks programs due to the fact that it already has a built-in "moral code" - a set of rules, violation of which prevents a data packet from being downloaded to a computer. These rules can be changed at your discretion. If you want - deny all connections to your device, if you want - block access to the Internet for a particular program, if it causes distrust. Blocking various resources helps make your online experience safer.

How reliable is Windows 10 firewall

The built-in firewall performs the same functions as downloadable antiviruses. In contrast, it sends notifications much less frequently, has no ads and does not require paid activation. The firewall runs in the background continuously and cannot shutdown without your command. Therefore, you can rely on it without resorting to the help of additional software. If the application requires access to certain parameters of your computer, a request will come from the firewall, which you will have to confirm.

The firewall asks for user confirmation to continue the program

How to set up a firewall

Configuring a firewall goes in several directions.

How to open a port in Windows 10 firewall

  1. We go to the "Start" menu, there we need the Control Panel.

    Opening the Control Panel

  2. Click on "System and Security" and click on "Firewall".

    Opening Windows Firewall

  3. In the firewall menu, find Advanced Options.

    Selecting Advanced Options

  4. Choosing the Rule for incoming connection and add the required ports.

    Create a new rule for incoming connection

  5. Click "Next" and enter SQL Server into the "Type" line.

    Choosing the type of rule

  6. We indicate the TCP port and the ports we need.

    We indicate the necessary information. In our case, this will be port 433

  7. We select the desired action. We will have it "Allow connection".

    Select "Allow connection"

  8. In the line "Name" we enter the number of our port.

    Finally, we name our port by its number.

Video: How to open ports in Windows 10 Firewall

How to add to firewall exceptions


Video: Configure and Disable Firewall in Windows 10

How to block an application / game in the firewall

To block an application in Windows Firewall, or, in other words, to deny it access to the Internet, you must perform the following steps:

  1. Select the "Advanced options" section in the firewall menu.
  2. Click on "Outbound Connection Rules" and click on "Create Rule"

    Create a new rule for the application

  3. Next, select the rule type "For the program".

    Since we need to exclude the program, we select the appropriate type of rule

  4. Then the system prompts you to select the path of the program. Click the "Browse" button and find desired file programs.

    We leave all the checkboxes in place

  5. And at the end we designate the name of the blocked program in a convenient way and click "Finish". From this moment, Internet access for the application will be blocked.

Video: blocking Internet access for individual programs

Updating the firewall

Updating the firewall is a controversial thing and rather even negative. The fact is that it does not carry any important functions, but it often takes a considerable amount of time. Therefore, some people prefer to disable auto-update of the firewall.


The Firewall control application is one of the supporting programs and is responsible for data security and protects against leakage of this data into the network. The program monitors the operation of ports and allows you to choose on what conditions applications will connect to the network.

The program interface is simple and concise

Many applications require a stable internet connection to function properly. They often look for updates in the background, and some are able to download them without user confirmation. Users also have the ability to block the program from accessing the Internet using the built-in operating windows systems 10.

This article will tell you how to prevent any application from accessing the Internet on a computer under windows management 10. And it is also possible to block Internet access not only for programs, but also for games. To use the method suggested below, you must have administrator rights in Windows 10.

Allow communication with apps in Windows 10 Firewall

Firewall Windows Defender helps protect your computer from intruders or malware on the Internet or local network. Configuring application communication permissions in the firewall allows you to easily block any application from accessing Windows Internet 10. It is enough for the user to uncheck the public network in front of the program whose access should be denied to block it.

The user just needs to find the application in the explorer to add. And also indicate the types of networks for which you want to add this application. After adding the required application, similarly uncheck the public network opposite the program.

How to add an app to Windows 10 Firewall exception

To add applications to firewall exceptions, you need to create rules for outbound and inbound connections. For more information about firewall exceptions, see the instructions:. By creating simple rules, you can easily block any program from accessing the Internet.


At the end, it is enough to indicate the name and description of the new rule, and then click done. By analogy, we create a rule for outbound connection in monitoring the Windows Defender Firewall. For rules and Internet blocking to work, the firewall must be enabled. Relevant for users who used to.

If you have a metered plan and want to improve control over data usage, set up your connection as a metered network. tariff plan... Some applications may work differently to reduce data usage when connected to this network.

  1. Go to Start\u003e Settings\u003e Network & Internet\u003e Status and press the button Change connection properties.
  2. Point value Set as metered connection change to Included.


Conclusion

You can block access to the Internet for an application by using the capabilities of the Windows Defender Firewall. The user has the option to remove the permission to communicate with applications in the firewall or simply add the application to the Windows 10 firewall exception. Alternatively, you can set the current connection as metered, this is the method we considered if necessary.

The need to block a certain Internet resource most often arises from parents who do not want their child to view this site. But ordinary users should also know how to block a site so that it does not open in any of the browsers.

Self-locking

You can block access yourself by making changes to the settings of Windows OS, firewall or browser. The Vkontakte website (vk.com) will be used as an example.

In the hosts file

The easiest way to block access to a specific portal on the Internet is to add it to the list of the hosts file.

  1. Enter "notepad" in the search bar → RMB on the application → Run as administrator.
  2. Menu File → Open.
  3. Specify the file type at the bottom right → All files.
  4. Go to the path: disk with the installed OS → Windows → System32 → drivers → etc → hosts.
  5. To add a site to the "black" list, make an entry at the end of the file in the format: 127.0.0.1 vk.com, where:
    127.0.0.1 - IP, which must be indicated in the entry before each site to be blocked;
    vk.com - the address of the portal to block.

    Important! Each new resource is written on a new line. And for more effect, you need to make two entries with and without www.


  6. Save changes and restart your PC.

Disadvantages of the method:

  • the user, faced with a similar situation, will immediately view the hosts file;
  • it is valid for Windows only.

In the firewall

Windows Firewall blocks resources by their IP address, so you need to find out first.

  1. RMB on the Start menu → Command line (administrator).
  2. Enter: ping resource_address.
  3. Remember / write down the ip address.
  4. Search for "firewall" → Windows Firewall with Advanced Security.
  5. Outbound rules → Create rule.
  6. Specify the following parameters:

In browsers

Resources cannot be locked in Chrome regular means... This requires the installation of additional extensions. Therefore, this method is suitable for Internet browsers that support the installation of add-ons.

Google chrome


In the settings you can block:

  • sites;
  • portals in the addresses of which certain words are indicated;
  • resource for a specific time.

In addition, you can set a password to change the settings of the extension, which is distributed free of charge, and set BlockSite to work in Incognito mode.

Mozilla Firefox


Opera

  1. Menu -\u003e Extensions -\u003e Download Extensions -\u003e find and install Adult Blocker.
  2. LMB on extension → set a password.
  3. Go to the site that needs to be closed for visiting → LMB by extension → Blacklist.

Using services

Close access to specific resources in The world wide web you can use special services.

Using Yandex.DNS, you can close sites for children, protecting them from viewing inappropriate content, restrict access to resources containing malware or fraudulent sites.


OpenDNS

In addition to blocking unwanted sites, OpenDNS offers a wide range of additional features. But since setting up this method requires an understanding of how the OS works, the method is suitable only for experienced users.

  1. Register at OpenDNS Home (you can do this for free) → confirm your registration by clicking on the link from the letter that came to your email.

    Helpful! After specifying the login and password, you will be taken to a page with instructions for setting up the service for a computer, router, smartphone and DNS server. But it is presented in English.


  2. Open the instructions for the method that suits you (DNS server is an option for the corporate segment). Then configure the appropriate node.
    • Computer
    • Router
      Used as an example router Asus RT-N12E.
  3. If the work was done correctly, go to the OpenDNS Dashboard settings panel in the Setting section → specify the IP address assigned to you by your provider (it should appear in the line automatically) → click Add this network → Done.
  4. If you are using dynamic IP address, install the special utility that is offered for installation when assigning a name to the connection being created. Its task is to send your current IP information when using a router.
  5. Click on the IP address and in the "Manage individual domains" block specify all the sites to which you want to close the connection → select Always Block from the drop-down list → Add Domain → Block vk.com - just the individual domain → Ok.

In the router settings