The PostgreSQL Global Development Group has released an update to all

supported versions of our database system, including 11.3, 10.8, 9.6.13,
9.5.17, and 9.4.22. This release fixes two security issues in the
PostgreSQL server, a security issue found in two of the PostgreSQL
Windows installers, and over 60 bugs reported over the last three months.

Security:	CVE-2019-10129: Memory disclosure in partition routing

Prior to this release, a user running PostgreSQL 11 can read arbitrary
bytes of server memory by executing a purpose-crafted INSERT statement
to a partitioned table.

Security:	CVE-2019-10130: Selectivity estimators bypass row security policies

PostgreSQL maintains statistics for tables by sampling data available in
columns; this data is consulted during the query planning process. Prior
to this release, a user able to execute SQL queries with permissions to
read a given column could craft a leaky operator that could read
whatever data had been sampled from that column.  If this happened to
include values from rows that the user is forbidden to see by a row
security policy, the user could effectively bypass the policy.  This is
fixed by only allowing a non-leakproof operator to use this data if
there are no relevant row security policies for the table.

This issue is present in PostgreSQL 9.5, 9.6, 10, and 11. The PostgreSQL
project thanks Dean Rasheed for reporting this problem.

Also fix a FreeBSD port problem with LLVM [1] and add promote command
to `service postgresql` [2]

PR:	236100, 234879
Submitted by:	tomonori.usaka@ubin.jp [1], Trix Farrar [2]
This commit is contained in:
Palle Girgensohn
2019-05-09 22:32:11 +00:00
parent 037bd13c9c
commit 0e8e77e466
17 changed files with 52 additions and 28 deletions

View File

@@ -2,10 +2,10 @@
# $FreeBSD$
PORTNAME?= postgresql
DISTVERSION?= 11.2
# PORTREVISION must be ?= otherwise, all other port get this PORTREVISION and
DISTVERSION?= 11.3
# PORTREVISION must be ?= otherwise, all slave ports get this PORTREVISION and
# not their own. Probably best to keep it at ?=0 when reset here too.
PORTREVISION?= 2
PORTREVISION?= 0
CATEGORIES?= databases
MASTER_SITES= PGSQL/source/v${DISTVERSION}
PKGNAMESUFFIX?= ${PORTVERSION:R}${COMPONENT}
@@ -175,12 +175,13 @@ USES+= compiler:gcc-c++11-lib
.if ${DISTVERSION:C/([0-9]*).*/\1/} >= 11
. if defined(SERVER_ONLY) && ${PORT_OPTIONS:MLLVM}
LLVM_VERSION= 60
BUILD_DEPENDS+= llvm-config${LLVM_VERSION}:devel/llvm${LLVM_VERSION}
RUN_DEPENDS+= llvm-config${LLVM_VERSION}:devel/llvm${LLVM_VERSION}
CONFIGURE_ENV+= LLVM_CONFIG=${LOCALBASE}/bin/llvm-config60 CLANG=${LOCALBASE}/bin/clang60
BUILD_DEPENDS+= llvm${LLVM_DEFAULT}>0:devel/llvm${LLVM_DEFAULT}
BUILD_DEPENDS+= llvm-config${LLVM_DEFAULT}:devel/llvm${LLVM_DEFAULT}
RUN_DEPENDS+= llvm-config${LLVM_DEFAULT}:devel/llvm${LLVM_DEFAULT}
CONFIGURE_ENV+= LLVM_CONFIG=${LOCALBASE}/bin/llvm-config${LLVM_DEFAULT}
CONFIGURE_ARGS+= --with-llvm
PLIST_SUB+= LLVM=""
INSTALL_DIRS+= src/backend/jit/llvm
. else
PLIST_SUB+= LLVM="@comment "
CONFIGURE_ARGS+= --without-llvm

View File

@@ -1,3 +1,3 @@
TIMESTAMP = 1550095269
SHA256 (postgresql/postgresql-11.2.tar.bz2) = 2676b9ce09c21978032070b6794696e0aa5a476e3d21d60afc036dc0a9c09405
SIZE (postgresql/postgresql-11.2.tar.bz2) = 19714229
TIMESTAMP = 1557217836
SHA256 (postgresql/postgresql-11.3.tar.bz2) = 2a85e082fc225944821dfd23990e32dfcd2284c19060864b0ad4ca537d30522d
SIZE (postgresql/postgresql-11.3.tar.bz2) = 19718775

View File

@@ -47,6 +47,7 @@ stop_cmd="postgresql_command stop"
restart_cmd="postgresql_command restart"
reload_cmd="postgresql_command reload"
status_cmd="postgresql_command status"
promote_cmd="postgresql_command promote"
initdb_cmd="postgresql_initdb"

View File

@@ -45,6 +45,8 @@ lib/postgresql/utf8_and_sjis.so
lib/postgresql/utf8_and_sjis2004.so
lib/postgresql/utf8_and_uhc.so
lib/postgresql/utf8_and_win.so
%%LLVM%%lib/postgresql/llvmjit.so
%%LLVM%%lib/postgresql/llvmjit_types.bc
%%LLVM%%lib/postgresql/bitcode/postgres.index.bc
%%LLVM%%lib/postgresql/bitcode/postgres/access/brin/brin.bc
%%LLVM%%lib/postgresql/bitcode/postgres/access/brin/brin_inclusion.bc
@@ -750,6 +752,7 @@ lib/libpgcommon.a
%%NLS%%share/locale/es/LC_MESSAGES/pg_test_fsync-11.mo
%%NLS%%share/locale/es/LC_MESSAGES/pg_test_timing-11.mo
%%NLS%%share/locale/es/LC_MESSAGES/pg_waldump-11.mo
%%NLS%%share/locale/es/LC_MESSAGES/pg_upgrade-11.mo
%%NLS%%share/locale/es/LC_MESSAGES/plpgsql-11.mo
%%NLS%%share/locale/es/LC_MESSAGES/postgres-11.mo
%%NLS%%share/locale/fr/LC_MESSAGES/initdb-11.mo
@@ -865,9 +868,15 @@ lib/libpgcommon.a
%%NLS%%share/locale/vi/LC_MESSAGES/pg_waldump-11.mo
%%NLS%%share/locale/vi/LC_MESSAGES/plpgsql-11.mo
%%NLS%%share/locale/zh_CN/LC_MESSAGES/initdb-11.mo
%%NLS%%share/locale/zh_CN/LC_MESSAGES/pg_archivecleanup-11.mo
%%NLS%%share/locale/zh_CN/LC_MESSAGES/pg_basebackup-11.mo
%%NLS%%share/locale/zh_CN/LC_MESSAGES/pg_controldata-11.mo
%%NLS%%share/locale/zh_CN/LC_MESSAGES/pg_ctl-11.mo
%%NLS%%share/locale/zh_CN/LC_MESSAGES/pg_resetwal-11.mo
%%NLS%%share/locale/zh_CN/LC_MESSAGES/pg_rewind-11.mo
%%NLS%%share/locale/zh_CN/LC_MESSAGES/pg_test_fsync-11.mo
%%NLS%%share/locale/zh_CN/LC_MESSAGES/pg_test_timing-11.mo
%%NLS%%share/locale/zh_CN/LC_MESSAGES/pg_upgrade-11.mo
%%NLS%%share/locale/zh_CN/LC_MESSAGES/plpgsql-11.mo
%%NLS%%share/locale/zh_CN/LC_MESSAGES/postgres-11.mo
%%DATADIR%%/snowball_create.sql