'When a StartTLS command is sent, prepare to start TLS, but don\'t actually
do it; wait for the acknowledgement, then initiate the TLS handshake.'

def _doCommand(self, proto):

    d = Command._doCommand(self, proto)
    proto._prepareTLS(self.certificate, self.authorities)
    def actuallystart(response):
        proto._startTLS(self.certificate, self.authorities)
        return response
    d.addCallback(actuallystart)
    return d
