Login Method
Authorizes the user. On success, the user is logged in and can connect to projects.
Starting in ALM 14.00, the authorization is not handled by ALM but by an external Identity Manager (IdM) and Identity Provider (IdP).
The Login method is supported for backward compatibility and requires referencing IdmClientSdk.dll and IdmSdkWrapper.dll.
To take advantage of the new authentication mechanism, develop your own authentication flow to acquire a LWSSO token from the IdP and IdM that manage authentication (see Acquire an authentication token to use for ALM APIs). Use the token you acquire to call InitConnectionWithCookiesEx Method instead of using this Login method.
Note: If ALM runs in non-SSO mode:
- In ALM 15.00, you can use this API to login with your username and password.
- In ALM 15.0.1 or later, you can use this API to login with either your username and password or your API key and API key secret.
If ALM runs in SSO mode:
- In ALM 15.00, you cannot use this API to login. Use the API InitConnectionWithApiKey Method to login with your API key and API key secret.
- In ALM 15.0.1 or later, you can use this API to login with your API key and API key secret.
See the following table for the username and password parameters.
ALM version | SSO mode | Non-SSO mode |
---|---|---|
14.x | Supports login with the one of the following pairs of username and password:
| NA |
12.5x, 12.60 | NA | Supports login with the one of the following pairs of username and password:
|
15.00 | Supports login with the one of the following pairs of username and password:
Note: If you want to login with API key and API key secret, you can use the InitConnectionWithApiKey Method API . | Supports login with the one of the following pairs of username and password:
|
15.0.1 | Supports login with the one of the following pairs of username and password:
| Supports login with the one of the following pairs of username and password:
|
Before authenticating a user with Login, connect to the server with InitConnectionEx.
After a successful call to Login, the user is authenticated on the server, but not connected to any project. Therefore, the LoggedIn Property and the Connected Property are True and the ProjectConnected Property is False.
For a table of properties affected by the state of the connection, see the Remarks for the TDConnection object.