Show / Hide Table of Contents

Class CredentialsManager

Manages IUserCredentialPlugin instances.

Inheritance
Object
CredentialsManager
Namespace: SuperOffice.Security
Assembly: SoDataBase.dll
Syntax
public class CredentialsManager : Object

Methods

GetAllInstalledPluginNames()

Return a list of all credential plugins that are available (including those that . i.e. all plugins that are installed are returned, including those without a corresponding license.

Declaration
public string[] GetAllInstalledPluginNames()
Returns
Type Description
String[]

List of all ICredntialPlugin names e.g: "ActiveDirectory", "CRM5/PASSWORD"

GetAllPlugins()

Return a list of all credential plugins that are licensed and available. i.e. some plugins that are installed may not be present, because the corresponding license is not present.

Declaration
public Dictionary<string, IUserCredentialPlugin> GetAllPlugins()
Returns
Type Description
Dictionary<String, IUserCredentialPlugin>

Dictionary of plugin name to plugin instance. e.g: "ActiveDirectory"=ActiveDirectoryCredentialPlugin

GetCurrent()

Get the current CredentialsManager

Declaration
public static CredentialsManager GetCurrent()
Returns
Type Description
CredentialsManager

GetDefaultCredentialPlugin(UserType, Int32)

Manages IUserCredentialPlugin instances.

Declaration
public IUserCredentialPlugin GetDefaultCredentialPlugin(UserType userType, int personId)
Parameters
Type Name Description
UserType userType
Int32 personId
Returns
Type Description
IUserCredentialPlugin

GetPlugin(String)

Get the plugin associated with a given credential type.

Declaration
public IUserCredentialPlugin GetPlugin(string credentialType)
Parameters
Type Name Description
String credentialType

Name of credential plugin: "CRM5/PASSWORD" or "ActiveDirectory".

Returns
Type Description
IUserCredentialPlugin

Plugin interface, or null if plugin is not available/licensed.

GetUntrustedCredentials(String)

Get a set of credentials for authenticated associate

Declaration
public static UntrustedCredentials[] GetUntrustedCredentials(string type)
Parameters
Type Name Description
String type

Type of credentials to retrieve

Returns
Type Description
UntrustedCredentials[]

Arrow of populated credential objects.

GetUntrustedCredentials(String, Int32)

Get a set of credentials for a specified associate

Declaration
public static UntrustedCredentials[] GetUntrustedCredentials(string type, int associateId)
Parameters
Type Name Description
String type

Type of credentials to retrieve

Int32 associateId

Id of associate to retrieve credentials for

Returns
Type Description
UntrustedCredentials[]

Arrow of populated credential objects. SecretValue is left blank for security purposes if associate is not authenticated user or a system user.

Refresh()

Refresh the list of credential plugins. Useful if you have just loaded some new licenses.

Declaration
public void Refresh()

RemoveUntrustedCredentials(String, Int32, String)

Remove a credentials entry for an associate

Declaration
public static void RemoveUntrustedCredentials(string type, int associateId, string publicValue)
Parameters
Type Name Description
String type

Type of credential(Ex: "imap", "smtp")

Int32 associateId

Id of associate to remove for

String publicValue

PublicValue of credential to remove

RemoveUntrustedCredentials(String, String)

Remove a credentials entry for authenticated user

Declaration
public static void RemoveUntrustedCredentials(string type, string publicValue)
Parameters
Type Name Description
String type

Type of credential(Ex: "imap", "smtp")

String publicValue

PublicValue of credential to remove

SaveUntrustedCredentials(String, UntrustedCredentials)

Save credentials for authenticated associate

Declaration
public static void SaveUntrustedCredentials(string type, UntrustedCredentials credentials)
Parameters
Type Name Description
String type

Type of credential(Ex: "imap", "smtp")

UntrustedCredentials credentials

Credentials to save

SaveUntrustedCredentials(String, Int32, UntrustedCredentials)

Save credentials for a specified associate

Declaration
public static void SaveUntrustedCredentials(string type, int associateId, UntrustedCredentials credentials)
Parameters
Type Name Description
String type

Type of credential(Ex: "imap", "smtp")

Int32 associateId

Id of associate to save for

UntrustedCredentials credentials

Credentials to save

Extension Methods

EnumUtil.MapEnums<From, To>(From)
Converters.MapEnums<From, To>(From)
© SuperOffice. All rights reserved.
SuperOffice |  Community |  Release Notes |  Privacy |  Site feedback |  Search Docs |  About Docs |  Contribute |  Back to top