#!/bin/sh
# simple-auth verifies that RADIUS_USERNAME and RADIUS_PASSWORD equal the
# first and second arguments, respectively.
if [ -z "$1" ]; then
  echo -n Username not defined on server
  exit 1
fi
if [ "$RADIUS_USERNAME" = "$1" -a "$RADIUS_PASSWORD" = "$2" ]; then
  echo -n Welcome!
  exit 0
fi
echo -n Invalid username and/or password
exit 1
