First available in Python 3.8, PEP 578 introduced audit hooks for certain functions which could be considered security-sensitive, such as opening a file or accessing the Windows registry.
To better support users who may want to log or inspect such events, we should add calls to PySys_Audit to the functions in SDSFilePython.cpp where SDS files are being opened for reading or writing. Ideally, we'd use the same event name and provide the same event data as used in CPython for their fopen wrapper, so users monitoring that event would just start seeing data for SDS reads/writes without having to make any additional changes to their setup.
More Info:
First available in Python 3.8, PEP 578 introduced audit hooks for certain functions which could be considered security-sensitive, such as opening a file or accessing the Windows registry.
To better support users who may want to log or inspect such events, we should add calls to
PySys_Auditto the functions in SDSFilePython.cpp where SDS files are being opened for reading or writing. Ideally, we'd use the same event name and provide the same event data as used in CPython for theirfopenwrapper, so users monitoring that event would just start seeing data for SDS reads/writes without having to make any additional changes to their setup.More Info:
PySys_Auditcalls in CPython