metablaster / windowsfirewallruleset Goto Github PK
View Code? Open in Web Editor NEWPowerShell scripts to automatically create rules for Windows firewall
Home Page: https://metablaster.github.io/WindowsFirewallRuleset/
License: MIT License
PowerShell scripts to automatically create rules for Windows firewall
Home Page: https://metablaster.github.io/WindowsFirewallRuleset/
License: MIT License
Is your feature request related to a problem? Please describe
Thanks for inspiration for scripting my own firewall rules with PowerShell.
Here's an alternative solution for Get-AppSID
, which does not rely on the filesystem, if you'd like to integrate into your scripts.
Describe the solution you'd like
function Get-AppSID {
[CmdletBinding()]
Param(
[Parameter(Mandatory = $True)]
[string]$AppContainerName
)
$sha256 = [System.Security.Cryptography.HashAlgorithm]::Create("sha256")
$hash = $sha256.ComputeHash([System.Text.Encoding]::Unicode.GetBytes($AppContainerName.ToLowerInvariant()))
$sid = "S-1-15-2"
for ($i = 0; $i -lt 28; $i += 4) {
$sid += "-" + [System.BitConverter]::ToUInt32($hash, $i)
}
$sid
}
Additional context
Some tests:
> Get-Acl C:\Users\Me\AppData\Local\Packages\Microsoft.MicrosoftEdge.Stable_8wekyb3d8bbwe\AC\| ForEach-Object { $_.Access | Where-Object { $_.IdentityReference.Value -like "S-1-15-2-*" } | ForEach-Object { $_.IdentityReference.Value } }
S-1-15-2-543634040-274359014-2226501544-3561766748-3991453649-3543631192-522786984
> Get-AppSID "Microsoft.MicrosoftEdge.Stable_8wekyb3d8bbwe"
S-1-15-2-543634040-274359014-2226501544-3561766748-3991453649-3543631192-522786984
> Get-Acl C:\Users\Me\AppData\Local\Packages\Microsoft.MicrosoftEdge_8wekyb3d8bbwe\AC\ | ForEach-Object { $_.Access | Where-Object { $_.IdentityReference.Value -like "S-1-15-2-*" } | ForEach-Object { $_.IdentityReference.Value } }
S-1-15-2-3624051433-2125758914-1423191267-1740899205-1073925389-3782572162-737981194
> Get-AppSID "Microsoft.MicrosoftEdge_8wekyb3d8bbwe"
S-1-15-2-3624051433-2125758914-1423191267-1740899205-1073925389-3782572162-737981194
> Get-Acl C:\Users\Me\AppData\Local\Packages\Microsoft.WindowsStore_8wekyb3d8bbwe\AC\ | ForEach-Object { $_.Access | Where-Object { $_.IdentityReference.Value -like "S-1-15-2-*" } | ForEach-Object { $_.IdentityReference.Value } }
S-1-15-2-1609473798-1231923017-684268153-4268514328-882773646-2760585773-1760938157
> Get-AppSID "Microsoft.WindowsStore_8wekyb3d8bbwe"
S-1-15-2-1609473798-1231923017-684268153-4268514328-882773646-2760585773-1760938157
> Get-Acl C:\Users\Me\AppData\Local\Packages\TheDebianProject.DebianGNULinux_76v4gfsz19hv4\AC\ | ForEach-Object { $_.Access | Where-Object { $_.IdentityReference.Value -like "S-1-15-2-*" } | ForEach-Object { $_.IdentityReference.Value } }
S-1-15-2-924832536-4127917372-3117263579-2243186587-3749335480-97027950-1331681895
> Get-AppSID "TheDebianProject.DebianGNULinux_76v4gfsz19hv4"
S-1-15-2-924832536-4127917372-3117263579-2243186587-3749335480-97027950-1331681895
Hi metablaster,
I'm here to ask you, if you could provide the correct port configuration for league of legends, I'm trying to configure myself for is hard to find the right ones.
Hello,
I would suggest you to add the tool "Firewall Log Viewer for Windows" to the page "Monitoring Firewall" into the Readme folder.
If you contact the developer it's likely they will send you a coupon code for the open source project.
Cheers,
Describe the bug
After applying some security settings in Windows 10 20H2, like enabling Attack Surface Reduction rules (all the rules available), Enable Block at First Sight feature, potentially unwanted applications, cloud protection,extended cloud check and also a in the exploit protection in system settings put everything to on by default, and add a few programs to program settings. It seems to appear the error described in the title.
A clear and concise description of what the bug is.
To Reproduce
Please describe the steps to reproduce the behavior, for example:
Expected behavior
A clear and concise description of what you expected to happen.
If applicable, add screenshots to help explain your problem.
Actual behavior
Describe what is the actual result as opposed to "Expected behavior"
Environment information:
Please provide detailed information about your system as needed:
Any other system information which you consider relevant for the problem, such as:
Additional context
Add any other context about the problem here.
Hi metablaster,
@metablaster I have an issue when I turn on the computer I got an triangle in the network icon, I tried to configure using the scripts available in the project, but it seems that still have the issue. And to get back the connection, I have to disable and enable the adapter 2,3 times in the Network Connections settings in Windows.
Here's a picture of the problem.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.