pgsql: remove unused "password_message" code

``Password message`` is actually logged just as ``Password``.
Remove related dead code.
pull/13211/head
Juliana Fajardini 2 months ago committed by Victor Julien
parent 6f81caf8d4
commit 62949b3815

@ -2526,7 +2526,7 @@ Requests are sent by the frontend (client), which would be the source of a pgsql
flow. Some of the possible request messages are:
* "startup_message": message sent to start a new PostgreSQL connection
* "password_message": if password output for PGSQL is enabled in suricata.yaml,
* "password": if password output for PGSQL is enabled in suricata.yaml,
carries the password sent during Authentication phase
* "password_redacted": set to true in case there is a password message, but its
logging is disabled

@ -3660,9 +3660,6 @@
"password": {
"type": "string"
},
"password_message": {
"type": "string"
},
"password_redacted": {
"type": "boolean",
"description": "indicates if a password message was received but not logged due to Suricata settings"

@ -80,7 +80,7 @@ fn log_request(req: &PgsqlFEMessage, flags: u32) -> Result<JsonBuilder, JsonErro
payload,
}) => {
if flags & PGSQL_LOG_PASSWORDS != 0 {
js.set_string_from_bytes("password", payload)?;
js.set_string_from_bytes(req.to_str(), payload)?;
} else {
js.set_bool("password_redacted", true)?;
}

@ -393,7 +393,7 @@ impl PgsqlFEMessage {
match self {
PgsqlFEMessage::StartupMessage(_) => "startup_message",
PgsqlFEMessage::SSLRequest(_) => "ssl_request",
PgsqlFEMessage::PasswordMessage(_) => "password_message",
PgsqlFEMessage::PasswordMessage(_) => "password",
PgsqlFEMessage::SASLInitialResponse(_) => "sasl_initial_response",
PgsqlFEMessage::SASLResponse(_) => "sasl_response",
PgsqlFEMessage::SimpleQuery(_) => "simple_query",

Loading…
Cancel
Save