[pgpool-committers: 3738] pgpool: Fix authentication timeout that can occur right after client co
Yugo Nagata
nagata at sraoss.co.jp
Wed Jan 4 14:20:53 JST 2017
Fix authentication timeout that can occur right after client connecttions
This is possible when connection_life_time is enabled.
SIGALRM signal is used for both connection_life_time and
authentication_timeout. Usually, SIGALRM is for connection_life_time,
but when the new connection is arrive, read_startup_packet() is called,
and the handler for authentication_timeout is set by pool_signal() and
alarm(authentication_timeout) is called in enable_authentication_timeout().
However, if connection_life_time is expired **between pool_signal() and
alarm()**, authenticate_timeout() will be called when connection_life_time
is expired instead of pool_backend_timer_handler().
To fix this, call alarm() before pool_signal() to prevent the signal
handler from being with wrong timing.
Branch
------
V3_4_STABLE
Details
-------
http://git.postgresql.org/gitweb?p=pgpool2.git;a=commitdiff;h=388e9c1550c001ec6837d0869db72c473ef6c823
Modified Files
--------------
src/protocol/child.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
More information about the pgpool-committers
mailing list