Skip to content

Instantly share code, notes, and snippets.

I contributed to the Semaphore Trusted Setup Multi-Party Ceremony.
The following are my contribution signatures:
Circuit: semaphore16
Contributor # 35
Hash: 606f3c2e 4665018f 7e8e6524 5d6f19f7
b021cdb6 4001240d ff21a37d d327851e
d1299494 8e9b030c ca30c5ca f2fd65b4
99aefc8e 05c8c76a 50f48502 c7efa123
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running ‘nixos-help’).
{ config, pkgs, ... }:
let
unstableTarball =
fetchTarball
https://github.com/NixOS/nixpkgs-channels/archive/nixos-unstable.tar.gz;
#!/usr/bin/env python3
import urllib.request
import json
import sys
import re
import shutil
# No, this isn't my own OAuth2 token. It isn't anyone's. It's the default token Twitter gives out to non-signedin users
@proprietary
proprietary / google-api-keys.sh
Created November 10, 2019 17:40
Google API keys for Chromium
# http://security.debian.org/debian-security/pool/updates/main/c/chromium-browser/chromium-browser_60.0.3112.78-1~deb9u1.debian.tar.xz
export GOOGLE_API_KEY="AIzaSyCkfPOPZXDKNn8hhgu3JrA62wIgC93d44k"
export GOOGLE_DEFAULT_CLIENT_ID="811574891467.apps.googleusercontent.com"
export GOOGLE_DEFAULT_CLIENT_SECRET="kdloedMFGdGla2P1zacGjAQh"
@proprietary
proprietary / nextcloud-log.sh
Created October 27, 2019 03:43
pretty print nextcloud log json line by line
#!/usr/bin/bash
# Usage: nextcloud-log.sh [number of recent entries] [logfile]
tail -${1:-10} ${2:-/var/www/nextcloud/data/nextcloud.log} | xargs -L1 -d "\n" -I '{}' sh -c "echo '{}' | python3 -m json.tool"
@proprietary
proprietary / download-chromium.sh
Last active October 1, 2019 00:03
Download Chromium on Linux, Windows, or MacOS
#!/bin/bash
# Download portable binaries of Chromium
# Usage: ./download-chromium.sh {windows,linux,mac} > chromium.zip
#
# If these URLs stop working, this should have it:
# https://github.com/GoogleChrome/puppeteer/blob/master/lib/BrowserFetcher.js
if [ "$1" = "linux" ] ; then
CHROMIUM_PLATFORM=Linux_x64

Keybase proof

I hereby claim:

  • I am proprietary on github.
  • I am zelly (https://keybase.io/zelly) on keybase.
  • I have a public key ASD9bCbFInpbh5w-KGEFJ2s9a4S1_qlYRtiGZOpv5H2KWAo

To claim this, I am signing this object:

@proprietary
proprietary / set_key_repeat_delay.cc
Created November 7, 2018 06:08
How to set key repeat rate and delay (in milliseconds) on Windows 10
#include <windows.h>
#include <stdlib.h>
#include <stdio.h>
BOOL parseDword(const char* in, DWORD* out)
{
char* end;
long result = strtol(in, &end, 10);
BOOL success = (errno == 0 && end != in);
if (success)
First, run the following command to create a blank disk image:
$ hdiutil create -o /tmp/HighSierra.cdr -size 7316m -layout SPUD -fs HFS+J
Next, mount your blank image:
$ hdiutil attach /tmp/HighSierra.cdr.dmg -noverify -nobrowse -mountpoint /Volumes/install_build
Now you’re going to restore BaseSystem.dmg from the installer over to the newly mounted image:
@proprietary
proprietary / send_mail.rb
Created July 19, 2018 07:21
send gmail with ruby net/smtp
require 'net/smtp'
def send_email (to:, msg:, subject:, from_name:, from:, password:)
message = "From: #{from_name} <#{from}>\n" \
"To: <#{to}>\n"\
"Subject: #{subject}\n"\
"#{msg}\n"
smtp = Net::SMTP.new 'smtp.gmail.com', 587
smtp.enable_starttls
smtp.start('gmail.com',