X-Git-Url: http://git.pjr.cc/?p=ga4php.git;a=blobdiff_plain;f=authserver%2Fusercmd.php;h=3adf83512c7a343f9c1fa7dcfe6222eee3ac9537;hp=1d4db80da87403f0c8f6c5e97097da3708f6f9d7;hb=c3c37cd9f486175adf0351de80c19efd02892ca6;hpb=684d7cc6c2ce6ba3f1ca5c48dda5c4efa9448455 diff --git a/authserver/usercmd.php b/authserver/usercmd.php index 1d4db80..3adf835 100644 --- a/authserver/usercmd.php +++ b/authserver/usercmd.php @@ -39,10 +39,19 @@ if(!isset($argv[1])) { echo "\tradauth: radauth - for radius, only returns a code\n"; echo "\tsynctoken: synctoken - resync's a hotp token based on two token codes\n"; echo "\ttokentype: tokentype - gets the token type for a user\n"; + echo "\taddradclient: addradclient \n"; return 0; } switch($argv[1]) { + case "addradclient": + $msg = $myAC->addRadiusClient($argv[2], $argv[3], $argv[4], ""); + if($msg) { + echo "Added successfully\n"; + } else { + echo "Not added\n"; + } + break; case "tokentype": $msg = $myAC->getUserTokenType($argv[2]); echo "token type: $msg\n"; @@ -133,5 +142,7 @@ switch($argv[1]) { echo "\tHas Token?: ".$hastoken."\n\n"; } break; + default: + echo "See the usage...\n"; } ?> \ No newline at end of file