 | SessionLogin Method |
Logins the specified management server, creating a new session.
Namespace:
Koopman.CheckPoint
Assembly:
CheckPoint.NET (in CheckPoint.NET.dll) Version: 0.5.1
Syntaxpublic static Task<Session> Login(
string managementServer,
string userName,
string password,
Nullable<bool> readOnly = null,
string sessionName = null,
string comments = null,
string description = null,
string domain = null,
Nullable<bool> continueLastSession = null,
Nullable<bool> enterLastPublishedSession = null,
CertificateValidation certificateValidation = CertificateValidation.Auto,
DetailLevelActions detailLevelAction = DetailLevelActions.ThrowException,
bool indentJson = false,
int port = 443,
Nullable<int> timeout = null,
int maxConnections = 5,
TextWriter debugWriter = null,
string certificateHash = null,
CancellationToken cancellationToken = null,
Nullable<TimeSpan> httpTimeout = null,
float version = 0f
)
Request Example
View SourceParameters
- managementServer
- Type: SystemString
The management server. - userName
- Type: SystemString
Administrator user name. - password
- Type: SystemString
The administrator password. - readOnly (Optional)
- Type: SystemNullableBoolean
Weather session should be read only. - sessionName (Optional)
- Type: SystemString
Name of the session. - comments (Optional)
- Type: SystemString
Session comments. - description (Optional)
- Type: SystemString
Session description. - domain (Optional)
- Type: SystemString
Domain to connect to. - continueLastSession (Optional)
- Type: SystemNullableBoolean
Weather to continue last session. - enterLastPublishedSession (Optional)
- Type: SystemNullableBoolean
Weather to enter last published session. - certificateValidation (Optional)
- Type: Koopman.CheckPointCertificateValidation
Level of server certificate validation that should be performed.
- detailLevelAction (Optional)
- Type: Koopman.CheckPointDetailLevelActions
Action to take when performing actions on objects and the current detail level is too low.
- indentJson (Optional)
- Type: SystemBoolean
if set to true json data sent to server will be indented. Helpful with debugging.
- port (Optional)
- Type: SystemInt32
The management server API port. - timeout (Optional)
- Type: SystemNullableInt32
The session timeout. - maxConnections (Optional)
- Type: SystemInt32
The maximum connections to establish to management server. - debugWriter (Optional)
- Type: System.IOTextWriter
The debug writer. WARNING: Setting debug writer here will output you login credentials to
the debug writer in the clear. Set DebugWriter after Login to
prevent this.
- certificateHash (Optional)
- Type: SystemString
Used to check the the server SSL certificate matches this hash. Valid only if
CertificateValidation contains the flag Auto or CertificatePinning - cancellationToken (Optional)
- Type: System.ThreadingCancellationToken
The cancellation token. - httpTimeout (Optional)
- Type: SystemNullableTimeSpan
The HTTP timeout. Default: 100 seconds - version (Optional)
- Type: SystemSingle
The API version to use. Set to 0 to use management's default version.
API Versions
Return Value
Type:
TaskSession
A task that represents the asynchronous operation. The task result contains the New
Logged in Session object
See Also