Skip to content

Instantly share code, notes, and snippets.

View richieforeman's full-sized avatar
😻

Richie Foreman richieforeman

😻
View GitHub Profile
@richieforeman
richieforeman / sample.pac
Last active April 2, 2024 19:41
Sample PAC File for Google Apps Deployments
function FindProxyForURL(url, host) {
// Plain hostnames. ( e.g. http://server )
if (isPlainHostName(host)) {
return "DIRECT";
}
// Private address classes.
if (isInNet(dnsResolve(host), "10.0.0.0", "255.0.0.0") ||
isInNet(dnsResolve(host), "172.16.0.0", "255.240.0.0") ||
@richieforeman
richieforeman / list_compare.py
Created October 31, 2012 16:57
Compare two simple files and return the differences
import sys
import os
def read_file(f, split="\n"):
return open(f).read().split(split)
list1 = read_file(sys.argv[1])
list2 = read_file(sys.argv[2])
@richieforeman
richieforeman / makeauthority.sh
Created July 23, 2012 21:38
Issue Your Own Self-Signed S/MIME Certs with OpenSSL
# Run this once
openssl genrsa -des3 -out ca.key 4096
openssl req -new -x509 -days 365 -key ca.key -out ca.crt