Debian DSA-229-1 : imp - SQL injection

high Nessus Plugin ID 15066

Synopsis

The remote Debian host is missing a security-related update.

Description

Jouko Pynnonen discovered a problem with IMP, a web-based IMAP mail program. Using carefully crafted URLs a remote attacker is able to inject SQL code into SQL queries without proper user authentication.
Even though results of SQL queries aren't directly readable from the screen, an attacker might update their mail signature to contain wanted query results and then view it on the preferences page of IMP.

The impact of SQL injection depends heavily on the underlying database and its configuration. If PostgreSQL is used, it's possible to execute multiple complete SQL queries separated by semicolons. The database contains session id's so the attacker might hijack sessions of people currently logged in and read their mail. In the worst case, if the hordemgr user has the required privilege to use the COPY SQL command (found in PostgreSQL at least), a remote user may read or write to any file the database user (postgres) can. The attacker may then be able to run arbitrary shell commands by writing them to the postgres user's ~/.psqlrc; they'd be run when the user starts the psql command which under some configurations happens regularly from a cron script.

Solution

Upgrade the IMP packages.

For the current stable distribution (woody) this problem has been fixed in version 2.2.6-5.1.

For the old stable distribution (potato) this problem has been fixed in version 2.2.6-0.potato.5.1.

See Also

http://www.debian.org/security/2003/dsa-229

Plugin Details

Severity: High

ID: 15066

File Name: debian_DSA-229.nasl

Version: 1.22

Type: local

Agent: unix

Published: 9/29/2004

Updated: 1/4/2021

Supported Sensors: Frictionless Assessment Agent, Nessus Agent, Agentless Assessment, Nessus

Risk Information

VPR

Risk Factor: Medium

Score: 5.8

CVSS v2

Risk Factor: High

Base Score: 7.5

Temporal Score: 6.5

Vector: CVSS2#AV:N/AC:L/Au:N/C:P/I:P/A:P

Vulnerability Information

CPE: p-cpe:/a:debian:debian_linux:imp, cpe:/o:debian:debian_linux:2.2, cpe:/o:debian:debian_linux:3.0

Required KB Items: Host/local_checks_enabled, Host/Debian/release, Host/Debian/dpkg-l

Exploit Available: true

Exploit Ease: No exploit is required

Patch Publication Date: 1/15/2003

Reference Information

CVE: CVE-2003-0025

BID: 6559

DSA: 229