C# Class SharpCifs.Smb.SmbSession

Show file Open project: brandonprry/Potato Class Usage Examples

Public Methods

Method Description
GetChallenge ( UniAddress dc ) : byte[]
GetChallenge ( UniAddress dc, int port ) : byte[]
GetChallengeForDomain ( ) : NtlmChallenge
Logon ( UniAddress dc, NtlmPasswordAuthentication auth ) : void

Authenticate arbitrary credentials represented by the NtlmPasswordAuthentication object against the domain controller specified by the UniAddress parameter.

Authenticate arbitrary credentials represented by the NtlmPasswordAuthentication object against the domain controller specified by the UniAddress parameter. If the credentials are not accepted, an SmbAuthException will be thrown. If an error occurs an SmbException will be thrown. If the credentials are valid, the method will return without throwing an exception. See the last FAQ question.

See also the jcifs.smb.client.logonShare property.

Logon ( UniAddress dc, int port, NtlmPasswordAuthentication auth ) : void
ToString ( ) : string

Private Methods

Method Description
GetSmbTree ( string share, string service ) : SmbTree
Interrogate ( NbtAddress addr ) : NtlmChallenge
Logoff ( bool inError ) : void
Matches ( NtlmPasswordAuthentication auth ) : bool
Send ( ServerMessageBlock request, ServerMessageBlock response ) : void
SessionSetup ( ServerMessageBlock andx, ServerMessageBlock andxResponse ) : void
SmbSession ( UniAddress address, int port, IPAddress localAddr, int localPort, NtlmPasswordAuthentication auth ) : System
Transport ( ) : SmbTransport

Method Details

GetChallenge() public static method

public static GetChallenge ( UniAddress dc ) : byte[]
dc UniAddress
return byte[]

GetChallenge() public static method

public static GetChallenge ( UniAddress dc, int port ) : byte[]
dc UniAddress
port int
return byte[]

GetChallengeForDomain() public static method

public static GetChallengeForDomain ( ) : NtlmChallenge
return NtlmChallenge

Logon() public static method

Authenticate arbitrary credentials represented by the NtlmPasswordAuthentication object against the domain controller specified by the UniAddress parameter.
Authenticate arbitrary credentials represented by the NtlmPasswordAuthentication object against the domain controller specified by the UniAddress parameter. If the credentials are not accepted, an SmbAuthException will be thrown. If an error occurs an SmbException will be thrown. If the credentials are valid, the method will return without throwing an exception. See the last FAQ question.

See also the jcifs.smb.client.logonShare property.

public static Logon ( UniAddress dc, NtlmPasswordAuthentication auth ) : void
dc UniAddress
auth NtlmPasswordAuthentication
return void

Logon() public static method

public static Logon ( UniAddress dc, int port, NtlmPasswordAuthentication auth ) : void
dc UniAddress
port int
auth NtlmPasswordAuthentication
return void

ToString() public method

public ToString ( ) : string
return string