#!/bin/sh # This script should be invoked from cert # It expects "$PROGRAMATICA", "$SERVERDIR" and "$certsDir" to be set. type=Cut [ -n "$PROGRAMATICA" ] || { echo >&2 'Bug: $PROGRAMATICA is not set'; exit 1;} . "$PROGRAMATICA/functions.sh" [ -n "$certsDir" ] || abort 'Bug: $certsDir is not set' [ -n "$SERVERDIR" ] || abort 'Bug: $SERVERDIR is not set' . $SERVERDIR/functions.sh # cut() u="Usage: cert new $type or: cert new $type conc" usage() { abort "$u"; } createcert() { mkdir -p "$1" cat >"$1/cert.attr" <