From: Juliana Fajardini Date: Tue, 5 Dec 2023 13:56:28 +0000 (-0300) Subject: pgsql: don't log password msg if password disabled X-Git-Tag: suricata-8.0.0-beta1~1967 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=bdec2d8ea80cf69a8d1ce9c4505452f17f6058fe;p=thirdparty%2Fsuricata.git pgsql: don't log password msg if password disabled If the logging of the password is disabled, there isn't much point in logging the password message itself. --- diff --git a/rust/src/pgsql/logger.rs b/rust/src/pgsql/logger.rs index b17986dec8..4a6f248802 100644 --- a/rust/src/pgsql/logger.rs +++ b/rust/src/pgsql/logger.rs @@ -78,8 +78,6 @@ fn log_request(req: &PgsqlFEMessage, flags: u32) -> Result { if flags & PGSQL_LOG_PASSWORDS != 0 { js.set_string_from_bytes("password", payload)?; - } else { - js.set_string(req.to_str(), "password log disabled")?; } } PgsqlFEMessage::SASLResponse(RegularPacket {