def get_manhole_factory(namespace, **passwords):
realm = manhole_ssh.TerminalRealm()<EOL>realm.chainedProtocolFactory.protocolFactory = (<EOL>lambda _: EnhancedColoredManhole(namespace)<EOL>)<EOL>p = portal.Portal(realm)<EOL>p.registerChecker(<EOL>checkers.InMemoryUsernamePasswordDatabaseDontUse(**passwords)<EOL>)<EOL>return manhole_ssh.ConchFactory(p)<EOL>
Get a Manhole Factory