Ticket #3443 defect closed fixed
twisted.conch.ssh.factory.SSHFactory.buildProtocol doesn't let you customize the protocol it creates
|Reported by:||mwh||Owned by:|
(diff, github, buildbot, log)
We want to set tcp keepalives on all connections to our ssh server, which would seem to be most logically done in connectionMade of the protocol object created on a connection -- but there's no way to influence the class of the protocol object created here, other than copy-paste-hacking buildProtocol into your factory subclass.
If SSHFactory.buildProtocol delegated to Factory.buildProtocol, you could do it by defining 'protocol' in your factory subclass, as in most of the rest of Twisted.
Diff attached, no tests though.