def test_parseRequest_pty_req(self): """ The payload of a pty-req message is:: string terminal uint32 columns uint32 rows uint32 x pixels uint32 y pixels string modes Modes are:: byte mode number uint32 mode value """ self.assertEquals( session.parseRequest_pty_req( common.NS('xterm') + struct.pack('>4L', 1, 2, 3, 4) + common.NS(struct.pack('>BL', 5, 6))), ('xterm', (2, 1, 3, 4), [(5, 6)]))
def test_parseRequest_pty_req(self): """ The payload of a pty-req message is:: string terminal uint32 columns uint32 rows uint32 x pixels uint32 y pixels string modes Modes are:: byte mode number uint32 mode value """ self.assertEqual( session.parseRequest_pty_req( common.NS(b"xterm") + struct.pack(">4L", 1, 2, 3, 4) + common.NS(struct.pack(">BL", 5, 6)) ), (b"xterm", (2, 1, 3, 4), [(5, 6)]), )
def request_pty_req(self, data): term, windowSize, modes = session.parseRequest_pty_req(data) log.msg('pty request: %r %r' % (term, windowSize)) return 1
def request_pty_req(self, data): term, windowSize, modes = session.parseRequest_pty_req(data) log.msg('pty request: %r %r' % (term, windowSize)) return 1
def request_pty_req(self, data): self.term, self.size, modes = parseRequest_pty_req(data) return True
def request_pty_req(self, data): t = session.parseRequest_pty_req(data) return True
def request_pty_req(self, data): self.term, self.size, modes = parseRequest_pty_req(data) return True