Skip to content

Instantly share code, notes, and snippets.

View tuian's full-sized avatar

tuian

View GitHub Profile
@tuian
tuian / make-lnk.ps1
Created September 5, 2022 14:43 — forked from mttaggart/make-lnk.ps1
make-lnk.ps1
param ( [string]$SourceExe, [string]$DestinationPath, [string]$IconPath)
$WshShell = New-Object -comObject WScript.Shell
$Shortcut = $WshShell.CreateShortcut($DestinationPath)
$Shortcut.RelativePath = "..\..\..\..\..\..\..\..\..\$SourceExe"
$Shortcut.IconLocation = $IconPath
$Shortcut.TargetPath = $SourceExe
$Shortcut.Save()
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows Defender]
"DisableAntiSpyware"=dword:00000001
"DisableRealtimeMonitoring"=dword:00000001
"DisableAntiVirus"=dword:00000001
"DisableSpecialRunningModes"=dword:00000001
"DisableRoutinelyTakingAction"=dword:00000001
"ServiceKeepAlive"=dword:00000000
import base64
import re
import xml.dom.minidom
import json
import uuid
import struct
import string
import random
import hashlib
import time
@tuian
tuian / get-shodan-favicon-hash.py
Created October 17, 2021 03:45 — forked from yehgdotnet/get-shodan-favicon-hash.py
Get Shodan FAVICON Hash
# https://twitter.com/brsn76945860/status/1171233054951501824
pip install mmh3
-----------------------------
# python 2
import mmh3
import requests
response = requests.get('https://cybersecurity.wtf/favicon.ico')
favicon = response.content.encode('base64')
@tuian
tuian / List of API endpoints & objects
Created September 17, 2021 16:49 — forked from yassineaboukir/List of API endpoints & objects
A list of 3203 common API endpoints and objects designed for fuzzing.
0
00
01
02
03
1
1.0
10
100
1000
@tuian
tuian / ssl-scraper.py
Created September 10, 2021 16:52 — forked from jfmaes/ssl-scraper.py
extract hostnames based on SSL certificates
#!/usr/bin/python
import requests
from socket import *
from requests.packages.urllib3.contrib import pyopenssl as reqs
from requests.packages.urllib3.exceptions import InsecureRequestWarning
requests.packages.urllib3.disable_warnings(InsecureRequestWarning)
import argparse
import ipaddress
#import asyncio
@tuian
tuian / gist:2dd2f0f2cb4e7cfd0b4ce5f60ca99e3a
Created September 2, 2021 15:35 — forked from mgraeber-rc/gist:bfc80007cb8816d029ff116928a76e76
Extensions scrutinized by the AssocIsDangerous
.ade
.adp
.app
.asp
.bas
.bat
.cer
.chm
.cmd
.cnt
Install-Module NtObjectManager
Import-Module NtObjectManager
$Servers = Get-RpcServer -Path C:\Windows\system32\efssvc.dll `
-DbgHelpPath 'C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\dbghelp.dll'
$EfsInterace = $Servers | Where-Object { $_.InterfaceId -eq 'df1941c5-fe89-4e79-bf10-463657acf44d' }
$client = Get-RpcClient -Server $EfsInterace
$client.Connect()
@tuian
tuian / Find-VulnerableSchemas.ps1
Created July 30, 2021 08:52 — forked from IISResetMe/Find-VulnerableSchemas.ps1
Find-VulnerableSchemas.ps1
# Dictionary to hold superclass names
$superClass = @{}
# List to hold class names that inherit from container and are allowed to live under computer object
$vulnerableSchemas = [System.Collections.Generic.List[string]]::new()
# Resolve schema naming context
$schemaNC = (Get-ADRootDSE).schemaNamingContext
# Enumerate all class schemas
@tuian
tuian / dns_server.py
Created March 18, 2021 09:17 — forked from samuelcolvin/dns_server.py
requires python 3.5+ and dnslib, see https://github.com/samuelcolvin/dnserver for full/better implementation
from datetime import datetime
from time import sleep
from dnslib import DNSLabel, QTYPE, RD, RR
from dnslib import A, AAAA, CNAME, MX, NS, SOA, TXT
from dnslib.server import DNSServer
EPOCH = datetime(1970, 1, 1)
SERIAL = int((datetime.utcnow() - EPOCH).total_seconds())