This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<VirtualHost *:80> | |
ServerName local.site | |
ProxyPass / http://local.site:81/ timeout=9999999 | |
ProxyPassReverse / http://local.site:81/ | |
RequestHeader unset Accept-Encoding | |
AddOutputFilterByType SUBSTITUTE text/html | |
Substitute s/www.site/local.site.nl/ni | |
Header edit Location ^http://www. http://local. | |
</VirtualHost> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#/etc/NetworkManager/NetworkManager.conf | |
[main] | |
plugins=ifcfg-rh | |
dns=dnsmasq | |
#[keyfile] | |
#unmanaged-devices=mac:01:23:45:67:89:AB |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
rpm -U http://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpm | |
rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-6 | |
yum update -y | |
yum install -y gcc wget tar gzip nasm zlib-devel perl ncurses-devel gcc-c++ libxml2-devel libmcrypt-devel bzip2-devel curl-devel libtidy-devel httpd-devel libtool-ltdl-devel mysql-server | |
# build freetype | |
mkdir -p /opt/php-5.2.10/freetype-2.6/src/ | |
cd /opt/php-5.2.10/freetype-2.6/src/ | |
wget http://download.savannah.gnu.org/releases/freetype/freetype-2.6.tar.gz | |
tar xzf freetype-2.6.tar.gz |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#http://blog.alexjj.com/2014/04/quick-start-guide-to-dm-crypt-with-luks.html | |
cryptsetup benchmark | |
cryptsetup --cipher aes-xts-plain64 --key-size 512 --hash sha512 --iter-time 5000 --use-random --verify-passphrase luksFormat /dev/sda2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set wildmode=longest,list | |
set tabstop=4 | |
set shiftwidth=4 | |
set expandtab | |
color beauty256 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
# tar -Oxf /Volumes/install_app/Packages/Essentials.pkg Payload|python pbzx.py|tar t | |
import subprocess | |
import struct | |
import sys | |
def pbzx(): | |
if sys.stdin.read(4) != "pbzx": | |
print "Not a pbzx stream" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
import subprocess | |
import sys | |
import struct | |
def pbzx(): | |
if sys.stdin.read(4) != "pbzx": | |
print "Not a pbzx stream" | |
sys.exit(1) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3 | |
import tty | |
import termios | |
import sys | |
import subprocess | |
def getchar(): | |
#Returns a single character from standard input | |
fd = sys.stdin.fileno() | |
old_settings = termios.tcgetattr(fd) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import subprocess | |
import time | |
time.sleep(.2) | |
password = subprocess.check_output(['secret-tool', 'lookup', 'keyboard', 'play']) | |
subprocess.call(['xdotool', 'type', password]) | |
subprocess.call(['xdotool', 'key', 'Return']) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# docker build -t="dockerproxy" . | |
FROM whatever | |
RUN yum install -y httpd mod_ssl | |
ADD ./proxy.py /root/bin/proxy.py | |
CMD python /root/bin/proxy.py | |
EXPOSE 80 443 | |
ADD *.crt /etc/pki/tls/certs/ | |
ADD *.key /etc/pki/tls/private/ |