Hi, I'm Robinson, and I’m happy to help you today.
I know how frustrating this may be for you but I'll do my very best to help you.
Here is some troubleshooting that you can try and should fix this error.
Solution 1: Download and run the Windows defender troubleshoot.
https://aka.ms/EasyFix_WindowsFirewall
Solution 2: Check if the required services are running
1-Right-click on Start then click on Run
2-Type: services.msc and click on OK
3-Search for Windows Defender Firewall and Base Filtering Engine
4-Make sure that their Startup type is set to Automatic. To do this, double-click on the service to open up the Properties window. There, in front of Startup type, choose Automatic and click to Start
Solution 3: Reset the Windows firewall
1-Right-click on Start and select Windows PowerShell(admin)
2-Run these commands:
netsh advfirewall reset (and press Enter)
net start mpsdrv (and press Enter)
net start mpssvc (and press Enter)
net start bfe (and press Enter)
regsvr32 firewallapi.dll (and press Enter)
3-Reboot your PC
Solution 4: Restore Windows to a previous point.
1-Restart your computer while holding the SHIFT button
2-The Advanced Startup menu will open on the boot.
3-Go to Troubleshoot.
4-Now, go to Advanced Options > System Restore
5-Select a point before the problem starts and click to restore