Re: Re[2]: [BUGS] BUG #10140: Configured for 127.0.0.1 but binds to all IP

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: sdfasdf asdfasdf <sofiamay(at)mail(dot)ru>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: Re[2]: [BUGS] BUG #10140: Configured for 127.0.0.1 but binds to all IP
Date: 2014-04-26 19:32:59
Message-ID: 13383.1398540779@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

=?UTF-8?B?c2RmYXNkZiBhc2RmYXNkZg==?= <sofiamay(at)mail(dot)ru> writes:
> IT IS A SECURITY (NETWORK) BUG (bind to all ip instead of 127.0.0.1).

No, it's pilot error.

> 2) In config file i wrote:
> listen_addresses = '127.0.0.1'
> 3) Then i do init db and run this command:

If you did things in that order, it would not have worked anyway, because
the config file that the postmaster will use doesn't exist until initdb
creates it. However, the real problem appears to be here:

> C:\database\PostgreSQL-9.3.4\bin\pg_ctl.exe start -w -D "C:\Postgre" -s -o "-i"

The -o "-i" part is passing a -i command line switch to the postmaster,
and that sets listen_addresses to "*", overriding whatever might be in
the config file. If you'd looked at pg_settings as I advised yesterday,
you'd have seen the evidence of this immediately.

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2014-04-26 19:45:33 Re: BUG #10144: PostgreSQL cost_index in costsize.c bug? (cann't estimate indexCorrelation correct)
Previous Message Dave Page 2014-04-26 19:29:22 Re: Re[2]: [BUGS] BUG #10140: Configured for 127.0.0.1 but binds to all IP