(self, packet)
| 71 | # |
| 72 | |
| 73 | def _processNMBSessionPacket(self, packet): |
| 74 | if packet.type == SESSION_MESSAGE: |
| 75 | self.onNMBSessionMessage(packet.flags, packet.data) |
| 76 | elif packet.type == POSITIVE_SESSION_RESPONSE: |
| 77 | self.onNMBSessionOK() |
| 78 | elif packet.type == NEGATIVE_SESSION_RESPONSE: |
| 79 | self.onNMBSessionFailed() |
| 80 | elif packet.type == SESSION_KEEPALIVE: |
| 81 | # Discard keepalive packets - [RFC1002]: 5.2.2.1 |
| 82 | pass |
| 83 | else: |
| 84 | self.log.warning('Unrecognized NMB session type: 0x%02x', packet.type) |
| 85 | |
| 86 | def _sendNMBPacket_NetBIOS(self, packet_type, data): |
| 87 | length = len(data) |
no test coverage detected