-
Notifications
You must be signed in to change notification settings - Fork 397
Add audit event log. #4556
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Add audit event log. #4556
Changes from 1 commit
Commits
Show all changes
20 commits
Select commit
Hold shift + click to select a range
c33ae5c
Add audit event log.
EreMaijala 2eee896
Merge remote-tracking branch 'origin/dev' into dev-audit-event-log
EreMaijala 2d556b3
Use datetime format constant.
EreMaijala 855d579
Use json column type.
EreMaijala 44a228b
Avoid direct $_SERVER access, fix.
EreMaijala 364e640
Fix event search, improve test.
EreMaijala 04f2120
Use compact.
EreMaijala bee1439
Add unit test for expire command.
EreMaijala 2665e06
Fix column name.
EreMaijala 70d8123
Refactor ILS authentication logging.
EreMaijala fbc22dd
Merge remote-tracking branch 'origin/dev' into dev-audit-event-log
EreMaijala a8bd558
Always get service by interface.
EreMaijala 02474ca
Use ATOM format for date/time in JSON.
EreMaijala d38b5bf
Allow strings to be used in type and subtype.
EreMaijala 5a9cc7d
Update module/VuFind/src/VuFind/Db/Service/AuditEventService.php
EreMaijala ecf8208
Allow string/enum in audit event service. Expand test.
EreMaijala b6c82fe
Fix qa.
EreMaijala dee5829
Move another piece of logging into ILSAuthenticator.
EreMaijala 3a11798
Update module/VuFind/src/VuFind/Auth/ILSAuthenticator.php
EreMaijala 40f8c89
Always return a string from type getters.
EreMaijala File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
17 changes: 17 additions & 0 deletions
17
module/VuFind/sql/migrations/mysql/11.0/005-add-audit-event-table.sql
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| CREATE TABLE `audit_event` ( | ||
| `id` int NOT NULL AUTO_INCREMENT, | ||
| `date` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, | ||
| `type` varchar(50) NOT NULL, | ||
| `subtype` varchar(50) NOT NULL, | ||
| `user_id` int NULL, | ||
| `session_id` varchar(128) NULL, | ||
| `username` varchar(255) NULL, | ||
| `client_ip` varchar(255) NULL, | ||
| `server_ip` varchar(255) NULL, | ||
| `server_name` varchar(255) NULL, | ||
| `message` varchar(255) NULL, | ||
| `data` mediumtext NULL, | ||
| PRIMARY KEY (`id`), | ||
| KEY `audit_event_user_id_idx` (`user_id`), | ||
| CONSTRAINT `audit_event_ibfk_1` FOREIGN KEY (`user_id`) REFERENCES `user` (`id`) ON DELETE SET NULL | ||
| ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci; |
19 changes: 19 additions & 0 deletions
19
module/VuFind/sql/migrations/pgsql/11.0/005-add-audit-event-table.sql
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,19 @@ | ||
| CREATE TABLE audit_event ( | ||
| id SERIAL, | ||
| date timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, | ||
| type varchar(50) NOT NULL, | ||
| subtype varchar(50) NOT NULL, | ||
| user_id int, | ||
| session_id varchar(128), | ||
| username varchar(255), | ||
| client_ip varchar(255), | ||
| server_ip varchar(255), | ||
| server_name varchar(255), | ||
| message varchar(255), | ||
| data text NULL, | ||
| PRIMARY KEY (id) | ||
| ); | ||
| CREATE INDEX audit_event_user_id_idx ON audit_event (user_id); | ||
|
|
||
| ALTER TABLE audit_event | ||
| ADD CONSTRAINT audit_event_ibfk_1 FOREIGN KEY (user_id) REFERENCES "user" (id) ON DELETE SET NULL; |
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
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
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
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
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
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.