Detailed Description
Holds the server credentials for the user logging in.
Availability
Available in version 7.1 of Decoder SDK. Requires a server version greater than 6.0
Two factor authentication (MFA) requires a supporting server
#include <Credentials.h>
Public Member Functions | |
DB_EDGEVIS_SDK | Credentials (const std::wstring &username, const std::wstring &password, const std::wstring &new_password=L"") |
Constructor for the Credentials object. More... | |
DB_EDGEVIS_SDK void | SetUsername (const std::wstring &username) |
Sets the username for logging in to the server. More... | |
DB_EDGEVIS_SDK void | SetSSOOpenIdAuthCode (const std::wstring &ssoOpenIdAuthCode) |
Sets the SSO OpenId auth code for logging in to the server. More... | |
DB_EDGEVIS_SDK void | SetPassword (const std::wstring &password) |
Sets the password for logging in to the server. More... | |
DB_EDGEVIS_SDK void | SetNewPassword (const std::wstring &new_password) |
Sets the new password to set when logging in to the server when a password reset is required. More... | |
DB_EDGEVIS_SDK bool | SetMFAPasscode (const std::wstring &otp) |
Sets the one time two factor authentication password for this login. More... | |
DB_EDGEVIS_SDK void | SetMFAEmergencyPasscode (const std::wstring &emergency_passcode) |
Sets the two factor authentication emergency passcode for this login. More... | |
DB_EDGEVIS_SDK void | SetDevicePassword (const std::wstring &password) |
Sets the device password for this login. More... | |
Constructor & Destructor Documentation
DB_EDGEVIS_SDK EdgeVisDecoderSDK::Credentials::Credentials | ( | const std::wstring & | username, |
const std::wstring & | password, | ||
const std::wstring & | new_password = L"" |
||
) |
Constructor for the Credentials object.
- Parameters
-
username The username to log in with. NOTE: if using an app specific password to log in to an MFA enabled server the app specific password should be appended to the username with a colon separator (eg. username:appspecificpassword) The app specific password can be generated in the server web UI if required. password The password to log in with. new_password The new password to set when logging in. This will be ignored if the user account does not require a password reset. If on attempting to connect to a server an OpResult of OR_NewPasswordRequired is returned you must set a new password. This new password must meet the requirements as set down by the PasswordResetInfo class.
Member Function Documentation
DB_EDGEVIS_SDK void EdgeVisDecoderSDK::Credentials::SetUsername | ( | const std::wstring & | username | ) |
Sets the username for logging in to the server.
- Parameters
-
username The username to log in with. NOTE: if using an app specific password to log in to an MFA enabled server the app specific password should be appended to the username with a colon separator (eg. username:appspecificpassword) The app specific password can be generated in the server web UI if required.
DB_EDGEVIS_SDK void EdgeVisDecoderSDK::Credentials::SetSSOOpenIdAuthCode | ( | const std::wstring & | ssoOpenIdAuthCode | ) |
Sets the SSO OpenId auth code for logging in to the server.
- Parameters
-
username The SSO OpenId-enabled auth code to log in with.
DB_EDGEVIS_SDK void EdgeVisDecoderSDK::Credentials::SetPassword | ( | const std::wstring & | password | ) |
Sets the password for logging in to the server.
- Parameters
-
password The password to log in with.
DB_EDGEVIS_SDK void EdgeVisDecoderSDK::Credentials::SetNewPassword | ( | const std::wstring & | new_password | ) |
Sets the new password to set when logging in to the server when a password reset is required.
- Parameters
-
new_password The new password to set when logging in. This will be ignored if the user account does not require a password reset.
DB_EDGEVIS_SDK bool EdgeVisDecoderSDK::Credentials::SetMFAPasscode | ( | const std::wstring & | otp | ) |
Sets the one time two factor authentication password for this login.
This is typically a 6 digit number provided by a mobile application. If MFA is required, set only one of:
- MFA Password
- MFA Emergency password
- Device Password
- Parameters
-
otp The one time MFA password
DB_EDGEVIS_SDK void EdgeVisDecoderSDK::Credentials::SetMFAEmergencyPasscode | ( | const std::wstring & | emergency_passcode | ) |
Sets the two factor authentication emergency passcode for this login.
The emergency passcodes are provided during 2FA enrolment. If MFA is required, set only one of:
- MFA Password
- MFA Emergency password
- Device Password
- Parameters
-
emergency_passcode The MFA emergency password
DB_EDGEVIS_SDK void EdgeVisDecoderSDK::Credentials::SetDevicePassword | ( | const std::wstring & | password | ) |
Sets the device password for this login.
A device password may be stored on a trusted device as an alternative to supplying a one-time password (OTP) for connecting to two-factor authentication enabled servers. If MFA is required, set only one of:
- MFA Password
- MFA Emergency password
- Device Password
- Parameters
-
password The device password
The documentation for this class was generated from the following file:
- SDKs/EdgeVisDecoderSDK/Credentials.h