Skip to content

Instantly share code, notes, and snippets.

Client-side SSL

For excessively paranoid client authentication.

Using self-signed certificate.

Create a Certificate Authority root (which represents this server)

Organization & Common Name: Some human identifier for this server CA.

openssl genrsa -des3 -out ca.key 4096
openssl req -new -x509 -days 365 -key ca.key -out ca.crt
1. Rename the host in the web panel
2. Edit /etc/hostname
3. Edit /etc/hosts
4. Reboot
// TinyBASIC.cpp : An implementation of TinyBASIC in C
//
// Author : Mike Field - [email protected]
//
// Based on TinyBasic for 68000, by Gordon Brandly
// (see http://members.shaw.ca/gbrandly/68ktinyb.html)
//
// which itself was Derived from Palo Alto Tiny BASIC as
// published in the May 1976 issue of Dr. Dobb's Journal.
//
@mcmatrix
mcmatrix / iso.htm
Last active August 29, 2015 14:19 — forked from konsumer/iso.htm
<!DOCTYPE html>
<html>
<head>
<title>Iso Demo</title>
<style>
html, body {
padding:0;
margin:0;
}
#framecounter {
@mcmatrix
mcmatrix / node-red
Last active August 29, 2015 14:20 — forked from Belphemur/node-red
#!/bin/bash
### BEGIN INIT INFO
# Provides: node-red
# Required-Start: $local_fs $remote_fs $network
# Required-Stop: $local_fs $remote_fs $network
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Start or stop the node-red server
### END INIT INFO
# Can be downloaded and installed in one go by using this command
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Upwey Temperatures</title>
</head>
<script type="text/javascript" src="/javascript/jquery_1.8.2/jquery.min.js"></script>
<script src="http://code.highcharts.com/stock/highstock.js"></script>
<script src="http://code.highcharts.com/stock/modules/exporting.js"></script>
<script type="text/javascript">
#!/usr/bin/env bash
# names of latest versions of each package
export VERSION_PCRE=pcre-8.37
export VERSION_OPENSSL=openssl-1.0.2a
export VERSION_NGINX=nginx-1.9.0
# URLs to the source directories
export SOURCE_OPENSSL=https://www.openssl.org/source/
export SOURCE_PCRE=ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/
@mcmatrix
mcmatrix / nginx.conf
Last active August 29, 2015 14:21 — forked from turtlesoupy/nginx.conf
http {
proxy_cache_path /var/cache/nginx levels=1:2 keys_zone=one:8m max_size=3000m inactive=600m;
proxy_temp_path /var/tmp;
include mime.types;
default_type application/octet-stream;
sendfile on;
keepalive_timeout 65;
gzip on;
gzip_comp_level 6;
/*
* object.watch polyfill
*
* 2012-04-03
*
* By Eli Grey, http://eligrey.com
* Public Domain.
* NO WARRANTY EXPRESSED OR IMPLIED. USE AT YOUR OWN RISK.
*/
/*!
* jQuery Tiny Pub/Sub - v0.X - 11/18/2010
* http://benalman.com/
*
* Original Copyright (c) 2010 "Cowboy" Ben Alman
* Dual licensed under the MIT and GPL licenses.
* http://benalman.com/about/license/
*
* Made awesome by Rick Waldron
*