index
netauth-server
network authentication server side
this program replaces minux's default user system with a network based one.
it listens for a netauth-client and handles their requests.
it requires a running ccnds-server to be found by clients
this is the first version of netauth, for now configuration can only be done on the server itself.
it uses a centralized system to keep track of user accounts and passwords
it replaces minux.login meaning that other programs using login will also switch
the server contains functions for developers and a binary to configure the server
installation instructions: - install guide
/bin/netauth-server.sh - alias:nas
this binary is used to change the server's configuration or start/stop it.
example: nas set path /var/test
options:
start/stop - starts or stops the server.
get - gets information from config, options:path
set - sets information to config, options: path DIR
useradd - adds a user, options: user,pass
userdel - removes a user, options: user
passwd - changes a user's password, options: user,pass
isop - checks if a user is admin, options: user
op - promotes a user to admin, options: user
deop - demotes a user to admin, options: user
lua functions - lua functions for devs to call
Error codes: 100=accept,102=already exists,103=denied,104=not found
checkpass - checks if user and pass match
example: nas.checkpass("user","pass")
input1: username as string
input2: password as string
output: either error code as number or data as table, d1=allowed|true/false(bool), d2=isadmin|true/false(bool)
useradd - adds a user
example: nas.useradd("user","pass")
input1: username as string
input2: password as string
output: 102 if already exist, 100 if success
userdel - deletes a user
example: nas.userdel("user")
input1: username as string
output: 104 if doesn't exist, 100 if success
passwd - changes a user's password
example: nas.passwd("user","pass")
input1: username as string
input2: password as string
output: 104 if doesn't exist, 100 if success
ismod - checks for admin
example: nas.ismod("user")
input1: username as string
output: true or false, bool
op - promotes a user to admin
example: nas.op("user")
input1: username as string
output: 104 if doesn't exist, 100 if success
deop - demotes a user from admin
example: nas.deop("user")
input1: username as string
output: 104 if doesn't exist, 100 if success