The figure below calls out
- The netfilter hooks
- The order of table traversal
//Thanks to: | |
//http://www.benjiegillam.com/2012/06/node-dot-js-ssl-certificate-chain/ | |
//For the code to pass a CA bundle (multiple certs in one file) as an array | |
//which fixes certificate errors on some browsers when doing https.createServer(options | |
//This is how you can fix that with nodejitsu's http-proxy when using SNI | |
// to have a server listening and returning multiple ssl certs |
require "Subprocess" | |
require "tmpdir" | |
# | |
# Currently will only convert a single swift code file into a static library | |
# and cannot include any Objective-C code. | |
# | |
# Usage: generate("/path/to/MyCode.swift", :ios) | |
# | |
def generate(file, platform, dst=nil) |
var mongoose = require('mongoose'), | |
Schema = mongoose.Schema, | |
ObjectId = Schema.ObjectId; | |
mongoose.connect('mongodb://localhost/testy2'); | |
var UserSchema = new Schema({ | |
name: String | |
}); |
// | |
// SimpleScrollingStack.swift | |
// A super-simple demo of a scrolling UIStackView in iOS 9 | |
// | |
// Created by Paul Hudson on 10/06/2015. | |
// Learn Swift at www.hackingwithswift.com | |
// @twostraws | |
// | |
import UIKit |
import Foundation.NSNotification | |
#if !COCOAPODS | |
import PromiseKit | |
#endif | |
/** | |
To import the `NSNotificationCenter` category: | |
use_frameworks! | |
pod "PromiseKit/Foundation" |
{0: 'tench, Tinca tinca', | |
1: 'goldfish, Carassius auratus', | |
2: 'great white shark, white shark, man-eater, man-eating shark, Carcharodon carcharias', | |
3: 'tiger shark, Galeocerdo cuvieri', | |
4: 'hammerhead, hammerhead shark', | |
5: 'electric ray, crampfish, numbfish, torpedo', | |
6: 'stingray', | |
7: 'cock', | |
8: 'hen', | |
9: 'ostrich, Struthio camelus', |
#!/bin/bash | |
# (In this case) default gateway is 192.168.1.3, alternate is 192.168.1.1. | |
# Usually default is either .1 or .254 - pay attention. | |
# If anything involving CDNs is involved, use https://github.com/hadess/resolvconf-override . | |
# Add new routing table, which uses alternate gateway by default | |
echo 100 altgateway >> /etc/iproute2/rt_tables | |
# Mark traffic sourced from UID as needing to go via other gateway (4 is arbitrary) |
Sometimes a python script will simply hang forever with no indication of where things went wrong. Perhaps it's polling a service that will never return a value that allows the program to move forward. Here's a way to see where the program is currently stuck.
Install gdb.
# Redhat, CentOS, etc
/* | |
* Copyright (c) 2011-2013 NVIDIA Corporation. All rights reserved. | |
* | |
* Redistribution and use in source and binary forms, with or without | |
* modification, are permitted provided that the following conditions are met: | |
* | |
* Redistributions of source code must retain the above copyright notice, | |
* this list of conditions and the following disclaimer. | |
* | |
* Redistributions in binary form must reproduce the above copyright notice, |