(tid)
| 616 | results = [ ] |
| 617 | |
| 618 | def sendCreate(tid): |
| 619 | create_context_data = binascii.unhexlify(b""" |
| 620 | 28 00 00 00 10 00 04 00 00 00 18 00 10 00 00 00 |
| 621 | 44 48 6e 51 00 00 00 00 00 00 00 00 00 00 00 00 |
| 622 | 00 00 00 00 00 00 00 00 18 00 00 00 10 00 04 00 |
| 623 | 00 00 18 00 00 00 00 00 4d 78 41 63 00 00 00 00 |
| 624 | 00 00 00 00 10 00 04 00 00 00 18 00 00 00 00 00 |
| 625 | 51 46 69 64 00 00 00 00 |
| 626 | """.replace(b' ', b'').replace(b'\n', b'')) |
| 627 | m = SMB2Message(SMB2CreateRequest(path, |
| 628 | file_attributes = 0, |
| 629 | access_mask = FILE_READ_DATA | FILE_READ_ATTRIBUTES | SYNCHRONIZE, |
| 630 | share_access = FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE, |
| 631 | oplock = SMB2_OPLOCK_LEVEL_NONE, |
| 632 | impersonation = SEC_IMPERSONATE, |
| 633 | create_options = FILE_DIRECTORY_FILE, |
| 634 | create_disp = FILE_OPEN, |
| 635 | create_context_data = create_context_data)) |
| 636 | m.tid = tid |
| 637 | self._sendSMBMessage(m) |
| 638 | self.pending_requests[m.mid] = _PendingRequest(m.mid, expiry_time, createCB, errback, tid = tid) |
| 639 | self._pushToArray(messages_history, m) |
| 640 | |
| 641 | def createCB(create_message, **kwargs): |
| 642 | self._pushToArray(messages_history, create_message) |
nothing calls this directly
no test coverage detected