Skip to content

Instantly share code, notes, and snippets.

View mhahl's full-sized avatar
👁️‍🗨️
Oh, hi Mark!

Mark Hahl mhahl

👁️‍🗨️
Oh, hi Mark!
  • Canberra, Australia
View GitHub Profile
@mhahl
mhahl / cert-production.sh
Created August 5, 2020 22:06 — forked from user890104/cert-production.sh
Certbot / Letsencrypt Wildcard DNS with nsupdate hook
# This will issue a production (valid and trusted) certificate
certbot certonly --agree-tos --manual --preferred-challenge=dns --manual-auth-hook=./hook.sh --register-unsafely-without-email --manual-public-ip-logging-ok -d '*.example.com' -d 'example.com' --server https://acme-v02.api.letsencrypt.org/directory
@mhahl
mhahl / gist:37e06e1e9bddcf4df30d
Created October 20, 2015 04:16 — forked from ericchen/gist:2656869
receive data from one client and forward data to tcp server on remote
require 'rubygems'
require 'eventmachine'
require "socket"
module GwServer
# @server_socket = TCPSocket.open('127.0.0.1', 3000)
# @queue = []
class GwTcpClient < EventMachine::Connection
@mhahl
mhahl / .nvimrc
Last active August 29, 2015 14:27 — forked from jthomas/.nvimrc
NeoVim configuration
call plug#begin('~/.vim/plugged')
Plug 'tpope/vim-sensible'
Plug 'tpope/vim-fugitive'
Plug 'altercation/vim-colors-solarized'
Plug 'scrooloose/syntastic'
Plug 'scrooloose/nerdtree'
Plug 'kien/ctrlp.vim'
Plug 'bling/vim-airline'
Plug 'jelera/vim-javascript-syntax'
@mhahl
mhahl / gist:e41595556b06b36f8651
Last active August 29, 2015 14:27 — forked from robertklep/gist:5124355
X11 keylogger
#include <stdio.h>
#include <stdlib.h>
#include <signal.h>
#include <netdb.h>
#include <string.h>
#include <netinet/in.h>
#include <X11/X.h>
#include <X11/Xlib.h>
#include <X11/Intrinsic.h>
#include <X11/StringDefs.h>
@mhahl
mhahl / fingerd.rb
Last active August 29, 2015 14:26 — forked from peterc/fingerd.rb
#!/usr/bin/env ruby
require './app'
require 'eventmachine'
class FingerServer < EM::Connection
def receive_data(data)
data.strip!
if data =~ /\A\w+\z/