Detections

Explore public detection logic contributed by the community across SIEM and rule languages.

173 detections

This rule detects administrative SQL statements (ALTER ROLE, CREATE ROLE, or GRANT) that assign the REPLICATION attribute to a database role. The REPLICATION attribute in PostgreSQL allows a user to initiate streaming replication and perform logical decoding. This is a security-sensitive privilege, as users with this attribute can potentially bypass standard access controls or, if the environment is misconfigured or vulnerable (e.g., CVE-2026-6471), potentially leverage malicious replication plugins to achieve arbitrary code execution.
avatar
Arnold Chan@slaz
avatar
Hunters
2 months ago
002
This rule monitors the software inventory for outdated versions of the PostgreSQL database server. It identifies installations where the major and minor versions are below the threshold for current security releases (e.g., v18 < 6, v17 < 11, v16 < 15, v15 < 19, v14 < 24). Running outdated software increases the risk of exploitation of known vulnerabilities.
avatar
Arnold Chan@slaz
avatar
Hunters
2 months ago
002
This rule detects potentially malicious modifications to PostgreSQL configuration files or the creation of new library files (.so or .dll) by the PostgreSQL service process. It also flags when the PostgreSQL service process is initiated with command-line arguments referencing 'shared_preload_libraries', which can be abused to load arbitrary code or malicious extensions into the database engine.
avatar
Arnold Chan@slaz
avatar
Hunters
2 months ago
002
Detects when the Postgres service process or account attempts to modify system-level persistence mechanisms, such as scheduled tasks (cron/schtasks) or system services (systemd/startup folders), which are typical behaviors for an adversary using database service context to maintain persistence.
avatar
Arnold Chan@slaz
avatar
Hunters
2 months ago
002
This rule monitors for modifications to the PostgreSQL configuration file 'pg_hba.conf', specifically looking for changes that would enable 'trust' authentication, followed by successful database logins using that method within one hour. This behavior is indicative of an attacker modifying authentication rules to gain unauthorized, passwordless access to a database.
avatar
Arnold Chan@slaz
avatar
Hunters
2 months ago
002
KQL Query from file: postgresql-pghbaconf-trust-auth-backdoor-enabling-passwordless-logins.kql
avatar
Arnold Chan@slaz
avatar
Hunters
2 months ago
002
KQL Query from file: postgresql-replication-account-escalated-to-superuser-cve-2026-6471.kql
avatar
Arnold Chan@slaz
avatar
Hunters
2 months ago
002
Detects the execution of PostgreSQL dump utilities (pg_dump, pg_dumpall) initiated directly by application-level processes like Langflow or Python, rather than through standard system-level task schedulers. This behavior is indicative of unauthorized data collection or staging of database contents by an application process.
avatar
Arnold Chan@slaz
avatar
Hunters
1 month ago
000
Detects the execution of PostgreSQL dump utilities (pg_dump, pg_dumpall) initiated directly by application-level processes like Langflow or Python, rather than through standard system-level task schedulers. This behavior is indicative of unauthorized data collection or staging of database contents by an application process.
avatar
Arnold Chan@slaz
avatar
Midnight Slayer
1 month ago
000
Detects the execution of PostgreSQL dump utilities (pg_dump, pg_dumpall) initiated directly by application-level processes like Langflow or Python, rather than through standard system-level task schedulers. This behavior is indicative of unauthorized data collection or staging of database contents by an application process.
avatar
Arnold Chan@slaz
avatar
Detections.ai Community
1 month ago
000
Detects modifications to the PostgreSQL configuration file 'pg_hba.conf' closely followed by a reload command (via pg_ctl or postgres processes). This behavior is indicative of an attacker attempting to modify authentication or connection access controls for a database.
avatar
Arnold Chan@slaz
avatar
Hunters
2 months ago
001
Detects attempts to modify internal PostgreSQL system catalog tables (pg_authid or pg_proc) to grant superuser privileges or alter authorization records. This activity is commonly associated with exploiting logical decoding plugins to achieve persistence or privilege escalation in PostgreSQL environments.
avatar
Arnold Chan@slaz
avatar
Hunters
2 months ago
001
Detects instances where a database role initially possessing only REPLICATION privileges is elevated to a SUPERUSER role, which represents a significant escalation of privilege within a PostgreSQL environment.
avatar
Arnold Chan@slaz
avatar
Hunters
2 months ago
001
Detects when the PostgreSQL service process (postgres.exe/postgres/postmaster) loads a shared library (.dll or .so) from a non-standard, user-writable directory (e.g., Temp, AppData, /tmp). This behavior is indicative of potential exploitation of vulnerabilities like CVE-2026-6471, where attackers attempt to load malicious plugins via unvalidated logical decoding plugin paths.
avatar
Arnold Chan@slaz
avatar
Hunters
2 months ago
001
This rule detects potential persistence mechanisms in a PostgreSQL database by identifying the creation of a new shared library file (e.g., .so or .dll) within PostgreSQL plugin directories, followed by a modification to the PostgreSQL configuration files (postgresql.conf or postgresql.auto.conf) within a short 30-minute window. This behavior is indicative of an attacker registering a malicious shared library to be loaded upon database startup, a technique associated with PostGREShell-style post-exploitation.
avatar
Arnold Chan@slaz
avatar
Hunters
2 months ago
001
This rule detects administrative SQL statements (ALTER ROLE, CREATE ROLE, or GRANT) that assign the REPLICATION attribute to a database role. The REPLICATION attribute in PostgreSQL allows a user to initiate streaming replication and perform logical decoding. This is a security-sensitive privilege, as users with this attribute can potentially bypass standard access controls or, if the environment is misconfigured or vulnerable (e.g., CVE-2026-6471), potentially leverage malicious replication plugins to achieve arbitrary code execution.
avatar
Arnold Chan@slaz
avatar
Midnight Slayer
2 months ago
204
Detects attempts to modify internal PostgreSQL system catalog tables (pg_authid or pg_proc) to grant superuser privileges or alter authorization records. This activity is commonly associated with exploiting logical decoding plugins to achieve persistence or privilege escalation in PostgreSQL environments.
avatar
Arnold Chan@slaz
avatar
Midnight Slayer
2 months ago
104
Detects potential exploitation of PostgreSQL via logical decoding plugins, specifically targeting CVE-2026-6471. The rule monitors for the PostgreSQL server process spawning suspicious shell utilities or loading modules from locations outside of the expected PostgreSQL library or plugin directories, which is a common indicator of unauthorized code execution.
avatar
Arnold Chan@slaz
avatar
Midnight Slayer
2 months ago
004
Detects the presence of PostgreSQL logical decoding output plugins (shared libraries) that export the '_PG_init' initialization function and contain strings indicative of unauthorized catalog modification, privilege escalation, or persistence attempts, often associated with PostGREShell-style attack vectors (CVE-2026-6471).
avatar
Arnold Chan@slaz
avatar
Detections.ai Community
2 months ago
006
This rule detects administrative SQL statements (ALTER ROLE, CREATE ROLE, or GRANT) that assign the REPLICATION attribute to a database role. The REPLICATION attribute in PostgreSQL allows a user to initiate streaming replication and perform logical decoding. This is a security-sensitive privilege, as users with this attribute can potentially bypass standard access controls or, if the environment is misconfigured or vulnerable (e.g., CVE-2026-6471), potentially leverage malicious replication plugins to achieve arbitrary code execution.
avatar
Arnold Chan@slaz
Defender - KQL
2 months ago
006
Detects direct SQL UPDATE operations on the pg_authid system table to modify privilege flags (e.g., rolsuper, rolcreaterole) without using the authorized ALTER ROLE statement. Such activity often indicates an attempt to escalate privileges or modify database user permissions in an unauthorized manner, bypassing standard auditing and role management processes.
avatar
Arnold Chan@slaz
avatar
Midnight Slayer
2 months ago
003
Page 2 of 9