Re: Using md5 authentication

From: Athanasios Kostopoulos <athanasios(dot)kostopoulos(at)classmarkets(dot)com>
To: Philip Poloczek <Philip(dot)Poloczek(at)dlr(dot)de>
Cc: "pgsql-novice(at)postgresql(dot)org" <pgsql-novice(at)postgresql(dot)org>
Subject: Re: Using md5 authentication
Date: 2013-07-31 08:10:32
Message-ID: CAFnWstMb4nnjFFx_JZ6z2fFfw081qTkVq3JfB2MQLCoMEYE3RQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

AFAIK, the permissions of .pgpass (0600) take care of security reasons.

On Wed, Jul 31, 2013 at 9:55 AM, Philip Poloczek <Philip(dot)Poloczek(at)dlr(dot)de>wrote:

> So isn't there any way to directly use a hash as password?
> I want to store the password locally as a hash instead of plain text for
> security reasons.
>
>
> Am 31.07.2013 09:43, schrieb Athanasios Kostopoulos:
>
> From the manual:
> "The password-based authentication methods are md5 and password. These
> methods operate similarly except for the way that the password is sent
> across the connection, namely MD5-hashed and clear-text respectively."
>
> so you still have to specify the password and not the hash of it in your
> .pgpass or manual connection string.
>
>
> On Wed, Jul 31, 2013 at 9:17 AM, Philip Poloczek <Philip(dot)Poloczek(at)dlr(dot)de>wrote:
>
>> Hello,
>>
>> I want to connect to my database using a md5 hash instead of the plain
>> password, so i changed the authentication method in the pg_hba.conf to md5
>> instead of password.
>> example: i want to use '5f4dcc3b5aa765d61d8327deb882cf99' instead of
>> 'password' in the login mask.
>>
>> But until now i didn't get it working, i still can connect to the
>> database with the plain password but not with the corresponding md5 Hash.
>> When i'am using the md5 hash i just get a FATAL error for password
>> authentication. I used pg_ctl to reload the pg_hba.conf and also restarted
>> the server.
>>
>> Also the md5 hash which is saved for the users in the database differs
>> from my created ones for that specific password. I read that the passwords
>> are salted before encrypted with a part of the usernames? But even if i use
>> these md5 hashes as password input, i can not connect and get a FATAL error.
>>
>> BTW is it possible to use SHA-1 encrypted passwords with postgresql?
>>
>> I'am currently using postgresql 8.4.
>>
>> pg_hba.conf
>> local all all md5
>> host all all 127.0.0.1/32 md5
>>
>> Best recards,
>> pp
>>
>>
>> --
>> Sent via pgsql-novice mailing list (pgsql-novice(at)postgresql(dot)org)
>> To make changes to your subscription:
>> http://www.postgresql.org/mailpref/pgsql-novice
>>
>
>
> classmarkets GmbH | Schumannstraße 6 | 10117 Berlin | Deutschland
> Tel: +49 (0)30 56 59 001-0 | Fax: +49 (0)30 56 59 001-99 |
> www.classmarkets.com
>
> Amtsgericht Charlottenburg HRB 111815 B | USt.Id.Nr: DE 260731582
> Geschäftsführer: Veit Mürz, Fabian Ströhle
>
> Diese Nachricht (inklusive aller Anhänge) ist vertraulich. Sie darf
> ausschließlich durch den vorgesehenen Empfänger und Adressaten gelesen,
> kopiert oder genutzt werden. Sollten Sie diese Nachricht versehentlich
> erhalten haben, bitten wir, den Absender (durch Antwort-E-Mail) hiervon
> unverzüglich zu informieren und die Nachricht zu löschen. Jede unerlaubte
> Nutzung oder Weitergabe des Inhalts dieser Nachricht, sei es vollständig
> oder teilweise, ist unzulässig. Bitte beachten Sie, dass E-Mail-Nachrichten
> an den Absender nicht für fristgebundene Mitteilungen geeignet sind.
> Fristgebundene Mitteilungen sind daher ausschließlich per Post oder per
> Telefax zu übersenden.
>
>
>
> --
> *Deutsches Zentrum für Luft- und Raumfahrt* e.V. (DLR)
> Institut für Aerodynamik und Strömungstechnik | Abteilung Raumfahrzeuge |
> Bunsenstr. 10 | 37073 Göttingen
>
> *Philip Poloczek* | Dualer Student (DHBW-Mannheim<http://www.dhbw-mannheim.de/>
> )
> Telefon 0551 709-2343 | Philip(dot)Poloczek(at)dlr(dot)de
> www.DLR.de
>

--

classmarkets GmbH | Schumannstraße 6 | 10117 Berlin | Deutschland
Tel: +49 (0)30 56 59 001-0 | Fax: +49 (0)30 56 59 001-99 |
www.classmarkets.com

Amtsgericht Charlottenburg HRB 111815 B | USt.Id.Nr: DE 260731582
Geschäftsführer: Veit Mürz, Fabian Ströhle

Diese Nachricht (inklusive aller Anhänge) ist vertraulich. Sie darf
ausschließlich durch den vorgesehenen Empfänger und Adressaten gelesen,
kopiert oder genutzt werden. Sollten Sie diese Nachricht versehentlich
erhalten haben, bitten wir, den Absender (durch Antwort-E-Mail) hiervon
unverzüglich zu informieren und die Nachricht zu löschen. Jede unerlaubte
Nutzung oder Weitergabe des Inhalts dieser Nachricht, sei es vollständig
oder teilweise, ist unzulässig. Bitte beachten Sie, dass E-Mail-Nachrichten
an den Absender nicht für fristgebundene Mitteilungen geeignet sind.
Fristgebundene Mitteilungen sind daher ausschließlich per Post oder per
Telefax zu übersenden.

In response to

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message Philip Poloczek 2013-07-31 08:25:03 Re: Using md5 authentication
Previous Message Philip Poloczek 2013-07-31 07:55:54 Re: Using md5 authentication