Bug #1694
closedmod_postgresql_vhost not sending password in connect string
Description
mod_postgresql_vhost is not sending the password part of the connect string. Logs show:
mod_postgresql_vhost.c.251: (error) Bad connection for 'host=192.168.1.10 dbname=lighttpd user=lighttpd': fe_sendauth: no password supplied
I played around with src/mod_postgresql_vhost.c and added:
BUFFER_APPEND_STRING_CONST(s->conninfo, " ");
BUFFER_APPEND_STRING_CONST(s->conninfo, "password=");
buffer_append_string_buffer(s->conninfo, s->core->pass);
under the other connect string parts at about line 171 and it is working now.
To get things to compile I also had to remove -lpgport from the
POSTGRESQL_LIBS="$POSTGRESQL_LIBS -lpgport -lpq -lrt"
line in configure.in. Not sure if that is just something with my systems, but it would not compile as there is no pgport library. Removing it allowed compile and it works.
OS: FreeBSD 7.0
Postgresql: postgresql-client-8.2.6_1 from ports
lighttpd-1.5.0-r1992, but appears to be same in trunk
--Matt
-- matt
Files
Updated by stbuehler over 16 years ago
- Status changed from New to Fixed
- Resolution set to fixed
Fixed in r2239
Also available in: Atom