pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Chris <dmagick@gmail.com>
To: AKHILESH GUPTA <akhilesh.davim@gmail.com>
Cc: pgsql-general@postgresql.org
Cc: pgsql-sql@postgresql.org
Subject: Re: pgcrypto-crypt
Date: Fri, 07 Apr 2006 08:24:32 +1000
Message-ID: <44359520.2060407@gmail.com> (raw)
In-Reply-To: <ad39daf90604060159h2943ecebp4155719531052920@mail.gmail.com>
References: <ad39daf90604060123s7972677cx95c852a59caf94fd@mail.gmail.com>
	<3c1395330604060153p4d773e0fu574a190de1fa4d9a@mail.gmail.com>
	<ad39daf90604060159h2943ecebp4155719531052920@mail.gmail.com>

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@gmail.com <mailto:dmagick@gmail.com>> 
> wrote:
> 
>     On 4/6/06, AKHILESH GUPTA <akhilesh.davim@gmail.com
>     <mailto:akhilesh.davim@gmail.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/



view thread (5+ messages)

Message-ID: <44359520.2060407@gmail.com>
Permalink:  ../44359520.2060407@gmail.com/
Also on:    postgresql.org/message-id/44359520.2060407@gmail.com

 · 

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 using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: dmagick@gmail.com, akhilesh.davim@gmail.com, pgsql-general@postgresql.org
  Subject: Re: pgcrypto-crypt
  In-Reply-To: <44359520.2060407@gmail.com>

* 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