Patch time for PostgreSQL
Crashable and hackable
The maintainers of the PostgreSQL database have released an urgent patch to cope with a vulnerability that allows remote users to crash servers, while authenticated users can execute arbitrary code.
It's time for admins to get busy: the Shodan tool identifies around 170,000 servers that are visible from the Internet, here.
As the advisory CVE-2013-1899 notes, an argument injection vulnerability “allows remote attackers to cause a denial of service (file corruption), and allows remote authenticated users to modify configuration settings and execute arbitrary code, via a connection request using a database name that begins with a "-" (hyphen).”
It impacts PostgreSQL 9.2.x before 9.2.4, 9.1.x before 9.1.9, and 9.0.x before 9.0.13.
An unauthenticated attacker can initiate a denial-of-service that will leave the server unable to restart after it's crashed. The technique is to cause PostgreSQL error messages to be appended to “targeted files” in the server's PostgreSQL data directory – only after the garbage files are removed or the system, is restored from backup will it restart.
The code execution vulnerability is less serious, since the scenario is less likely: ThreatPost states that an authenticated user could attacker a server with the same name as the user, and execute arbitrary code on the server. ®