Re: pgcrypto-crypt

From: Chris <dmagick(at)gmail(dot)com>
To: AKHILESH GUPTA <akhilesh(dot)davim(at)gmail(dot)com>
Cc: pgsql-general(at)postgresql(dot)org, pgsql-sql(at)postgresql(dot)org
Subject: Re: pgcrypto-crypt
Date: 2006-04-06 22:24:32
Message-ID: 44359520.2060407@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-sql

AKHILESH GUPTA wrote:
> how do we compare the existing data in the table with the entered one?

same way as anything else, for example:

select * from users where passwd=md5('my_password');

> is there any other function which we can use here for both cases
> encryption as well as for decryption at the script as well as database
> level....

why do you need it encrypted?

Please do reply-all - you will get a quicker response (from me and the
list(s) might have suggestions I don't).

> On 4/6/06, *chris smith* <dmagick(at)gmail(dot)com <mailto:dmagick(at)gmail(dot)com>>
> wrote:
>
> On 4/6/06, AKHILESH GUPTA <akhilesh(dot)davim(at)gmail(dot)com
> <mailto:akhilesh(dot)davim(at)gmail(dot)com>> wrote:
> > dear all,
> > i want to encrypt and decrypt one of the fields in my table
> (i.e-password
> > field)
> > i have searched and with the help of pgcrypto package, using
> function
> > "crypt", i am able to encrypt my data,
> > but there is nothing which i found to decrypt that same data,
> > plz anybody give me the function to decrypt that encrypted
> value.....
>
> The crypt function can't be decrypted (whether it's in postgresql or
> anywhere else).
>
> Crypt is meant to be used for passwords and such that you don't need
> to reverse (you only compare against).
>
> --
> Postgresql & php tutorials
> http://www.designmagick.com/
>
>
>
>
> --
> Thanks & Regards,
> Akhilesh
> DAV Institute of Management
> Faridabad(Haryana)
> GSM:-(+919891606064)
> (+911744293789)
>
> "FAILURES CAN BE FORGIVEN BUT AIMING LOW IS A CRIME"

--
Postgresql & php tutorials
http://www.designmagick.com/

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Guy Fraser 2006-04-06 22:24:49 Re: Backup method
Previous Message Antimon 2006-04-06 22:18:36 Large text data

Browse pgsql-sql by date

  From Date Subject
Next Message Jim Buttafuoco 2006-04-06 22:56:42 Re: Query from shell
Previous Message kevin.kempter 2006-04-06 21:43:16 Re: Query from shell