Thread: password() function?

password() function?

From
Peter Choe
Date:
is there a password() function in postgres?  something similar to mySQL?

Peter Choe



Re: password() function?

From
"Berend Tober"
Date:
> is there a password() function in postgres?  something similar to
> mySQL?
>

I'm not sure why, when you post to a postgresql news group, you would
assume knowlege of how some other product works. That's kind of like
using Microsoft products as your frame of reference on an open-source
news group. Bad form. It would be more useful if you pointed out more
specifically the functionality you are inquiring about.

That flame extinquished, if what you are looking for is a way to change
passwords, you can use ALTER USER inside a stored procedure.

What I do is create the stored procedure as owned by a superuser, and
then grant select privileges on the procedure to an admin group so that
my customers have the ability to change passwords without having to
actually have dba privileges to the database. Same thing for CREATE USER,
DROP USER, ALTER GROUP, etc.





Re: password() function?

From
Arjen van der Meijden
Date:
You're probably looking for something like the crypt() or the
crypt_md5() function supplied in de contrib/pgcrypto module.

Regards,

Arjen

> -----Oorspronkelijk bericht-----
> Van: pgsql-general-owner@postgresql.org
> [mailto:pgsql-general-owner@postgresql.org] Namens Peter Choe
> Verzonden: donderdag 6 februari 2003 16:33
> Aan: pgsql-general@postgresql.org
> Onderwerp: [GENERAL] password() function?
>
>
> is there a password() function in postgres?  something
> similar to mySQL?
>
> Peter Choe
>
>
>
> ---------------------------(end of
> broadcast)---------------------------
> TIP 3: if posting/reading through Usenet, please send an
> appropriate subscribe-nomail command to
> majordomo@postgresql.org so that your message can get through
> to the mailing list cleanly
>



Re: password() function?

From
Robert Treat
Date:
On Thu, 2003-02-06 at 10:59, Berend Tober wrote:
>
> > is there a password() function in postgres?  something similar to
> > mySQL?
> >
>
> I'm not sure why, when you post to a postgresql news group, you would
> assume knowlege of how some other product works. That's kind of like
> using Microsoft products as your frame of reference on an open-source
> news group. Bad form. It would be more useful if you pointed out more
> specifically the functionality you are inquiring about.
>

I think it's worse etiquette to flame people when they are just trying
to get help. If his question doesn't make sense to you, ask for
clarification, don't criticize him for asking the question in a way that
you don't understand. And besides, given that everyone knows people are
switching from mysql to postgresql by the thousands, he probably just
took for granted that some of the people here would know what he was
talking about without having to give a full breakdown.

Peter, do some searching on pgcrypto, you'll find what your looking for.

Robert Treat



Re: password() function?

From
Andrew Sullivan
Date:
On Thu, Feb 06, 2003 at 10:59:58AM -0500, Berend Tober wrote:

> That flame extinquished, if what you are looking for is a way to change
> passwords, you can use ALTER USER inside a stored procedure.

Or it might be a way of storing passwords, in which case reading the
README in contrib/pgcrypto might help.

A

--
----
Andrew Sullivan                         204-4141 Yonge Street
Liberty RMS                           Toronto, Ontario Canada
<andrew@libertyrms.info>                              M2P 2A8
                                         +1 416 646 3304 x110


Re: password() function?

From
Arjen van der Meijden
Date:
Besides that, last time I checked MySQL was not owned by Microsoft ;)

Arjen

> -----Oorspronkelijk bericht-----
> Van: pgsql-general-owner@postgresql.org
> [mailto:pgsql-general-owner@postgresql.org] Namens Robert Treat
> Verzonden: donderdag 6 februari 2003 17:18
> Aan: Berend Tober
> CC: pgsql-general@postgresql.org; Peter Choe
> Onderwerp: Re: [GENERAL] password() function?
>
>
> On Thu, 2003-02-06 at 10:59, Berend Tober wrote:
> >
> > > is there a password() function in postgres?  something similar to
> > > mySQL?
> > >
> >
> > I'm not sure why, when you post to a postgresql news group,
> you would
> > assume knowlege of how some other product works. That's
> kind of like
> > using Microsoft products as your frame of reference on an
> open-source
> > news group. Bad form. It would be more useful if you
> pointed out more
> > specifically the functionality you are inquiring about.
> >
>
> I think it's worse etiquette to flame people when they are
> just trying to get help. If his question doesn't make sense
> to you, ask for clarification, don't criticize him for asking
> the question in a way that you don't understand. And besides,
> given that everyone knows people are switching from mysql to
> postgresql by the thousands, he probably just took for
> granted that some of the people here would know what he was
> talking about without having to give a full breakdown.
>
> Peter, do some searching on pgcrypto, you'll find what your
> looking for.
>
> Robert Treat
>
>
>
> ---------------------------(end of
> broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to
> majordomo@postgresql.org
>



Re: password() function?

From
"Berend Tober"
Date:
> On Thu, Feb 06, 2003 at 10:59:58AM -0500, Berend Tober wrote:
>
>> That flame extinquished, if what you are looking for is a way to
>> change passwords, you can use ALTER USER inside a stored procedure.
>
> Or it might be a way of storing passwords, in which case reading the
> README in contrib/pgcrypto might help.
>

Yes, indeed it might. And that reference might help him. Would have been
nice, as I attempted to teach him, though, if the question had been
framed in a way appropriate for this forum. I'm not going to waste my
time reading the mySQL documentation to figure out his question about
PostgreSQL, however. No apologies here.




Re: password() function?

From
Peter Choe
Date:
i didn't mean to get people upset about this whole.  i appreciate all the
help that i received for everyone.

i'll try to ask better questions next time.

Peter Choe

At 01:27 PM 2/6/2003, Berend Tober wrote:

> > On Thu, Feb 06, 2003 at 10:59:58AM -0500, Berend Tober wrote:
> >
> >> That flame extinquished, if what you are looking for is a way to
> >> change passwords, you can use ALTER USER inside a stored procedure.
> >
> > Or it might be a way of storing passwords, in which case reading the
> > README in contrib/pgcrypto might help.
> >
>
>Yes, indeed it might. And that reference might help him. Would have been
>nice, as I attempted to teach him, though, if the question had been
>framed in a way appropriate for this forum. I'm not going to waste my
>time reading the mySQL documentation to figure out his question about
>PostgreSQL, however. No apologies here.
>
>
>
>
>---------------------------(end of broadcast)---------------------------
>TIP 2: you can get off all lists at once with the unregister command
>     (send "unregister YourEmailAddressHere" to majordomo@postgresql.org)