human
I wrote the below code

    class GreetingServer(protocol.Protocol, ):
        greeting = 'greetings!'
        def connectionMade(self):
            self.transport.write(self.greeting)
    class ListeningClient(protocol.Protocol, ):
        data = ''
        lostReason = None
        def dataReceived(self, data):
            self.data += data
        def connectionLost(self, reason):
            self.lostReason = reason
    clientFactory = TLSMemoryBIOFactory(clientOpts, isClient=True, wrappedFactory=protocol.Factory.forProtocol(GreetingServer))
    serverFactory = TLSMemoryBIOFactory(serverOpts, isClient=False, wrappedFactory=protocol.Factory.forProtocol(ListeningClient))
    (sProto, cProto, pump) = connectedServerAndClient((lambda : serverFactory.buildProtocol(None)), (lambda : clientFactory.buildProtocol(None)))
    return (sProto, cProto, pump)

What's a good function header?
assistant
#Here's a good function header.

def _loopbackTLSConnection(serverOpts, clientOpts):