⚠️ Note 2023-01-21
Some things have changed since I originally wrote this in 2016. I have updated a few minor details, and the advice is still broadly the same, but there are some new Cloudflare features you can (and should) take advantage of. In particular, pay attention to Trevor Stevens' comment here from 22 January 2022, and Matt Stenson's useful caching advice. In addition, Backblaze, with whom Cloudflare are a Bandwidth Alliance partner, have published their own guide detailing how to use Cloudflare's Web Workers to cache content from B2 private buckets. That is worth reading,
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
wget http://archive.ubuntu.com/ubuntu/pool/universe/p/polipo/polipo_1.1.1-8_amd64.deb | |
sudo dpkg -i polipo_1.1.1-8_amd64.deb |
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 requests, signal, sys, argparse | |
from requests.auth import HTTPBasicAuth | |
p = argparse.ArgumentParser("./camera.py -h <ip> -p <port>", version="0.1") | |
p.add_argument("-ip", "--ipaddress", dest="ipaddress", help="Enter an ipaddress") | |
p.add_argument("-p", "--port", dest="port", default="8081", help="Enter a port") | |
args = p.parse_args() |
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
# | |
# The word 'password', hashed with many unsalted hash types, up to 5 iterations deep | |
# Courtesy MDXfind - https://hashes.org/mdxfind.php | |
# (Mirror: https://www.techsolvency.com/pub/bin/mdxfind/) | |
# Source: https://gist.github.com/roycewilliams/5e8d676ac4fe54fb7b6cb233b0721f57 | |
# | |
# See also: | |
# https://github.com/roycewilliams/kens-salty-rainbow # Common default descrypt hashes | |
# https://gist.github.com/roycewilliams/794e4d7a81e7840deae29fdc7c03fa10 # 10k rounds MD5 | |
# https://gist.github.com/roycewilliams/1c8044e40ed0716f99a773036a8891ac # 10k rounds SHA1 |
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
#doc2vec parameters | |
vector_size = 300 | |
window_size = 15 | |
min_count = 1 | |
sampling_threshold = 1e-5 | |
negative_size = 5 | |
train_epoch = 100 | |
dm = 0 #0 = dbow; 1 = dmpv | |
worker_count = 1 #number of parallel processes |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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/env python3 | |
""" | |
License: MIT License | |
Copyright (c) 2023 Miel Donkers | |
Very simple HTTP server in python for logging requests | |
Usage:: | |
./server.py [<port>] | |
""" | |
from http.server import BaseHTTPRequestHandler, HTTPServer |
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
# 1 | |
location / { | |
set $mobile 0; | |
if ($http_user_agent ~* "iphone|android") { | |
set $mobile 1; | |
} | |
if ($mobile = 1) { | |
# return or rewrite to somewhere | |
} | |
} |
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
Port: 1080 | |
1. Create a file /YOUR PATH/gitproxy.sh with content: | |
#!/bin/sh | |
nc -X 5 -x 127.0.0.1:1080 "$@" | |
2. Edit your ~/.gitconfig | |
# For git:// |
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
{ | |
"acap": 674, | |
"afp": 548, | |
"dict": 2628, | |
"dns": 53, | |
"file": null, | |
"ftp": 21, | |
"git": 9418, | |
"gopher": 70, | |
"http": 80, |
NewerOlder