pgsql: Prevent a double free by not reentering be_tls_close().

Поиск
Список
Период
Сортировка
От Noah Misch
Тема pgsql: Prevent a double free by not reentering be_tls_close().
Дата
Msg-id E1YuLeE-00066O-Sd@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Prevent a double free by not reentering be_tls_close().

Reentering this function with the right timing caused a double free,
typically crashing the backend.  By synchronizing a disconnection with
the authentication timeout, an unauthenticated attacker could achieve
this somewhat consistently.  Call be_tls_close() solely from within
proc_exit_prepare().  Back-patch to 9.0 (all supported versions).

Benkocs Norbert Attila

Security: CVE-2015-3165

Branch
------
REL9_2_STABLE

Details
-------
http://git.postgresql.org/pg/commitdiff/439ff9b6b9de435e1c92d05221cfbcb7ff80e150

Modified Files
--------------
src/backend/libpq/be-secure.c       |    5 -----
src/backend/libpq/pqcomm.c          |   23 ++++++++++++++++++-----
src/backend/postmaster/postmaster.c |   11 ++++++++++-
3 files changed, 28 insertions(+), 11 deletions(-)


В списке pgsql-committers по дате отправления:

Предыдущее
От: Noah Misch
Дата:
Сообщение: pgsql: Add error-throwing wrappers for the printf family of functions.
Следующее
От: Noah Misch
Дата:
Сообщение: pgsql: pgcrypto: Report errant decryption as "Wrong key or corrupt data