Re: Converting BYTEA from/to BIGINT

From: Dimitri Fontaine <dfontaine(at)hi-media(dot)com>
To: Vincenzo Romano <vincenzo(dot)romano(at)notorand(dot)it>
Cc: Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>, PostgreSQL General <pgsql-general(at)postgresql(dot)org>
Subject: Re: Converting BYTEA from/to BIGINT
Date: 2010-07-27 09:22:38
Message-ID: 87iq41qnxd.fsf@hi-media-techno.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Vincenzo Romano <vincenzo(dot)romano(at)notorand(dot)it> writes:
> Now, why doing this?
> I am using a plain SEQUENCE to create a (kind of) "session ID". That
> is simple but predictable.
> The idea is to use this function in conjunction with encrypt (from
> pgcrypto) and the blowfish algorithm
> to make that sequence numbers somehow unpredictable.
> I'm pretty sure there are better (or at least easier) solutions out
> there, but there needs to be also some fun
> in here.

I think you'd be interested into the following:

http://wiki.postgresql.org/wiki/Pseudo_encrypt

Regards,
--
dim

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Dimitri Fontaine 2010-07-27 09:28:57 Re: Integral PG DB replication
Previous Message Davor J. 2010-07-27 08:36:16 Re: Inheritance and trigger/FK propagation