Skip to content

Instantly share code, notes, and snippets.

@rqu1
rqu1 / checkmk.py
Last active August 4, 2024 16:42
check if a PAN firewall is using the default master key when globalprotect is enabled
from hashlib import md5, sha1
from cryptography.hazmat.primitives.ciphers import Cipher, algorithms, modes
from cryptography.hazmat.backends import default_backend
from base64 import b64encode, b64decode
import sys, time
import requests
DEFAULT_MASTERKEY=b'p1a2l3o4a5l6t7o8'
class PanCrypt():
#include "mt7620a.dtsi"
#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>
/ {
compatible = "linksys,ea6100", "ralink,mt7620a-soc";
model = "Linksys EA6100";
nand {
@out0xb2
out0xb2 / Check-Dbx.ps1
Last active September 11, 2024 17:23 — forked from mattifestation/UEFISecDatabaseParser.ps1
Parses signature data from the pk, kek, db, and dbx UEFI variables.
Write-Host "Checking for Administrator permission..."
if (-NOT ([Security.Principal.WindowsPrincipal] [Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole] "Administrator")) {
Write-Warning "Insufficient permissions to run this script. Open the PowerShell console as administrator and run this script again."
Break
} else {
Write-Host "Running as administrator — continuing execution..." -ForegroundColor Green
}
$patchfile = $args[0]
@jamesy0ung
jamesy0ung / Microsoft Static Activation Keys
Created September 26, 2020 22:37
Microsoft Static Activation Keys for many Microsoft products
Access 2003 Developer Extensions: KHCYK-2DXWD-6D4BV-9D9K6-TT9RY
Access 2003: HVCBT-WQ823-BHMJC-RQJ3P-9T9VT
Advanced Threat Analytics (ATA): F3JM7-7QNWQ-KKFVP-PDDRT-4M6P7
Automatic Graph Layout: HWQWP-RXKVP-PJ4BB-9KD87-K67H2
Commerce Server 2002: QJY77-8G8BD-3FYFQ-FDFH3-4RDCP
CRM 2011 Server Edition: 36D7J-FR6QG-JXPF6-H449P-2P6RR
CRM 2011 Workgroup Server Edition: 73B26-GWVRK-GDX7X-MDQBX-DH28R
CRM 3.0 Professional Edition: D2Q47-3K4QX-FPVDT-P4QT6-3C8H8
CRM 3.0 Small Business Edition: TD7BB-D2H87-27KJH-VMH3P-QTQYW
CRM 4.0 Enterprise Edition: WQWYD-FHH7F-XQPCK-2B8KG-D6VT3
@DanielSmon
DanielSmon / New MS Teams Profile.cmd
Last active June 19, 2024 23:48
For running multiple MS Teams accounts side by side. Save this with the name of the MS Teams profile you wish to use. When launched, a folder will be created in your user profile. See https://danielsmon.com/2020/04/02/multiple-ms-teams-accounts-on-the-desktop/.
@ECHO OFF
REM Uses the file name as the profile name
SET MSTEAMS_PROFILE=%~n0
ECHO - Using profile "%MSTEAMS_PROFILE%"
SET "OLD_USERPROFILE=%USERPROFILE%"
SET "USERPROFILE=%LOCALAPPDATA%\Microsoft\Teams\CustomProfiles\%MSTEAMS_PROFILE%"
REM Ensure there is a downloads folder to avoid error described at
@PatrickLang
PatrickLang / README.md
Last active June 10, 2024 18:36
Yubikey + Windows

Using a Yubikey 4 on Windows

These are my notes on how to set up GPG with the private key stored on the hardware Yubikey. This will reduce the chances of your GPG private key from being stolen, and also allow you to protect other secrets such as SSH private keys.

It's just some notes and a partial worklog for now, but I may turn it into a full blog post later.

@IISResetMe
IISResetMe / ConvertTo-Object.ps1
Last active July 25, 2023 23:12
Quick and dirty regex-based text-to-object parsing using named expressions groups and $Matches
function ConvertTo-Object {
param(
[Parameter(Mandatory=$true,ValueFromPipeline=$true)]
[AllowEmptyString()]
[string[]]$InputString,
[Parameter(Mandatory=$true,ValueFromRemainingArguments=$true)]
[string[]]$Pattern
)