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
var http = require('http'); | |
var options = { | |
host: 'ze.garambrogne.net', | |
port: 80, | |
path: '/' | |
}; | |
var cpt = 0; | |
var good = 0; |
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
import time | |
import pcap, dpkt, socket | |
# code stolen from: | |
# http://bramp.net/blog/2010/01/follow-http-stream-with-decompression/ | |
pc = pcap.pcap('eth0') | |
count = 0 | |
ports = (80, 8080, 888) | |
# Pcap writer |
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
import time | |
from socket import socket | |
import collectd | |
sock = None | |
CARBON_SERVER = '127.0.0.1' | |
CARBON_PORT = 2003 | |
def config(conf): | |
collectd.debug('Configuring Stuff') |
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/env python | |
from multiprocessing import Process, Pipe | |
from SimpleHTTPServer import SimpleHTTPRequestHandler | |
import SocketServer | |
ROOT = "." | |
def webserver(conn): | |
PORT = 8000 |
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
-module(basho_bench_driver_carbon). | |
% basho bench needs only two functions | |
-export([new/1, run/4]). | |
-include("basho_bench.hrl"). | |
-record(state, { | |
host, | |
port, |
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/env python | |
import sys | |
# Lamson is an application, but also the best way to read email without | |
# struggling with "battery include" libraries. | |
from lamson.encoding import from_string as parse_mail | |
from pyelasticsearch import ElasticSearch | |
from pyelasticsearch.exceptions import ElasticHttpNotFoundError |
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
{"facets": { | |
"facet1": { | |
"terms_stats": { | |
"key_field": "@fields.path", | |
"value_field": "@fields.time", | |
"order": "total", | |
"size": 20 | |
}, | |
"facet_filter": { | |
"fquery": { |
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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing! | |
VAGRANTFILE_API_VERSION = "2" | |
Vagrant.configure(VAGRANTFILE_API_VERSION) do |main_config| | |
main_config.vm.define :alice do |config| | |
# All Vagrant configuration is done here. The most common configuration | |
# options are documented and commented below. For a complete reference, |
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
# -*- mode: ruby -*- | |
# vi: set ft=ruby : | |
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing! | |
VAGRANTFILE_API_VERSION = "2" | |
Vagrant.configure(VAGRANTFILE_API_VERSION) do |main_config| | |
main_config.vm.define :alice do |config| | |
# All Vagrant configuration is done here. The most common configuration | |
# options are documented and commented below. For a complete reference, |
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/env python | |
import socket | |
import sys | |
import re | |
DOMAIN = re.compile("https?://([a-zA-Z0-9.-_]*\.[\w]{2,})") | |
dejavue = set() | |
for line in sys.stdin: |