Repository navigation
Feat/admin audit logging - #3781
Open
GhassenKefi wants to merge 4 commits into
Open
GhassenKefi wants to merge 4 commits into
GhassenKefi wants to merge 4 commits into
Conversation
Creating a form (empty or as a copy of another form, with the source form ID), deleting a form, transferring its ownership and the following form updates are now written to the admin audit log: - opening the form to or closing it for all users (permitAllUsers, showToAllUsers) - closing, archiving or reopening the form, with the new and previous state - changing the response settings isAnonymous, submitMultiple, allowEditSubmissions, expires or maxSubmissions; only the names of the changed settings are logged - linking the results to a spreadsheet file, with the file ID and format Updates are only logged when the value actually changed, after the form was saved. The title, description, submission message and confirmation email texts are never logged. Unlinking the results file and the short-lived editing lock are not logged. Form deletion is logged in the controller rather than in FormMapper::deleteForm(), which also runs from the cleanup job on user deletion, where there is no actor and admin_audit already logs the user deletion. The operations are collected in the new OCA\Forms\AuditLog\Operation enum, with a short description of each for the documentation. Entries are written through the new OCA\Forms\AuditLog\AuditLogger, which dispatches the public CriticalActionPerformedEvent. Assisted-by: ClaudeCode:claude-opus-5-5 Signed-off-by: Ghassen kefi <ghassen.kefi.dev@gmail.com>
Creating a share of a form (with a user, group or team or by public link), changing the permissions or the custom token of a share and deleting a share are now written to the admin audit log, with the share ID, form ID, share type, recipient and permissions. Forms shares are stored in the Forms share table, not as core shares, so admin_audit did not see them. Deleting a share through the share review is logged with its own message, after the share was deleted. The token of a link share is stored as its recipient and is never logged; a share update only logs whether the token changed. The recipient of user, group and team shares is also logged on updates and deletions, so that a revoked grant can be attributed. Assisted-by: ClaudeCode:claude-opus-5-5 Signed-off-by: Ghassen kefi <ghassen.kefi.dev@gmail.com>
…t log Downloading all results as a CSV, ODS or XLSX file, exporting them to a file in the cloud, deleting all submissions of a form, and deleting or updating a single submission are now written to the admin audit log. The results download is not a file access, so admin_audit did not see it. Submission entries carry the submission ID, the form ID and the user who submitted it, which is often not the user doing the change. The answers are never logged. The cloud export is logged in the controller, not in SubmissionService::writeFileToCloud(), which also runs from the background job keeping a linked results file in sync. The export entry also carries the file ID besides the file name and format. New submissions and uploaded answer files are not logged: they are frequent, often anonymous, and the file writes are already logged by admin_audit. Assisted-by: ClaudeCode:claude-opus-5-5 Signed-off-by: Ghassen kefi <ghassen.kefi.dev@gmail.com>
Changing one of the Forms admin settings (permitting forms for all users, public links, custom public link tokens, showing forms to all users, restricting form creation and the groups allowed to create forms, confirmation emails and their rate limit, comments) is now written to the admin audit log with the setting name and its new value, after the value was saved. All of these settings are booleans, integers or group IDs. Rejected values are not logged. Assisted-by: ClaudeCode:claude-opus-5-5 Signed-off-by: Ghassen kefi <ghassen.kefi.dev@gmail.com>
GhassenKefi
force-pushed
the
feat/admin-audit-logging
branch
from
October 20, 2026 15:46
6a3d3bb to
ef50ec8
Compare
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🤖 AI (if applicable)