You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Current database access protocol integration captures simple pgproto3.Query messages but doesn't take into account prepared statements so those slip the audit log.
Example logs when using DataGrip that executes prepared statements:
DEBU [DB:SERVIC] Received client message: &pgproto3.Parse{Name:"S_3", Query:"select * from test", ParameterOIDs:[]uint32(nil)}. db:local from:client id:7714d409-e373-4bf4-9a43-31dd093b440a postgres/engine.go:265
DEBU [DB:SERVIC] Received client message: &pgproto3.Bind{DestinationPortal:"C_4", PreparedStatement:"S_3", ParameterFormatCodes:[]int16(nil), Parameters:[][]uint8(nil), ResultFormatCodes:[]int16{}}. db:local from:client id:7714d409-e373-4bf4-9a43-31dd093b440a postgres/engine.go:265
DEBU [DB:SERVIC] Received client message: &pgproto3.Describe{ObjectType:0x50, Name:"C_4"}. db:local from:client id:7714d409-e373-4bf4-9a43-31dd093b440a postgres/engine.go:265
DEBU [DB:SERVIC] Received client message: &pgproto3.Execute{Portal:"C_4", MaxRows:0x64}. db:local from:client id:7714d409-e373-4bf4-9a43-31dd093b440a postgres/engine.go:265
DEBU [DB:SERVIC] Received client message: &pgproto3.Sync{}. db:local from:client id:7714d409-e373-4bf4-9a43-31dd093b440a postgres/engine.go:265
DEBU [DB:SERVIC] Received server message: &pgproto3.ParseComplete{}. db:local from:server id:7714d409-e373-4bf4-9a43-31dd093b440a postgres/engine.go:303
DEBU [DB:SERVIC] Received server message: &pgproto3.BindComplete{}. db:local from:server id:7714d409-e373-4bf4-9a43-31dd093b440a postgres/engine.go:303
DEBU [DB:SERVIC] Received server message: &pgproto3.RowDescription{Fields:[]pgproto3.FieldDescription{pgproto3.FieldDescription{Name:[]uint8{0x69, 0x64}, TableOID:0x6001, TableAttributeNumber:0x1, DataTypeOID:0x19, DataTypeSize:-1, TypeModifier:-1, Format:0}}}. db:local from:server id:7714d409-e373-4bf4-9a43-31dd093b440a postgres/engine.go:303
DEBU [DB:SERVIC] Received server message: &pgproto3.DataRow{Values:[][]uint8{[]uint8{0x71, 0x77, 0x65, 0x71, 0x77, 0x65, 0x71, 0x77, 0x65}}}. db:local from:server id:7714d409-e373-4bf4-9a43-31dd093b440a postgres/engine.go:303
...
We need to capture pgproto3.Parse messages as well.
The text was updated successfully, but these errors were encountered:
Current database access protocol integration captures simple
pgproto3.Query
messages but doesn't take into account prepared statements so those slip the audit log.Example logs when using DataGrip that executes prepared statements:
We need to capture
pgproto3.Parse
messages as well.The text was updated successfully, but these errors were encountered: