Life == Software

OSX User/Group Management – Part 2: Groups

This post, Part 2: Groups, will cover creating, modifying, and deleting group accounts on MacOS. The goal is to provide a quick and simple reference for managing group accounts from the command-line using the following native MacOS utilities: Directory Service Command Line Utility: dscl Directory Service Cache Utility: dscacheutil Directory Service Edit Group Utility: dseditgroup If you missed the first iteration of the series, Part 1: Users, I would recommend giving that post a thorough look as well – you won’t be disappointed.

OSX User/Group Management – Part 1: Users

MacOS, like Linux, is a multiuser system that relies on accounts – an abstract term for data structures and procedures used to identify the individual users and groups of a computer. But unlike Linux, MacOS does not have the same simple, easy-to-use utility commands for managing users and groups from the command-line; most long-time Linux enthusiasts have grown accustomed to the useradd, usermod, and userdel commands for creating, modifying, and deleting user accounts.

Cross Compilation in Golang

Makefile ##### EXECUTABLE NAME ##### appname := $(APPNAME) sources := $(wildcard *.go) build = GOOS=$(1) GOARCH=$(2) go build -o build/$(appname)$(3) tar = cd build && tar -cvzf $(1)_$(2).tar.gz $(appname)$(3) && rm $(appname)$(3) zip = cd build && zip $(1)_$(2).zip $(appname)$(3) && rm $(appname)$(3) .PHONY: all windows darwin linux clean all: windows darwin linux clean: rm -rf build/ ##### LINUX BUILDS ##### linux: build/linux_arm.tar.gz build/linux_arm64.tar.gz build/linux_386.tar.gz build/linux_amd64.tar.gz build/linux_386.tar.gz: $(sources) $(call build,linux,386,) $(call tar,linux,386) build/linux_amd64.

Generating SSL Certificates

This guide provides the basic steps needed to generate a self-signed certificate with OpenSSl on a trusted host where you will be testing TLS/SSL connections. Set the filename: FILENAME="server" Generate a 2048 bit RSA key openssl genrsa -des3 -passout pass:x -out "$FILENAME.pass.key" 2048 openssl rsa -passin pass:x -in "$FILENAME.pass.key" -out "$FILENAME.key" rm -f "$FILENAME.pass.key" Generate a certificate signing request openssl req -new -key "$FILENAME.key" -out "$FILENAME.csr" Generate a signed certificate openssl x509 -req -sha256 -days 365 -in "$FILENAME.

Socat Cheatsheet

Welcome to this Socat tutorial. Socat is a network utility similar to netcat. Socat is a command line based utility that establishes two bidirectional byte streams and transfers data between them. This cheatsheet provides a quick reference to Socat commands that are useful in common, everyday scenarios. Behold the power of Socat! Server/Client communication Create a simple client/server TCP connection Server socat TCP-LISTEN:8800\ ,reuseaddr\ ,pf=ip4\ ,fork - Client socat TCP:localhost:8800 - Create a client/server TCP connection over TLS/SSL.

TableExport: Export HTML tables to xlsx, xls, csv, and txt

Docs Migrating from 3.x to 4.x? v3 docs and README v4 docs and README Getting Started Install manually using <script> tags To use this library, include the FileSaver.js library, and TableExport library before the closing <body> tag of your HTML document: <script src="FileSaver.js"></script> ... <script src="tableexport.js"></script> Install with Bower $ bower install tableexport.js Install with npm $ npm install tableexport Usage JavaScript To use this library, simple call the TableExport constructor: