View Get-AvProviders.ps1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Get-ChildItem -Path "HKLM:\SOFTWARE\Microsoft\Security Center\Provider\Av" | Get-ItemProperty |
View Enumerators.ps1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Flags()] enum ProductState | |
{ | |
Off = 0x0000 | |
On = 0x1000 | |
Snoozed = 0x2000 | |
Expired = 0x3000 | |
} | |
[Flags()] enum SignatureStatus | |
{ |
View install_wrt.helpers.ps1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Install-Module wrt.helpers -Scope CurrentUser -Force | |
Test-IsProductStateOn 39756 |
View Test-IsProductStateOn.ps1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Test-IsProductStateOn { | |
<# | |
.SYNOPSIS | |
Tests if given product state has product state flag to On | |
.DESCRIPTION | |
Registry, WMI and other properties may contain a DWORD value or data object that represents the state of the corresponding product. | |
Specific state of the product is set to a bit in this DWORD, these states can be optained using bitwise operations. | |
This function will return true if the flag for product state is set to on, meaning this product is enabled. | |
.PARAMETER ProductState | |
The value (DWORD) containing the bitflags. |
View .txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
displayName : Windows Defender | |
instanceGuid : {D68DDC3A-831F-4fae-9E44-DA132C1ACF46} | |
pathToSignedProductExe : windowsdefender:// | |
pathToSignedReportingExe : %ProgramFiles%\Windows Defender\MsMpeng.exe | |
productState : 393472 | |
timestamp : Wed, 01 Apr 2020 16:56:49 GMT | |
PSComputerName : |
View gather_ciminstance.ps1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Get-CimInstance -Namespace root/SecurityCenter2 -ClassName AntivirusProduct |
View New-SelfSignedAlwaysEncryptedCertificate.ps1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$storeLocation = "CurrentUser" | |
$certPath = "Cert:" + $storeLocation + "\My" | |
$cert = New-SelfSignedCertificate -Subject "cert1" -CertStoreLocation $certPath -KeyExportPolicy Exportable -Type CodeSigningCert -KeySpec None -KeyUsage KeyEncipherment -HashAlgorithm sha256 -TextExtension @("2.5.29.37={text}1.3.6.1.5.5.8.2.2,1.3.6.1.4.1.311.10.3.11") | |
# keep in mind the Serviceaccount needs access to the private key, permissions need to be set and also the location would need to be altered. |
View vtx.lua
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- | |
-- *Fixed version of wkochFPV for BF 3.5 | |
-- Original: https://github.com/betaflight/betaflight/issues/3094#issuecomment-302953603 | |
-- Note: If you put it on a 3-way switch and go from first to third position fast it may not register correctly so better step through slowly | |
-- | |
-- *Changes: | |
-- Corrected loading of dependencies | |
-- Shortened filename to make it compatible with latest opentx restrictions | |
-- Added a condition in the script for pit mode (vtx power 0 alone didn't work for me) | |
-- |
View cre_name_kv_secr.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#we create a randomized name, the name of the keyvault has to be unique within the current cloud | |
#it will be publicly available using this name. | |
keyvaultName="keyvault-$(cat /proc/sys/kernel/random/uuid | cut -c-7)" | |
keyvaultURI=$(az keyvault create --name $keyvaultName --resource-group "ContosoResourceGroup" --location eastus --query "properties.vaultUri" --output tsv) | |
az keyvault secret set --vault-name $keyvaultName --name "ExamplePassword" --value "sampleSecretValueIn_plaintext" | |
tenantID=$(az account show --output tsv --query tenantId) |
View cre_rg.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
az group create --name "ContosoResourceGroup" --location eastus |
NewerOlder