This file contains hidden or 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
nf_conntrack | |
nf_conntrack_ipv4 | |
nf_conntrack_ipv6 | |
nf_defrag_ipv4 | |
nf_defrag_ipv6 | |
nf_nat | |
nf_nat_ipv4 | |
nf_tables | |
nf_tables_inet | |
nf_tables_ipv4 |
This file contains hidden or 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
table inet firewall { | |
chain incoming { | |
type filter hook input priority 0; | |
# bad tcp -> avoid network scanning: | |
tcp flags & (fin|syn) == (fin|syn) drop | |
tcp flags & (syn|rst) == (syn|rst) drop | |
tcp flags & (fin|syn|rst|psh|ack|urg) < (fin) drop # == 0 would be better, not supported yet. | |
tcp flags & (fin|syn|rst|psh|ack|urg) == (fin|psh|urg) drop |
This file contains hidden or 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/ruby | |
require 'net/http' | |
require 'cloudfiles' | |
require 'colorize' | |
require 'uri' | |
i = 0 | |
skipto = ARGV[0].to_i | |
snooze = ARGV[1].to_f |
This file contains hidden or 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
// trivial HTTP server | |
package main | |
import ( | |
"flag" | |
"fmt" | |
"log" | |
"net/http" | |
) |
This file contains hidden or 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
/* | |
FizzBuzz in GO, as a webserver... | |
*/ | |
package main | |
import ( | |
"flag" | |
"fmt" | |
"net/http" | |
c "strconv" |
This file contains hidden or 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
/* http://tools.ietf.org/html/rfc6455#section-5.2 | |
0 1 2 3 | |
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 | |
+-+-+-+-+-------+-+-------------+-------------------------------+ | |
|F|R|R|R| opcode|M| Payload len | Extended payload length | | |
|I|S|S|S| (4) |A| (7) | (16/64) | | |
|N|V|V|V| |S| | (if payload len==126/127) | | |
| |1|2|3| |K| | | | |
+-+-+-+-+-------+-+-------------+ - - - - - - - - - - - - - - - + | |
| Extended payload length continued, if payload len == 127 | |
NewerOlder