The purpose of these scripts is to help implement HTTPS Everywhere using acmetool and F5 BigIP LTM.
Set up acmetool as normal.
#!/usr/bin/python | |
# vim: set ts=4 sw=4 et ai si: | |
import socket | |
import struct | |
def getpeereid(sock): | |
LOCAL_PEERCRED = 0x001 | |
fmt = struct.Struct('2Ih16I') # see /usr/include/sys/ucred.h struct xucred | |
res = tuple(fmt.unpack(sock.getsockopt(0, LOCAL_PEERCRED, fmt.size))) |
I hereby claim:
To claim this, I am signing this object:
os_http_be.map and os_sni_passthrough.map are both just empty files |
package proxy | |
import ( | |
"io" | |
"log" | |
"net" | |
) | |
func Proxy(srvConn, cliConn *net.TCPConn) { | |
// channels to wait on the close event for each connection |