pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Mathijs Brands <mathijs@ilse.nl>
To: clayton cottingham <drfrog@smartt.com>
Cc: Boulat Khakimov <boulat@inet-interactif.com>
Cc: pgsql-sql@postgresql.org
Subject: Re: Two way encryption in PG???
Date: Tue, 6 Mar 2001 00:06:25 +0100
Message-ID: <20010306000625.H22983@ilse.nl> (raw)
In-Reply-To: <3AA3C195.3B525BB@smartt.com>
References: <Pine.LNX.4.31.0103041803350.30977-100000@bubbles.electricutopia.net>
	<3AA39E82.756494C1@inet-interactif.com>
	<3AA3C195.3B525BB@smartt.com>

On Mon, Mar 05, 2001 at 08:40:53AM -0800, clayton cottingham allegedly wrote:
> Boulat Khakimov wrote:
> > 
> > David Olbersen wrote:
> > >
> > > On Sun, 4 Mar 2001, Boulat Khakimov wrote:
> > >
> > > ->How do I encrypt/decrypt something in PG?
> > >
> > > Perhaps it'd be better to one-way encrypt something? Granted I don't know the
> > > details of your project, but allowing a way to "decrypt" something is rather
> > > insecure.
> > >
> > > -- Dave
> > 
> > Now, one way CC encryption doesnt really make any sense, does it :)
> > 
> > Two-way encryption algorithms like blowfish are very hard to break, too
> > bad they are
> > not build in to PG.
> > 
> 
> this could be easily done with
> PL/perl couldnt it?

It's still not clear to me why someone would want to. Having the database
server do two-way encryption doesn't really provide you with any extra
protection. Also, it puts extra strain on the database server.

If you want to store encrypted data on the server, have the application do
the encryption. That also would provide for a much more scaleable solution,
since it doesn't put any extra load on the database server. Doing the
encryption on the application end should be pretty easy.

I know there are some database(like) systems that can do this kind of stuff,
but the only advantage I can see at the moment is that when someone
physically steals your database server (or the disks), they can't read your
data. This only works when the key is NOT, again, NOT stored on disk in any
form; query the sysadmin (or someone similar) when starting the db server
instead.

Btw. don't even think about asymmetric (public key) cyphers, such as RSA.
They are MUCH too slow, both in setup and processing (throughput) time.

Cheers,

Mathijs
-- 
It's not that perl programmers are idiots, it's that the language
rewards idiotic behavior in a way that no other language or tool has
ever done.
                                                    Erik Naggum



view thread (5+ messages)

Message-ID: <20010306000625.H22983@ilse.nl>
Permalink:  ../20010306000625.H22983@ilse.nl/
Also on:    postgresql.org/message-id/20010306000625.H22983@ilse.nl

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-sql@postgresql.org
  Cc: mathijs@ilse.nl, drfrog@smartt.com, boulat@inet-interactif.com
  Subject: Re: Two way encryption in PG???
  In-Reply-To: <20010306000625.H22983@ilse.nl>
  References: <Pine.LNX.4.31.0103041803350.30977-100000@bubbles.electricutopia.net> <3AA39E82.756494C1@inet-interactif.com> <3AA3C195.3B525BB@smartt.com> <20010306000625.H22983@ilse.nl>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox