forked from MirrorHub/synapse
Fix manhole on py3 (pt 2) (#4067)
This commit is contained in:
parent
b69216f768
commit
e404ba9aac
1
changelog.d/4067.bugfix
Normal file
1
changelog.d/4067.bugfix
Normal file
|
@ -0,0 +1 @@
|
||||||
|
Manhole now works again on Python 3, instead of failing with a "couldn't match all kex parts" when connecting.
|
|
@ -70,6 +70,8 @@ def manhole(username, password, globals):
|
||||||
Returns:
|
Returns:
|
||||||
twisted.internet.protocol.Factory: A factory to pass to ``listenTCP``
|
twisted.internet.protocol.Factory: A factory to pass to ``listenTCP``
|
||||||
"""
|
"""
|
||||||
|
if not isinstance(password, bytes):
|
||||||
|
password = password.encode('ascii')
|
||||||
|
|
||||||
checker = checkers.InMemoryUsernamePasswordDatabaseDontUse(
|
checker = checkers.InMemoryUsernamePasswordDatabaseDontUse(
|
||||||
**{username: password}
|
**{username: password}
|
||||||
|
|
Loading…
Reference in a new issue