|
libclues
Linux C++ Tracing Library
|
Inheritance diagram for clues::FcntlSystemCall:Public Member Functions | |
| FcntlSystemCall (const SystemCallNr sysnr) | |
Public Member Functions inherited from clues::SystemCall | |
| SystemCall (const SystemCallNr nr) | |
| Instantiates a new SystemCall object with given properties. | |
| SystemCall (const SystemCall &other)=delete | |
| SystemCall & | operator= (const SystemCall &other)=delete |
| void | setEntryInfo (const Tracee &proc, const SystemCallInfo &info) |
| Update the stored parameter values from the given tracee. | |
| void | setExitInfo (const Tracee &proc, const SystemCallInfo &info) |
| Update possible out and return parameter values from the given tracee. | |
| std::string_view | name () const |
| Returns the system call's human readable name. | |
| size_t | numPars () const |
| Returns the number of parameters for this system call. | |
| SystemCallNr | callNr () const |
| Returns the system call table number for this system call. | |
| const ParameterVector & | parameters () const |
| Access to the parameters associated with this system call. | |
| SystemCallItemPtr | result () const |
| Access to the return value parameter associated with this system call. | |
| std::optional< ErrnoResult > | error () const |
| Access to the errno result seen for this system call. | |
| bool | hasOutParameter () const |
| bool | hasResultValue () const |
| bool | hasErrorCode () const |
| ABI | abi () const |
| Returns the system call ABi seen during system call entry. | |
| bool | is32BitEmulationABI () const |
| const SystemCallInfo * | currentInfo () const |
| Access the current SystemCallInfo if currently processing syscall entry/exit. | |
Public Attributes | |
| item::FileDescriptor | fd |
| item::FcntlOperation | operation |
| std::optional< item::FileDescriptor > | dup_lowest |
| for DUPFD, DUPFD_CLOEXEC | |
| std::optional< item::FileDescFlagsValue > | fd_flags_arg |
| for SETFD | |
| std::optional< item::OpenFlagsValue > | status_flags_arg |
| for SETFL | |
| std::optional< item::FLockParameter > | flock_arg |
| for F_SETLK, F_SETLKW, F_GETLK | |
| std::optional< item::FileDescOwner > | owner_arg |
| for SETOWN | |
| std::optional< item::ExtFileDescOwner > | ext_owner_arg |
| for SETOWN_EX, GETOWN_EX | |
| std::optional< item::SignalNumber > | io_signal_arg |
| for SETSIG | |
| std::optional< item::LeaseType > | lease_arg |
| for SETLEASE | |
| std::optional< item::DNotifySettings > | dnotify_arg |
| for NOTIFY | |
| std::optional< item::IntValue > | pipe_size_arg |
| for SETPIPE_SZ | |
| std::optional< item::FileSealSettings > | file_seals_arg |
| for ADD_SEALS | |
| std::optional< item::ReadWriteHint > | rw_hint_arg |
| for {GET,SET}_[FILE]_RW_HINT | |
| std::optional< item::SuccessResult > | result |
| for all other cases | |
| std::optional< item::FileDescriptor > | ret_dupfd |
| for DUPFD, DUPFD_CLOEXEC | |
| std::optional< item::FileDescFlagsValue > | ret_fd_flags |
| for GETFD | |
| std::optional< item::OpenFlagsValue > | ret_status_flags |
| for GETFL | |
| std::optional< item::FileDescOwner > | ret_owner |
| for GET_OWNER | |
| std::optional< item::SignalNumber > | ret_io_signal |
| for GETSIG | |
| std::optional< item::LeaseType > | ret_lease |
| for GETLEASE | |
| std::optional< item::IntValue > | ret_pipe_size |
| for GETPIPE_SZ, SETPIPE_SZ | |
| std::optional< item::FileSealSettings > | ret_seals |
| for GET_SEALS | |
Protected Member Functions | |
| void | clear () |
| bool | check2ndPass (const Tracee &) override |
| Check whether a second pass needs to be made processing parameters. | |
| void | prepareNewSystemCall () override |
| Perform any necessary actions before processing a new system call entry event. | |
| void | updateFDTracking (const Tracee &proc) override |
| Update file descriptor tracking. | |
Protected Member Functions inherited from clues::SystemCall | |
| void | fillParameters (const Tracee &proc, const SystemCallInfo &info) |
| void | setReturnItem (SystemCallItem &ret) |
| Sets the return value system call item. | |
| void | addParameters () |
| template<typename T, typename... Targs> | |
| void | addParameters (T &par, Targs &...rest) |
| template<typename... Targs> | |
| void | setParameters (Targs &...args) |
| void | dropFD (const Tracee &proc, const cosmos::FileNum num) |
| void | trackFD (const Tracee &proc, FDInfo &&info) |
Additional Inherited Members | |
Public Types inherited from clues::SystemCall | |
| using | ParameterVector = std::vector<SystemCallItemPtr> |
| Vector of the parameters required for a system call. | |
Static Public Member Functions inherited from clues::SystemCall | |
| static const char * | name (const SystemCallNr nr) |
| Returns the name of the given system call or "<unknown>" if unknown. | |
| static bool | validNr (const SystemCallNr nr) |
| Returns whether the given system call number is in a valid range. | |
Protected Attributes inherited from clues::SystemCall | |
| SystemCallNr | m_nr |
| The raw system call number of the system call. | |
| const std::string_view | m_name |
| The basic name of the system call. | |
| const SystemCallInfo * | m_info = nullptr |
| Current system call info during entry/exit processing, nullptr otherwise. | |
| SystemCallItemPtr | m_return |
| The return value of the system call. | |
| std::optional< ErrnoResult > | m_error |
| If the system call fails, this is the error code. | |
| ParameterVector | m_pars |
| The array of system call parameters, if any. | |
| ABI | m_abi = ABI::UNKNOWN |
| The current system call ABI which is in effect. | |
|
inlineexplicit |
Definition at line 60 of file fs.hxx.
|
overrideprotectedvirtual |
Check whether a second pass needs to be made processing parameters.
This function can be overridden by the actual system call implementation to perform context-sensitive evaluation of system call parameters (e.g. for ioctl() style system calls) upon system call entry.
The implementation of this function is allowed to modify the amount and types of system call parameters and return parameter. In this case true must be returned to let the base class implementation reevaluate all system call parameters.
Reimplemented from clues::SystemCall.
Definition at line 41 of file fs.cxx.
|
overrideprotectedvirtual |
Perform any necessary actions before processing a new system call entry event.
Reimplemented from clues::SystemCall.
Definition at line 8 of file fs.cxx.
|
overrideprotectedvirtual |
Update file descriptor tracking.
This function is called upon successful system call exit to track any potential new file descriptors or stop tracking of existing file descriptors.
Specializations of SystemCall that create or close file descriptors need to overwrite this function and call proc.trackFD() or proc.dropFD() accordingly.
Reimplemented from clues::SystemCall.
Definition at line 167 of file fs.cxx.
| std::optional<item::DNotifySettings> clues::FcntlSystemCall::dnotify_arg |
| std::optional<item::FileDescriptor> clues::FcntlSystemCall::dup_lowest |
| std::optional<item::ExtFileDescOwner> clues::FcntlSystemCall::ext_owner_arg |
| item::FileDescriptor clues::FcntlSystemCall::fd |
| std::optional<item::FileDescFlagsValue> clues::FcntlSystemCall::fd_flags_arg |
| std::optional<item::FileSealSettings> clues::FcntlSystemCall::file_seals_arg |
| std::optional<item::FLockParameter> clues::FcntlSystemCall::flock_arg |
| std::optional<item::SignalNumber> clues::FcntlSystemCall::io_signal_arg |
| std::optional<item::LeaseType> clues::FcntlSystemCall::lease_arg |
| item::FcntlOperation clues::FcntlSystemCall::operation |
| std::optional<item::FileDescOwner> clues::FcntlSystemCall::owner_arg |
| std::optional<item::IntValue> clues::FcntlSystemCall::pipe_size_arg |
| std::optional<item::SuccessResult> clues::FcntlSystemCall::result |
| std::optional<item::FileDescriptor> clues::FcntlSystemCall::ret_dupfd |
| std::optional<item::FileDescFlagsValue> clues::FcntlSystemCall::ret_fd_flags |
| std::optional<item::SignalNumber> clues::FcntlSystemCall::ret_io_signal |
| std::optional<item::LeaseType> clues::FcntlSystemCall::ret_lease |
| std::optional<item::FileDescOwner> clues::FcntlSystemCall::ret_owner |
| std::optional<item::IntValue> clues::FcntlSystemCall::ret_pipe_size |
| std::optional<item::FileSealSettings> clues::FcntlSystemCall::ret_seals |
| std::optional<item::OpenFlagsValue> clues::FcntlSystemCall::ret_status_flags |
| std::optional<item::ReadWriteHint> clues::FcntlSystemCall::rw_hint_arg |
| std::optional<item::OpenFlagsValue> clues::FcntlSystemCall::status_flags_arg |