NetLinx Programming
103
NX-Series Controllers - WebConsole & Programming Guide
NetLinx.axi - Library Calls (Cont.)
VALIDATE_NETLINX_ACCOUNT This function validates the specified user name and password against the NetLinx Master Controller's
internal user account database. For the account to be valid the user name must exist with the
matching password and the specified user account must have been set up with ICSP Authorization.
Syntax:
sinteger VALIDATE_NETLINX_ACCOUNT(CHAR username[], CHAR
password[],LAST_LOGIN_INFO info)
Parameters:
username - A character array containing the user name to validate.
password - A character array containing the password to validate.
info - A return structure of type LAST_LOGIN_INFO.
Returns:
The following values are returned from the call:
0 - Valid user account.
-1 - Username invalid
-2 - Password invalid
-3 - Invalid user account
-4 - No authorization (Username/password are not authorized)
-5 - Invalid parameter
-6 - User account matching name is locked out
-7 - User account matching name has expired
VALIDATE_NETLINX_ACCOUNT_
WITH_PERMISSION
This function validates the specified user name and password against the NetLinx Master Controller's
internal user account database. For the account to be valid the user name must exist with the
matching password and the specified user account must have been set up with ICSP Authorization.
This command includes parameters for authorization and permission types.
Syntax:
sinteger VALIDATE_NETLINX_ACCOUNT_WITH_PERMISSION(CHAR username[], CHAR
password[],CHAR type[], CHAR permission[], LAST_LOGIN_INFO info)
Parameters:
username - A character array containing the user name to validate.
password - A character array containing the password to validate.
type - The authorization type.
permission - The permission type. Valid permissions include: Configuration, Console, Diags,
EncryptICSP, FTP, HTTP, ICSP, Terminal, AuditLog, User1, User2, User3, and User4
info - A return structure of type LAST_LOGIN_INFO
Returns:
The following values are returned from the call:
0 - Valid user account.
-1 - Username parameter is not a valid string
-2 - Password parameter is not a valid string
-3 - Invalid user account
-4 - No authorization (Username/password are not authorized and/or permission is not
authorized)
-5 - Third argument is not a LAST_LOGIN_INFO structure
-6 - User account matching name is locked out
-7 - User account matching name has expired