MCPcopy Create free account
hub / github.com/USArmyResearchLab/Dshell / messagefactory

Function messagefactory

dshell/plugins/ssh/ssh-pubkey.py:101–114  ·  view source on GitHub ↗
(data)

Source from the content-addressed store, hash-verified

99
100
101def messagefactory(data):
102
103 datalen = len(data)
104 offset = 0
105 msglist = []
106 while offset < datalen:
107 try:
108 msg = sshmessage(data[offset:])
109 except ValueError:
110 return msglist
111 msglist.append(msg)
112 offset += msg.packet_len + 4
113
114 return msglist
115
116
117class sshmessage:

Callers 1

connection_handlerMethod · 0.85

Calls 1

sshmessageClass · 0.85

Tested by

no test coverage detected