For educational reasons I've decided to create my own CA. Here is what I learned.
Lets get some context first.
# Hello, and welcome to makefile basics. | |
# | |
# You will learn why `make` is so great, and why, despite its "weird" syntax, | |
# it is actually a highly expressive, efficient, and powerful way to build | |
# programs. | |
# | |
# Once you're done here, go to | |
# http://www.gnu.org/software/make/manual/make.html | |
# to learn SOOOO much more. |
# Simple Recommendation Engine in Ruby | |
# Visit: http://otobrglez.opalab.com | |
# Author: Oto Brglez <[email protected]> | |
class Book < Struct.new(:title) | |
def words | |
@words ||= self.title.gsub(/[a-zA-Z]{3,}/).map(&:downcase).uniq.sort | |
end |
#!/usr/bin/python | |
# -*- coding: utf-8 -*- | |
import urllib2 | |
import HTMLParser | |
import csv | |
import datetime | |
import codecs, cStringIO # for UnicodeWriter | |
response = urllib2.urlopen('http://www.imdb.com/chart/top') |
// Matraka's source code decoded and beautified | |
// by @tlack | |
// | |
// Matraka is a 1005 byte Javascript "demo" by p01. It includes an 'evolving animation' | |
// and great dirty synth music. View here: | |
// | |
// http://www.p01.org/releases/MATRAKA/matraka.png.html | |
// | |
// I fondly recall the demo scene of my youth, puzzling over the work of Future | |
// Creators and those guys. I was puzzled by this worked so I had to figure it |
Latency Comparison Numbers (~2012) | |
---------------------------------- | |
L1 cache reference 0.5 ns | |
Branch mispredict 5 ns | |
L2 cache reference 7 ns 14x L1 cache | |
Mutex lock/unlock 25 ns | |
Main memory reference 100 ns 20x L2 cache, 200x L1 cache | |
Compress 1K bytes with Zippy 3,000 ns 3 us | |
Send 1K bytes over 1 Gbps network 10,000 ns 10 us | |
Read 4K randomly from SSD* 150,000 ns 150 us ~1GB/sec SSD |
Every so often I have to restore my gpg keys and I'm never sure how best to do it. So, I've spent some time playing around with the various ways to export/import (backup/restore) keys.
cp ~/.gnupg/pubring.gpg /path/to/backups/
cp ~/.gnupg/secring.gpg /path/to/backups/
cp ~/.gnupg/trustdb.gpg /path/to/backups/