pg.ddx.io  pgsql-odbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
catch password on Postgres server
5+ messages / 3 participants
[nested] [flat]

* catch password on Postgres server
@ 2004-01-29 19:42 Bing Du <bdu@iastate.edu>
  2004-01-29 21:33 ` Re: catch password on Postgres server Richard Huxton <dev@archonet.com>
  0 siblings, 1 reply; 5+ messages in thread

From: Bing Du @ 2004-01-29 19:42 UTC (permalink / raw)
  To: pgsql-odbc

Greetings,

Postgres 7.4 running on RedHat 9.

We are trying to migrate a MS SQL server based comertial application
software to a Postgres database.  We know what password that application
uses to connect to the MS SQL database.  The password has five letters.
We've set up the same user on the Postgres server.  However, when the
application software connects to the Postgres database through the
PostgreSQL ODBC driver, the Postgres server always shows 'password
authentication for user ...' in the log file.  I even tried all the
permutations of the letters in various cases that make up the password. 
None works.  I'm completely lost.  Is there anyway on the server side to
see what was  submitted in the password field by the application from the
client side?

Any help would be greatly appreciated.

Bing



^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: catch password on Postgres server
  2004-01-29 19:42 catch password on Postgres server Bing Du <bdu@iastate.edu>
@ 2004-01-29 21:33 ` Richard Huxton <dev@archonet.com>
  2004-01-30 21:15   ` Re: catch password on Postgres server Bing Du <bdu@iastate.edu>
  2004-02-02 22:30   ` Re: catch password on Postgres server Bing Du <bdu@iastate.edu>
  0 siblings, 2 replies; 5+ messages in thread

From: Richard Huxton @ 2004-01-29 21:33 UTC (permalink / raw)
  To: Bing Du <bdu@iastate.edu>; pgsql-odbc

On Thursday 29 January 2004 19:42, Bing Du wrote:
> Greetings,
>
> Postgres 7.4 running on RedHat 9.
>
> We are trying to migrate a MS SQL server based comertial application
> software to a Postgres database.  We know what password that application
> uses to connect to the MS SQL database.

> Is there anyway on the server side to
> see what was  submitted in the password field by the application from the
> client side?

Don't think you can get to the password without changing the code. I can think 
of two options:
1. In src/backend/libpq/auth.c search for "echo password to logs" and change 
the ereport() to log the password rather than not to. Reply to this if C 
isn't your thing.

2. Use tcpdump -s 255 port 5432 and see what's going over the wire. You'd need 
to set plaintext passwords though.

Before any of this though, make sure you can connect from Access using that 
password.
-- 
  Richard Huxton
  Archonet Ltd



^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: catch password on Postgres server
  2004-01-29 19:42 catch password on Postgres server Bing Du <bdu@iastate.edu>
  2004-01-29 21:33 ` Re: catch password on Postgres server Richard Huxton <dev@archonet.com>
@ 2004-01-30 21:15   ` Bing Du <bdu@iastate.edu>
  1 sibling, 0 replies; 5+ messages in thread

From: Bing Du @ 2004-01-30 21:15 UTC (permalink / raw)
  To: Richard Huxton <dev@archonet.com>; +Cc: pgsql-odbc

Thanks very much, Richard, for your response.  Yes, I've verified other
ODBC applications can connect fine using the same password.  I'll try your
suggestions.  I've not used C for many years.

Bing

> On Thursday 29 January 2004 19:42, Bing Du wrote:
>> Greetings,
>>
>> Postgres 7.4 running on RedHat 9.
>>
>> We are trying to migrate a MS SQL server based comertial application
>> software to a Postgres database.  We know what password that application
>> uses to connect to the MS SQL database.
>
>> Is there anyway on the server side to
>> see what was  submitted in the password field by the application from
>> the
>> client side?
>
> Don't think you can get to the password without changing the code. I can
> think
> of two options:
> 1. In src/backend/libpq/auth.c search for "echo password to logs" and
> change
> the ereport() to log the password rather than not to. Reply to this if C
> isn't your thing.
>
> 2. Use tcpdump -s 255 port 5432 and see what's going over the wire. You'd
> need
> to set plaintext passwords though.
>
> Before any of this though, make sure you can connect from Access using
> that
> password.
> --
>   Richard Huxton
>   Archonet Ltd
>




^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: catch password on Postgres server
  2004-01-29 19:42 catch password on Postgres server Bing Du <bdu@iastate.edu>
  2004-01-29 21:33 ` Re: catch password on Postgres server Richard Huxton <dev@archonet.com>
@ 2004-02-02 22:30   ` Bing Du <bdu@iastate.edu>
  2004-02-03 03:20     ` Re: catch password on Postgres server Tom Lane <tgl@sss.pgh.pa.us>
  1 sibling, 1 reply; 5+ messages in thread

From: Bing Du @ 2004-02-02 22:30 UTC (permalink / raw)
  To: Richard Huxton <dev@archonet.com>; +Cc: pgsql-odbc

Regarding of changing ereport(), what's its syntax supposed to be?  Would

ereport(LOG, (buf.data))

echo password to logs?

Appreciate any help as always,

Bing

> On Thursday 29 January 2004 19:42, Bing Du wrote:
>> Greetings,
>>
>> Postgres 7.4 running on RedHat 9.
>>
>> We are trying to migrate a MS SQL server based comertial application
>> software to a Postgres database.  We know what password that application
>> uses to connect to the MS SQL database.
>
>> Is there anyway on the server side to
>> see what was  submitted in the password field by the application from
>> the
>> client side?
>
> Don't think you can get to the password without changing the code. I can
> think
> of two options:
> 1. In src/backend/libpq/auth.c search for "echo password to logs" and
> change
> the ereport() to log the password rather than not to. Reply to this if C
> isn't your thing.
>
> 2. Use tcpdump -s 255 port 5432 and see what's going over the wire. You'd
> need
> to set plaintext passwords though.
>
> Before any of this though, make sure you can connect from Access using
> that
> password.
> --
>   Richard Huxton
>   Archonet Ltd
>




^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: catch password on Postgres server
  2004-01-29 19:42 catch password on Postgres server Bing Du <bdu@iastate.edu>
  2004-01-29 21:33 ` Re: catch password on Postgres server Richard Huxton <dev@archonet.com>
  2004-02-02 22:30   ` Re: catch password on Postgres server Bing Du <bdu@iastate.edu>
@ 2004-02-03 03:20     ` Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 5+ messages in thread

From: Tom Lane @ 2004-02-03 03:20 UTC (permalink / raw)
  To: Bing Du <bdu@iastate.edu>; +Cc: Richard Huxton <dev@archonet.com>; pgsql-odbc

"Bing Du" <bdu@iastate.edu> writes:
> Regarding of changing ereport(), what's its syntax supposed to be?  Would
> ereport(LOG, (buf.data))
> echo password to logs?

See
http://www.postgresql.org/docs/7.4/static/error-message-reporting.html

			regards, tom lane



^ permalink  raw  reply  [nested|flat] 5+ messages in thread


end of thread, other threads:[~2004-02-03 03:20 UTC | newest]

Thread overview: 5+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2004-01-29 19:42 catch password on Postgres server Bing Du <bdu@iastate.edu>
2004-01-29 21:33 ` Richard Huxton <dev@archonet.com>
2004-01-30 21:15   ` Bing Du <bdu@iastate.edu>
2004-02-02 22:30   ` Bing Du <bdu@iastate.edu>
2004-02-03 03:20     ` Tom Lane <tgl@sss.pgh.pa.us>

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