Skip to content

Instantly share code, notes, and snippets.

View mgeeky's full-sized avatar
💭
Wanna sip a sencha?

Mariusz Banach mgeeky

💭
Wanna sip a sencha?
View GitHub Profile
@LuemmelSec
LuemmelSec / Get-SPVersionInfo.ps1
Last active January 9, 2026 15:34
Script to get SharePoint Version and release date remotely
# Script to check SharePoint version numbers directly with Microsoft
# Usage:
# iex(new-object net.webclient).downloadstring("https://raw.githubusercontent.com/LuemmelSec/Pentest-Tools-Collection/refs/heads/main/tools/Azure/Get-SPVersionInfo.ps1")
# Get-SPVersionInfo -ServerUrl "https://my-sharepointserver"
# Get-SPVersionInfo -InputFile .\targets.txt -SkipCertificateCheck -SkipHttpErrorCheck
function Get-SPVersionInfo {
param (
[string]$ServerUrl,
[string]$InputFile,
@odzhan
odzhan / aperm.py
Created October 18, 2024 15:01
Affine Permutation For Obfuscation
#!/usr/bin/env python3
"""
Affine Permutation File Encoder/Decoder
This script allows you to encode and decode files using an Affine Permutation.
It uses command-line arguments to specify the operation mode (encode or decode), input file, and output file.
Additionally, it stores a SHA256 hash of the original data to verify successful decoding.
Usage:
To encode a file:
@dadevel
dadevel / main.c
Created May 7, 2024 21:30
EFS Trigger
#include <windows.h>
int main() {
HANDLE file = CreateFileA(".\\test.txt", GENERIC_WRITE, FILE_SHARE_WRITE, NULL, OPEN_ALWAYS, FILE_ATTRIBUTE_NORMAL|FILE_ATTRIBUTE_ENCRYPTED|FILE_FLAG_DELETE_ON_CLOSE, NULL);
if (!file || file == INVALID_HANDLE_VALUE) {
return GetLastError();
}
CloseHandle(file);
return 0;
}
@Homer28
Homer28 / test_dll.c
Last active June 29, 2025 09:52
DLL code for testing CVE-2024-21378 in MS Outlook
/**
* This DLL is designed for use in conjunction with the Ruler tool for
* security testing related to the CVE-2024-21378 vulnerability,
* specifically targeting MS Outlook.
*
* It can be used with the following command line syntax:
* ruler [auth-params] form add-com [attack-params] --dll ./test.dll
* Ruler repository: https://github.com/NetSPI/ruler/tree/com-forms (com-forms branch).
*
* After being loaded into MS Outlook, it sends the PC's hostname and
@thesamesam
thesamesam / xz-backdoor.md
Last active September 9, 2026 07:33
xz-utils backdoor situation (CVE-2024-3094)

FAQ on the xz-utils backdoor (CVE-2024-3094)

This is a living document. Everything in this document is made in good faith of being accurate, but like I just said; we don't yet know everything about what's going on.

Update: I've disabled comments as of 2025-01-26 to avoid everyone having notifications for something a year on if someone wants to suggest a correction. Folks are free to email to suggest corrections still, of course.

Background

@adamsvoboda
adamsvoboda / gist:9ac52548d3d81f3185e36b9f0be31990
Created August 30, 2023 15:02
Windows Defender LSASS ASR Exclusion Paths - 08.30.2023
%windir%\system32\WerFaultSecure.exe
%windir%\system32\mrt.exe
%windir%\system32\svchost.exe
%windir%\system32\NETSTAT.EXE
%windir%\system32\wbem\WmiPrvSE.exe
%windir%\system32\DriverStore\FileRepository\*\NVWMI\nvWmi64.exe
%programfiles(x86)%\Microsoft Intune Management Extension\ClientHealthEval.exe
%programfiles(x86)%\Microsoft Intune Management Extension\SensorLogonTask.exe
%programfiles(x86)%\Microsoft Intune Management Extension\Microsoft.Management.Services.IntuneWindowsAgent.exe
%programdata%\Microsoft\Windows Defender Advanced Threat Protection\DataCollection\*\OpenHandleCollector.exe
@hawkeye217
hawkeye217 / fovtest.py
Last active February 5, 2026 09:28
Check if an ONVIF-capable IP PTZ camera supports RelativeMove with FOV
# This script can help you determine if your PTZ is capable of
# working with Frigate NVR's autotracker.
#
# Cameras with a "YES" printed for each parameter at the end of
# the output will likely be supported by Frigate.
#
# Make sure you're using python3 with the onvif-zeep package
# Update the values for your camera below, then run:
# pip3 install onvif-zeep
# python3 ./fovtest.py
general:
cloud_provider: aws
attack_range_password: AW^@#^%&^#@##
use_prebuilt_images_with_packer: '0'
key_name: yourkey-001423
ip_whitelist: 8.8.8.8 #your public ip address
attack_range_name: test-range
aws:
private_key_path: /Users/your/key-001423.key
region: us-west-2
@Washi1337
Washi1337 / DynamicLibrary.cpp
Last active April 21, 2026 12:45
Injecting unconventional entry points in a .NET module. Blog post: https://washi.dev/blog/posts/entry-points/
#include <cstdio>
#include <windows.h>
VOID WINAPI TlsCallback(PVOID DllHandle, DWORD Reason, PVOID Reserved)
{
puts("[DynamicLibrary.dll]: TLS Callback");
}
#ifdef _WIN64
#pragma comment (linker, "/INCLUDE:_tls_used")
@N7WEra
N7WEra / field-config.yaml
Last active February 24, 2026 16:27
Kitana custom field
- name: awss3
type: regex
regex:
- '[a-zA-Z0-9.-]+\.s3\.amazonaws\.com'
- 's3://([^/]+)'
- '[a-zA-Z0-9.-]+.s3\.[a-zA-Z0-9.-]+\.amazonaws\.com'
- '[a-zA-Z0-9.-]+\.s3-website-[a-z0-9-]+\.amazonaws\.com'
- '[a-zA-Z0-9.-]+\.s3\.amazonaws\.com'
- name: awsapps