forked from pgaudit/pgaudit
-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Description
Overview
- Pattern matching with '%' character is not supported
- In Readme.md '%' with the character, it has been described as a possible backward match or forward match.
In the value '%' can be used for backward match or forward match.
- If pattern matching is not supported, it is necessary to modify Readme.md.
Config file
[output]
logger = 'serverlog'
# SQL(1)
[rule]
class = 'READ,WRITE'
object_name = 'public.f%'
# SQL(2)
[rule]
class = 'READ,WRITE'
object_name = 'public.f%,b%,public.baz%'
# SQL(3)
[rule]
class = 'READ,WRITE'
object_name = 'ba%,public.baz%,public.fo%'
Executed SQL
-- create objects
CREATE TABLE IF NOT EXISTS foo(id int, data text);
CREATE TABLE IF NOT EXISTS bar(id int, data text);
BEGIN;
INSERT INTO foo VALUES (1, 'aaa');
INSERT INTO bar VALUES (1, 'xxx');
UPDATE foo SET data = 'AAA' WHERE id = 1;
UPDATE bar SET data = 'XXX' WHERE id = 1;
SELECT * FROM foo;
SELECT * FROM bar;
DELETE FROM foo;
DELETE FROM bar;
TRUNCATE foo;
TRUNCATE bar;
COMMIT;
DROP TABLE foo;
DROP TABLE bar;
Log.
LOG: connection received: host=[local]
LOG: connection authorized: user=postgres database=postgres
LOG: disconnection: session time: 0:00:00.060 user=postgres database=postgres host=[local]
- Since no pattern match evaluation is performed, all audit logs are not output.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels