SecureBlackbox 2020 Qt Edition

Questions / Feedback?

WriteFile Event

This event is fired when a file write request is received.

Syntax

class SFTPServerWriteFileEventParams {
public:
  qint64 ConnectionID();
  const QString &Handle();
  int Offset();
  int OperationStatus();
  void SetOperationStatus(int iOperationStatus);
  int EventRetVal();
  void SetEventRetVal(int iRetVal);
};
// To handle, connect one or more slots to this signal. void WriteFile(SFTPServerWriteFileEventParams *e);
// Or, subclass SFTPServer and override this emitter function. virtual int FireWriteFile(SFTPServerWriteFileEventParams *e) {...}

Remarks

This event is fired when a request to write a data block to a file is received from the client. The ConnectionID parameter specifies the session the request originates from. The Handle parameter references the opened file where the block should be written to. Offset references the position in the file where the block of data should be written.

Use GetClientBuffer method to obtain the piece of data that should be written to the file.

Set OperationStatus to one of the below values according to the outcome of the request processing:

ostOk1
ostNoSuchFile2
ostAccessDenied3
ostWriteProtect4
ostUnsupported5
ostInvalidParameter6
ostEOF7

Copyright (c) 2022 /n software inc. - All rights reserved.
SecureBlackbox 2020 Qt Edition - Version 20.0 [Build 8154]