Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@mtigas
mtigas / 0.md
Last active October 6, 2019 03:46

A new version of this report is located at ProPublica. Includes more detail and a comment from Susan Prosser, Vice President of Industry Relations at DomainTools, about the how the DomainTools "IP Explorer" tool gathers the "C block owner" value.


The new version mostly just adds information, but previous versions of this gist can still be seen at the "Revisions" button to the left. Earlier versions should be considered draft quality.


@mtigas
mtigas / sunrise.html
Created June 7, 2010 08:25
Messing with HTML5 canvas to create a daylight clock visualization.
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" lang="en-US">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title>Sunlight</title>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js" type="text/javascript"></script>
<script type="text/javascript">/*<![CDATA[*/
// TODO automate getting this data somehow
// http://aa.usno.navy.mil/data/docs/RS_OneDay.php
@mtigas
mtigas / 1-ssldump.md
Last active February 13, 2019 21:24
patches for ssldump. see also https://github.com/mtigas/homebrew-ssldump

Patches for ssldump

Patches for [ssldump][ssldump] (the last ssldump-0.9b3.tar.gz version).

You can install a Mac OS X version of ssldump with these patches included, using [Homebrew][brew]. Check https://github.com/mtigas/homebrew-ssldump for instructions.


Patch 2-ssldump-tls12.diff adds information about new TLSv1.2 cipher suites

#!/bin/bash
# Wraps the standard tar command with the xz (LZMA2)
# compression program since Mac OS X's old version of `tar`
# doesn't have the -I shortcut flag.
#
# Requires XZ Utils.
#
# On Mac OS X with homebrew, you can get XZ Utils via:
# brew install xz
#import "CustomOverlayView.h"
#import "TileOverlay.h"
#import "Three20Network/Three20Network.h"
#pragma mark Private methods
@interface CustomOverlayView()
- (NSUInteger)zoomLevelForMapRect:(MKMapRect)mapRect;
- (NSUInteger)zoomLevelForZoomScale:(MKZoomScale)zoomScale;
- (NSUInteger)worldTileWidthForZoomLevel:(NSUInteger)zoomLevel;
- (CGPoint)mercatorTileOriginForMapRect:(MKMapRect)mapRect;
@mtigas
mtigas / 0001.markdown
Last active February 15, 2018 17:04
Command-line s3 uploader that uses the MultiPart (chunked) S3 upload functionality to parallelize and speed up large file uploads.
@mtigas
mtigas / ciphertest.sh
Last active February 12, 2018 13:22
test what SSL ciphersuites a given server supports
#!/usr/bin/env bash
#
# Modified version of http://superuser.com/a/224263
#
# You should make sure you have an OpenSSL 1.0.1+ installed. (Mac OS X? Use homebrew.
# This script automatically hooks into homebrew's installation of 1.0.1e, see line 22.)
#
#######
#
# usage:
@mtigas
mtigas / 01.md
Last active January 6, 2018 00:40
some notes about meltdown & spectre patches

(originally from a tweet thread: https://twitter.com/mtigas/status/949337073495916544 )

updated january 5, 2018; 12:47 US Eastern Time

ok here's a rough list of links i have collected about patches for meltdown / spectre https://kb.cert.org/vuls/id/584653 , that i sort of compiled for my own reference but figure others might want. (info as of this morning, january 5. might have mistakes, use at own risk, etc)


MacOS High Sierra 10.13.2+, Sierra 2017-002 security update, and El Capitan 2017-005 security update mitigate meltdown:

<!--somewhere in the headers or in a site-wide JS file or right before you need a retina snippet -->
<script>var SR=SR||{};SR.RETINA=((window.devicePixelRatio !== undefined)&&(window.devicePixelRatio >= 2));</script>