Received: from maia.hub.org (unknown [200.46.208.211]) by mail.postgresql.org (Postfix) with ESMTP id 26562632315 for ; Thu, 8 Apr 2010 05:53:05 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.208.211]) (amavisd-maia, port 10024) with ESMTP id 47369-05 for ; Thu, 8 Apr 2010 08:52:49 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from roadrunner.wars-nicht.de (roadrunner.wars-nicht.de [88.198.26.233]) by mail.postgresql.org (Postfix) with ESMTP id 581FA632224 for ; Thu, 8 Apr 2010 05:52:54 -0300 (ADT) Received: from platin.wars-nicht.de (f053201065.adsl.alicedsl.de [78.53.201.65]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by roadrunner.wars-nicht.de (Postfix) with ESMTP id 241769D8003 for ; Thu, 8 Apr 2010 10:52:52 +0200 (CEST) Received: from platin.wars-nicht.de (unknown [127.0.0.1]) by platin.wars-nicht.de (Postfix) with ESMTP id C30C1B922DC for ; Thu, 8 Apr 2010 10:52:50 +0200 (CEST) Date: Thu, 8 Apr 2010 10:52:49 +0200 From: Andreas 'ads' Scherbaum To: pgsql-admin@postgresql.org Subject: Re: Database level encryption Message-ID: <20100408105249.0523f772@platin.wars-nicht.de> In-Reply-To: References: <4BB774D4.3070306@joeconway.com> <4BBA05E80200002500030493@gw.wicourts.gov> <4BBA6924.5050305@joeconway.com> <4BBB009102000025000304D3@gw.wicourts.gov> <4BBB6A49020000250003052B@gw.wicourts.gov> X-Mailer: Claws Mail 3.7.2 (GTK+ 2.18.3; i486-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.305 tagged_above=-10 required=5 tests=AWL=-0.195, BAYES_05=-1.11 X-Spam-Level: X-Archive-Number: 201004/79 X-Sequence-Number: 34173 Hi Timothy, On Wed, 7 Apr 2010 13:45:11 +0300 Timothy Madden wrote: > On Wed, Apr 7, 2010 at 1:07 AM, Kevin Grittner > wrote: > > Timothy Madden wrote: > > > [...] > > But the server needs to read certain data from the database > > directory in order to start. =C2=A0In particular, WAL files need to be > > read to get a clean start, and those can contain any data from the > > database table. =C2=A0Any or all tables may need to be accessed to get > > the database to a consistent point on startup. =C2=A0Plus there are all > > the system catalogs, including the ones needed to authenticate > > users. >=20 > OK let's put the key logger issue aside from database encryption. No, because that's one of the main problems. If someone already goot root access on this laptop, he can snuff keystrokes or the network traffic and capture all kind of passwords (and other interesting information). Basically your database, running on an unprivileged account, is only as secure as the root account. > I am willing to accept that the server may need to read the list of > tables/schema-objects in the database, and some leftover data, in > order to start, as long as the leftover data is immediately discarded > upon start-up, and as long as it is likely that this data is not a > large fraction of the data found in the database. It would still be > nice if this check or clean-up could be delayed until such time some > user really selects the database for use, and provides a password. There's more: - Vacuum reads whole memory pages, so any kind of encryption can only be on row level. - Analyze stores the most common values per column, so it must be able to scan the columns without the password. Else the planer won't have reasonable good data. In addition: the statistics data is stored in system tables, so your password must apply here too. Bye --=20 Andreas 'ads' Scherbaum German PostgreSQL User Group European PostgreSQL User Group - Board of Directors Volunteer Regional Contact, Germany - PostgreSQL Project