Skip to content

Instantly share code, notes, and snippets.

View ligurio's full-sized avatar
💥

Sergey Bronnikov ligurio

💥
View GitHub Profile
@afresh1
afresh1 / palm_keyring2pwsafe.pl
Created July 11, 2013 06:27
A script to turn a Palm Keyring file into a PasswordSafe v3 file. http://gnukeyring.sourceforge.net/ http://passwordsafe.sourceforge.net/
#!/usr/bin/perl
########################################################################
# Copyright (c) 2013 Andrew Fresh <andrew@afresh1.com>
#
# Permission to use, copy, modify, and distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
#
# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
@afresh1
afresh1 / make_updated_ports.pl
Last active December 28, 2015 14:49
A script that will create updated "starter" Makefiles for OpenBSD perl ports available on the CPAN. Should only require things in the base system, but does like an up-to-date /usr/ports path.
#!/usr/bin/perl
use strict;
use warnings;
# Copyright (c) 2013 Andrew Fresh <andrew@afresh1.com>
#
# Permission to use, copy, modify, and distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
#
@ducu
ducu / hners-most-followed.md
Last active August 18, 2016 13:45
Top 1000 Most Followed by HNers - see https://github.com/ducu/twitter-most-followed
Rank Popularity Followers Friends Name (@twitter)
1 12476 13377 0 Hacker News 20 (@newsyc20)
2 5266 3781036 872 TechCrunch (@TechCrunch)
3 4600 17099119 165 Bill Gates (@BillGates)
4 3921 8836866 411 A Googler (@google)
5 3890 3115526 72 WIRED (@WIRED)
6 3562 31793932 131 Twitter (@twitter)
7 3488 4289712 2773 Mashable (@mashable)
8 3410 151838 2197 The Hacker News (@TheHackersNews)
@reyk
reyk / openbsd-amd64-20160809-aws
Last active September 13, 2016 10:02
OpenBSD running in Amazon EC2 m4.10xlarge
i-31d911ba 6895748\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\+2179952|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/
import os
import pytest
import cs
import hashlib
import time
import socket
import io
from paramiko.client import SSHClient, AutoAddPolicy
from paramiko.rsakey import RSAKey
@reyk
reyk / openbsd-amd64-20151210-aws
Last active June 12, 2017 04:25
OpenBSD running in Amazon EC2 t2.micro (no networking yet)
\|/booting hd0a:/bsd: -\|/-6867204\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-+2173200\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/-\|/
@afresh1
afresh1 / unifi.sh
Last active January 11, 2018 18:52
Command-line interface for the OpenBSD Ubiquiti [unifi port](http://ports.su/net/unifi)
#!/bin/sh
basename $0 |&
IFS=- read -p name cmd
if [ -z "$cmd" -a $# -gt 0 ]; then
cmd=$1
shift
fi
cmd=${cmd%svc}
@EmmanuelKasper
EmmanuelKasper / kvm-autostable
Last active February 21, 2018 09:28
A script to automatically install Debian Wheezy on a KVM guest
#!/bin/sh
# You can optionally connect to the VM with
# virt-viewer -c qemu:///system Debian7
export OS=Debian7
virt-install \
--connect qemu:///system \
--name ${OS} \
--ram 1024 \
--vcpus 1 \
@robinsmidsrod
robinsmidsrod / memtest-report.cgi
Last active March 16, 2018 17:17
Simple CGI script used to store memtest results + iPXE SMBIOS information and VRAM screenshot (Work-In-Progress)
#!/usr/bin/env perl
use CGI;
use URI::Escape;
use MIME::Base64;
my $q = CGI->new();
my $result = $q->param('result');
my $vram = MIME::Base64::decode_base64( $q->param('vram') );
@travisdahlke
travisdahlke / ledger2beancount.py
Created November 7, 2014 18:57
Ledger to Beancount
#!/usr/bin/python
import ledger
import sys
import re
def account_name(post):
account = post.account.fullname().replace(" ","").replace("(","").replace(")","").replace("'","")
return re.sub(r'\:(\d)',r':X\1', account)