Property AuthenticationMethod
- Namespace
- YndigoBlue.Velocity.Data.DB2
- Assembly
- YndigoBlue.Velocity.dll
AuthenticationMethod
Gets or sets the DB2 authentication mechanism used when
UseIntegratedSecurity is true.
public DB2AuthenticationMethod AuthenticationMethod { get; set; }
Property Value
Examples
// Connect using LDAP-backed GSS plugin authentication
var conn = new DB2DatasourceConnection
{
Hostname = "db2server.example.com",
Port = 50000,
Database = "SAMPLE",
UseIntegratedSecurity = true,
AuthenticationMethod = DB2AuthenticationMethod.GssPlugin
};
Remarks
This property maps to the Authentication= keyword in the IBM DB2 connection string.
It is only applied when UseIntegratedSecurity is set to
true; it has no effect when username/password authentication is used.
The default value is Kerberos, which covers most Active Directory / Kerberos-integrated environments. For LDAP or other GSS-backed authentication, use GssPlugin or GssServerEncrypt.
Note: Velocity only sets the connection string keyword. The underlying authentication infrastructure — Kerberos ticket cache, DB2 GSS plugin configuration, LDAP bind settings — must be configured externally on both the client machine and the DB2 server.