Skip to content

Instantly share code, notes, and snippets.

View habemus-papadum's full-sized avatar

Nehal Patel habemus-papadum

  • Boston, USA
View GitHub Profile
@habemus-papadum
habemus-papadum / main.swift
Last active April 21, 2022 18:12
Single File Swift 3 Gui Sample
// A reminder to myself on how to quickly create a throw away gui app on OSX (i.e. a single file,
// w/o relying on XCode project templates
//Notes: In general it is hard to know how to create a Cocoa based gui without using XCode.
//This issue has existed for both Objective-C and now Swift
//Furthermore, Swift<-->Cocoa syntax has changed dramatically over various Swift versions,
//making stackoverflow posts unreliable
//This file provides a template for creating a throw away gui app
@habemus-papadum
habemus-papadum / gist:3b0ed878881b92c71f217492ec1caa1e
Created April 10, 2018 15:02 — forked from mtigas/gist:952344
Mini tutorial for configuring client-side SSL certificates.

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