MCPcopy Create free account
hub / github.com/PierreGode/Ragnar / sendOpen

Method sendOpen

pager_lib/smb/base.py:2458–2467  ·  view source on GitHub ↗
(tid)

Source from the content-addressed store, hash-verified

2456 messages_history = [ ]
2457
2458 def sendOpen(tid):
2459 m = SMBMessage(ComOpenAndxRequest(filename = path,
2460 access_mode = 0x0040, # Sharing mode: Deny nothing to others
2461 open_mode = 0x0001, # Failed if file does not exist
2462 search_attributes = SMB_FILE_ATTRIBUTE_HIDDEN | SMB_FILE_ATTRIBUTE_SYSTEM,
2463 timeout = timeout * 1000))
2464 m.tid = tid
2465 self._sendSMBMessage(m)
2466 self.pending_requests[m.mid] = _PendingRequest(m.mid, int(time.time()) + timeout, openCB, errback)
2467 self._pushToArray(messages_history, m)
2468
2469 def openCB(open_message, **kwargs):
2470 self._pushToArray(messages_history, open_message)

Callers

nothing calls this directly

Calls 4

_pushToArrayMethod · 0.95
SMBMessageClass · 0.85
ComOpenAndxRequestClass · 0.85
_PendingRequestClass · 0.85

Tested by

no test coverage detected