[issue43762] Add audit events for loading of sqlite3 extensions

2021-05-01 Thread Christian Heimes
Change by Christian Heimes : -- pull_requests: +24468 pull_request: https://github.com/python/cpython/pull/25778 ___ Python tracker ___

[issue43762] Add audit events for loading of sqlite3 extensions

2021-04-26 Thread Steve Dower
Steve Dower added the comment: Thanks for the PR! -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue43762] Add audit events for loading of sqlite3 extensions

2021-04-26 Thread Steve Dower
Steve Dower added the comment: New changeset 7244c0060dc3ef909f34b0791c3e7490b0340d5e by Erlend Egeberg Aasland in branch 'master': bpo-43762: Add audit events for loading of sqlite3 extensions (GH-25246) https://github.com/python/cpython/commit/7244c0060dc3ef909f34b0791c3e7490b0340d5e

[issue43762] Add audit events for loading of sqlite3 extensions

2021-04-26 Thread Erlend Egeberg Aasland
Erlend Egeberg Aasland added the comment: Ah, yes thanks for the heads up! I'll update the PR. -- ___ Python tracker ___ ___

[issue43762] Add audit events for loading of sqlite3 extensions

2021-04-26 Thread Steve Dower
Steve Dower added the comment: Yeah, along those lines. I believe the event is ".../result" in other places, just to be clear that it's not a function with that name. Also, don't forget to clean up when returning early from the connected event. We don't want to leak the connection object if

[issue43762] Add audit events for loading of sqlite3 extensions

2021-04-24 Thread Erlend Egeberg Aasland
Erlend Egeberg Aasland added the comment: Maybe it's better to send the event only if the connection succeeded: diff --git a/Modules/_sqlite/module.c b/Modules/_sqlite/module.c index 8dbfa7b38a..0220978cf2 100644 --- a/Modules/_sqlite/module.c +++ b/Modules/_sqlite/module.c @@ -97,6 +97,12 @@

[issue43762] Add audit events for loading of sqlite3 extensions

2021-04-24 Thread Erlend Egeberg Aasland
Erlend Egeberg Aasland added the comment: Something like the attached patch, if I understand you correctly? -- Added file: https://bugs.python.org/file49982/patch.diff ___ Python tracker

[issue43762] Add audit events for loading of sqlite3 extensions

2021-04-24 Thread Erlend Egeberg Aasland
Erlend Egeberg Aasland added the comment: Good question. sqlite3_load_extension() loads an extension into a database connection, so it would make sense to also pass the connection object. I'd say we do it; it's a small change, and as you say: if we wanted to add it later, we couldn't. Ref.

[issue43762] Add audit events for loading of sqlite3 extensions

2021-04-23 Thread Steve Dower
Steve Dower added the comment: Left some minor suggestions on the PR, but wanted to copy this comment here as well: I wonder if it's worth returning the connection object when it's created (through a new event in module.c) and then reference it in these events? That can then correlate

[issue43762] Add audit events for loading of sqlite3 extensions

2021-04-16 Thread Ned Deily
Change by Ned Deily : -- nosy: +steve.dower ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue43762] Add audit events for loading of sqlite3 extensions

2021-04-07 Thread Erlend Egeberg Aasland
Change by Erlend Egeberg Aasland : -- keywords: +patch pull_requests: +23985 stage: -> patch review pull_request: https://github.com/python/cpython/pull/25246 ___ Python tracker

[issue43762] Add audit events for loading of sqlite3 extensions

2021-04-07 Thread Erlend Egeberg Aasland
New submission from Erlend Egeberg Aasland : If Python is configured with --enable-loadable-sqlite-extensions, it is possible to load third party SQLite extensions (shared libraries/DLL’s) via the sqlite3 extension module. When enabled, the sqlite3.Connection.enable_load_extension() class