class documentation

class ExampleProxy(ProxyBase): (source)

View In Hierarchy

A simple example of using `ProxyBase` to log responses.

Method handleProxiedResponse Log the representation of the responses received.

Inherited from ProxyBase:

Method __init__ Undocumented
Method connectionLost Called when TCP connection has been lost
Method connectionMade Establish a connection with an LDAP client.
Method handle_LDAPExtendedRequest Handler for extended LDAP requests (e.g. startTLS).
Method handle_LDAPUnbindRequest The client has requested to gracefully end the connection. Disconnect from the proxied server.
Method handleBeforeForwardRequest Override to modify request and/or controls forwarded on to the proxied server. Must return a tuple of request, controls or a deferred that fires the same. Return `None` or a deferred that fires `None` to bypass forwarding the request to the proxied server...
Method handleStartTLSRequest If the protocol factory has an `options` attribute it is assumed to be a `twisted.internet.ssl.CertificateOptions` that can be used to initiate TLS on the transport.
Method handleUnknown Forwards requests to the proxied server. This handler is overridden from `ldaptor.protocol.ldap.server.BaseServer`. And request for which no corresponding `handle_xxx()` method is implemented is dispatched to this handler.
Class Variable clientConnector Undocumented
Class Variable use_tls Undocumented
Instance Variable client Undocumented
Instance Variable queuedRequests Undocumented
Instance Variable startTLS_initiated Undocumented
Instance Variable unbound Undocumented
Method _connectedToProxiedServer The connection to the proxied server is set up.
Method _establishedTLS TLS has been started. Process any backlog of requests.
Method _failedToConnectToProxiedServer The connection to the proxied server failed.
Method _forwardRequestToProxiedServer Forward the original requests to the proxied server.
Method _gotResponseFromProxiedServer Returns True if this is the last response to the request.
Method _processBacklog Process the backlog of requests.

Inherited from BaseLDAPServer (via ProxyBase):

Method checkControls Undocumented
Method dataReceived Undocumented
Method failDefault Undocumented
Method handle Undocumented
Method queue Undocumented
Method unsolicitedNotification Undocumented
Class Variable berdecoder Undocumented
Class Variable debug Undocumented
Instance Variable buffer Undocumented
Instance Variable connected Undocumented
Method _callErrorHandler Undocumented
Method _cbHandle Undocumented
Method _cbLDAPError Undocumented
Method _cbOtherError Undocumented
def handleProxiedResponse(self, response, request, controls): (source)

Log the representation of the responses received.