Skip to content

Instantly share code, notes, and snippets.

@tracyhatemice
tracyhatemice / README.md
Created October 27, 2015 08:38 — forked from hwdsl2/.MOVED.md
IPsec L2TP VPN Auto Install Script for Ubuntu 14.04 & 12.04 and Debian 8
@tracyhatemice
tracyhatemice / ipsec.sh
Created October 29, 2015 12:08 — forked from izhaomin/ipsec.sh
Deploy Strongswan IPSec VPN on Debian/Ubuntu (Experimental)
#!/bin/bash
# for KVM and XEN, modification required for OpenVZ
apt-get -y update
apt-get -y upgrade
apt-get -y install libpam0g-dev libssl-dev make gcc
wget http://download.strongswan.org/strongswan-5.3.0.tar.gz
tar zxvf strongswan-5.3.0.tar.gz
cd strongswan-5.3.0
./configure --enable-eap-identity --enable-eap-md5 --enable-eap-mschapv2 --enable-eap-tls --enable-eap-ttls --enable-eap-peap --enable-eap-tnc --enable-eap-dynamic --enable-eap-radius --enable-xauth-eap --enable-xauth-pam --enable-dhcp --enable-openssl --enable-addrblock --enable-unity --enable-certexpire --enable-radattr --enable-tools --enable-openssl --disable-gmp
make
@tracyhatemice
tracyhatemice / squid.conf
Created October 29, 2015 12:09
Squid cache configuration
acl Safe_ports port 80 21 443 563 70 210 280 488 591 777 1025-65535
acl SSL_ports port 443 563
acl CONNECT method CONNECT
http_access deny !Safe_ports
http_access deny CONNECT !SSL_ports
http_access allow all
http_port 0.0.0.0:21
via off
request_header_access Allow allow all
request_header_access Authorization allow all
@tracyhatemice
tracyhatemice / 0. remote.conf
Created December 29, 2015 13:31 — forked from clowwindy/0. remote.conf
SigmaVPN configure
[peername]
proto = nacltai
proto_publickey = LOCAL_PUBKEY
proto_privatekey = REMOTE_PRIKEY
local = tuntap
local_interface = tunnel
local_tunmode = 1
peer = udp
peer_localaddr = REMOTE_IP
peer_localport = 8000
@tracyhatemice
tracyhatemice / README.md
Created December 29, 2015 17:14 — forked from magnetikonline/README.md
IE 7/8/9/10/11 Virtual machines from Microsoft - Linux w/VirtualBox installation notes.
@tracyhatemice
tracyhatemice / ocserv.init
Created March 23, 2016 08:38 — forked from bolasblack/ocserv.init
/etc/init.d/ocserv
#!/sbin/runscript
DAEMON=/usr/local/sbin/ocserv
PIDFILE=/var/run/ocserv.pid
LOGFILE=/var/log/ocserv.log
DAEMON_ARGS="-f -d 1"
extra_commands="debug"
depend() {
@tracyhatemice
tracyhatemice / squidlog.py
Created May 26, 2016 04:06 — forked from ArthurClune/squidlog.py
Code to read Squid access-log files
#!/usr/bin/env python
"""
Code to read a squid log file
Sample usage:
f = SquidLog('access.log.1.gz')
for l in f:
print l.ts, l.remhost, l.url
@tracyhatemice
tracyhatemice / ocsetup.sh
Created June 1, 2016 08:17 — forked from luginbash/ocsetup.sh
setting up ocserv (open source AnyConnect alternative) on a new Debian, use passwd auth by default
echo "this file isn't supposed to run"
exit 0
# <------------------------------ Enviroment Variables ------------------------------->
FQDN = <Server DNS Name> # can also get from PTR record
ORG_NAME = <Org name>
RELEASE_NAME = $(lsb_release -sc)
# <------------------------------ Network Stack Setups ------------------------------->
# Please edit /etc/default/ufw first
@tracyhatemice
tracyhatemice / gfwlist2regex.py
Created July 1, 2016 03:40 — forked from sorz/gfwlist2regex.py
Download and convert GFWList to url regex which compatible with Squid.
#!/usr/bin/env python
#encoding: utf-8
import urllib2
from base64 import b64decode
LIST_URL = 'https://autoproxy-gfwlist.googlecode.com/svn/trunk/gfwlist.txt'
BLACK_FILE = 'gfw.url_regex.lst'
WHITE_FILE = 'cn.url_regex.lst'
@tracyhatemice
tracyhatemice / auth-basic.conf
Created October 5, 2016 17:25 — forked from Thermionix/auth-basic.conf
nginx reverse proxy for sickbeard, couchpotato etc.
auth_basic "Restricted";
auth_basic_user_file /etc/nginx/htpasswd;