Class BasePipe
Abstract base class for the ClientPipe and ServerPipe classes. A Pipe represents a connection to either the client or the server, optionally encrypted using SSL/TLS.
Inheritance
Inherited Members
Namespace: Fiddler
Assembly: FiddlerCore.dll
Syntax
public abstract class BasePipe
Constructors
BasePipe(Socket, String)
Create a new pipe, an enhanced wrapper around a socket
Declaration
public BasePipe(Socket oSocket, string sName)
Parameters
System.Net.Sockets.Socket
oSocket
Socket which this pipe wraps |
System.String
sName
Identification string used for debugging purposes |
Fields
_baseSocket
The base socket wrapped in this pipe
Declaration
protected Socket _baseSocket
Field Value
System.Net.Sockets.Socket
|
_httpsStream
The HTTPS stream wrapped around the base socket
Declaration
protected SslStream _httpsStream
Field Value
System.Net.Security.SslStream
|
_sPipeName
The display name of this Pipe
Declaration
protected string _sPipeName
Field Value
System.String
|
iUseCount
The number of times that this Pipe has been used
Declaration
protected uint iUseCount
Field Value
System.UInt32
|
Properties
Address
Returns the remote address to which this Pipe is connected, or 0.0.0.0 on error.
Declaration
public IPAddress Address { get; }
Property Value
System.Net.IPAddress
|
bIsSecured
Returns a bool indicating if the socket in this Pipe is CURRENTLY connected and wrapped in a SecureStream
Declaration
public bool bIsSecured { get; }
Property Value
System.Boolean
|
Connected
Return the Connected status of the base socket. WARNING: This doesn't work as you might expect; you can see Connected == false when a READ timed out but a WRITE will succeed.
Declaration
public bool Connected { get; }
Property Value
System.Boolean
|
LocalPort
Return the Local Port to which the base socket is attached. Note: May return a misleading port if the ISA Firewall Client is in use.
Declaration
public int LocalPort { get; }
Property Value
System.Int32
|
Port
Return the Remote Port to which this socket is attached.
Declaration
public int Port { get; }
Property Value
System.Int32
|
SecureProtocol
Returns the SSL/TLS protocol securing this connection
Declaration
public SslProtocols SecureProtocol { get; }
Property Value
System.Security.Authentication.SslProtocols
|
TransmitDelay
Gets or sets the transmission delay on this Pipe, used for performance simulation purposes.
Declaration
public int TransmitDelay { get; set; }
Property Value
System.Int32
|
Methods
End()
Shutdown and close the socket inside this pipe. Eats exceptions.
Declaration
public void End()
EndWithRST()
Abruptly closes the socket by sending a RST packet
Declaration
public void EndWithRST()
GetRawSocket()
Return the raw socket this pipe wraps. Avoid calling this method if at all possible.
Declaration
public Socket GetRawSocket()
Returns
System.Net.Sockets.Socket
The Socket object this Pipe wraps. |
HasDataAvailable()
Poll the underlying socket for readable data (or closure/errors)
Declaration
public virtual bool HasDataAvailable()
Returns
System.Boolean
TRUE if this Pipe requires attention |
Send(Byte[])
Sends a byte array through this pipe
Declaration
public void Send(byte[] oBytes)
Parameters
System.Byte[]
oBytes
The bytes |