We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0487a4a commit 9d5b035Copy full SHA for 9d5b035
2 files changed
Exscript/protocols/drivers/junos.py
@@ -48,7 +48,7 @@
48
# pheller@fw1>
49
#
50
51
-_user_re = [re.compile(r'[\r\n]login: $')]
+_user_re = [re.compile(r'[\r\n](?:[\-\w+]+ )?login: $')]
52
_password_re = [re.compile(r'[\r\n](Local )?[Pp]assword: ?$')]
53
_mb = r'(?:\{master(?::\d+)?\}|\{backup(?::\d+)?\})'
54
_ps = r'(?:\{primary:node\d+\}|\{secondary:node\d+\})'
Exscript/protocols/telnetlib.py
@@ -483,6 +483,10 @@ def process_rawq(self):
483
# to perform, the indicated option.
484
elif command == DO:
485
opt = self.rawq_getchar()
486
+ # int 0 produces an empty byte string which then has no ord
487
+ # we can skip its processing
488
+ if opt == b"":
489
+ continue
490
self.msg('IAC DO %s', ord(opt))
491
if opt == TTYPE:
492
self.sock.send(IAC+WILL+opt)
0 commit comments