solidDB Help : Configuring and administering : Security : Authentication : Token-based authentication : Using token-based authentication
  
Using token-based authentication
To use token-based authentication, the application that connects to the server must provide the authentication token. Authentication tokens can be configured by using configuration parameters in solid.ini:
Client.AuthTokenString: The authentication token.
Client.AuthTokenFile: The path to the file that contains the token.
See Client section.
JDBC
With JDBC, the authentication token can be provided to the server by using the non-standard JDBC properties solid_authtoken_file and solid_authtoken_string, see JDBC: Non-standard connection properties.
One of these properties must be set before connecting to the server.
Properties prop = new Properties();
prop.setProperty("solid_authtoken_file", filename);
or
Properties prop = new Properties();
prop.setProperty("solid_authtoken_string", authtoken);
The authentication token or file containing the token can be also provided to JDBC by using a URL.
The following URL is an example that contains an authentication token string:
jdbc:solid://localhost:1964/localuser/bad?solid_authtoken_string=hDnx0VQZkXabwOekg797BC6kCDZh1HImzDDHwi2F3nPijKC-HH-07VxZHc9UdD2tP_h5ms5KIf3-zBHrvH6lqKpzrZgRAvT1
The following URL is an example that contains the file name for the authentication token:
jdbc:solid://localhost:1964/localuser/bad?solid_authtoken_file=./authtoken
ODBC
With ODBC, the authentication can be provided to the server by using the non-standard ODBC attributes SQL_ATTR_AUTHTOKEN_FILE or SQL_ATTR_AUTHTOKEN_STRING., see solidDB extensions for ODBC API.
Either of these connection attributes must be set before connecting to the server.
For example:
SQLSetConnectAttr(hdbc, SQL_ATTR_AUTHTOKEN_STRING, authtoken, SQL_NTS);
or
SQLSetConnectAttr(hdbc, SQL_ATTR_AUTHTOKEN_FILE, filename, SQL_NTS);
Go up to
Token-based authentication