aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
* Stamp releases notes for 8.2.3, 8.1.8, 8.0.12.REL8_1_8Bruce Momjian2007-02-07
|
* Fix wrong spacing (I think Bruce tried to hand-edit this instead of letting ↵Tom Lane2007-02-07
| | | | autoconf do it)
* Stamp releases 8.2.3, 8.1.8, 8.0.12. No release notes yet.Bruce Momjian2007-02-07
|
* Fix an error in the original coding of holdable cursors: PersistHoldablePortalTom Lane2007-02-06
| | | | | | | | | | | thought that it didn't have to reposition the underlying tuplestore if the portal is atEnd. But this is not so, because tuplestores have separate read and write cursors ... and the read cursor hasn't moved from the start. This mistake explains bug #2970 from William Zhang. Note: the coding here is pretty inefficient, but given that no one has noticed this bug until now, I'd say hardly anyone uses the case where the cursor has been advanced before being persisted. So maybe it's not worth worrying about.
* Remove typmod checking from the recent security-related patches. It turnsTom Lane2007-02-06
| | | | | | | | | | | | | out that ExecEvalVar and friends don't necessarily have access to a tuple descriptor with correct typmod: it definitely can contain -1, and possibly might contain other values that are different from the Var's value. Arguably this should be cleaned up someday, but it's not a simple change, and in any case typmod discrepancies don't pose a security hazard. Per reports from numerous people :-( I'm not entirely sure whether the failure can occur in 8.0 --- the simple test cases reported so far don't trigger it there. But back-patch the change all the way anyway.
* Backported va_list handling cleanupMichael Meskes2007-02-06
|
* Reword suggestion that libpq.dll be installed in WINNT\SYSTEM32 underNeil Conway2007-02-02
| | | | Windows. Per Magnus Hagander, this is not recommended.
* Stamp release 8.1.7.REL8_1_7Tom Lane2007-02-02
| | | | Security: CVE-2007-0555, CVE-2007-0556
* Update release notes for security-related releases in all active branches.Tom Lane2007-02-02
| | | | Security: CVE-2007-0555, CVE-2007-0556
* Repair failure to check that a table is still compatible with a previouslyTom Lane2007-02-02
| | | | | | | | | | | | | | | | | | | | | | made query plan. Use of ALTER COLUMN TYPE creates a hazard for cached query plans: they could contain Vars that claim a column has a different type than it now has. Fix this by checking during plan startup that Vars at relation scan level match the current relation tuple descriptor. Since at that point we already have at least AccessShareLock, we can be sure the column type will not change underneath us later in the query. However, since a backend's locks do not conflict against itself, there is still a hole for an attacker to exploit: he could try to execute ALTER COLUMN TYPE while a query is in progress in the current backend. Seal that hole by rejecting ALTER TABLE whenever the target relation is already open in the current backend. This is a significant security hole: not only can one trivially crash the backend, but with appropriate misuse of pass-by-reference datatypes it is possible to read out arbitrary locations in the server process's memory, which could allow retrieving database content the user should not be able to see. Our thanks to Jeff Trout for the initial report. Security: CVE-2007-0556
* Repair insufficiently careful type checking for SQL-language functions:Tom Lane2007-02-02
| | | | | | | | | | | | | | | | we should check that the function code returns the claimed result datatype every time we parse the function for execution. Formerly, for simple scalar result types we assumed the creation-time check was sufficient, but this fails if the function selects from a table that's been redefined since then, and even more obviously fails if check_function_bodies had been OFF. This is a significant security hole: not only can one trivially crash the backend, but with appropriate misuse of pass-by-reference datatypes it is possible to read out arbitrary locations in the server process's memory, which could allow retrieving database content the user should not be able to see. Our thanks to Jeff Trout for the initial report. Security: CVE-2007-0555
* Translation updatesPeter Eisentraut2007-01-31
|
* Repair oversights in the mechanism used to store compiled plpgsql functions.Tom Lane2007-01-30
| | | | | | | | | | | | | The original coding failed (tried to access deallocated memory) if there were two active call sites (fn_extra pointers) for the same function and the function definition was updated. Also, if an update of a recursive function was detected upon nested entry to the function, the existing compiled version was summarily deallocated, resulting in crash upon return to the outer instance. Problem observed while studying a bug report from Sergiy Vyshnevetskiy. Bug does not exist before 8.1 since older versions just leaked the memory of obsoleted compiled functions, rather than trying to reclaim it.
* Add SPI_push/SPI_pop calls so that datatype input and output functions calledTom Lane2007-01-30
| | | | | | | | | by plpgsql can themselves use SPI --- possibly indirectly, as in the case of domain_in() invoking plpgsql functions in a domain check constraint. Per bug #2945 from Sergiy Vyshnevetskiy. Somewhat arbitrarily, I've chosen to back-patch this as far as 8.0. Given the lack of prior complaints, it doesn't seem critical for 7.x.
* Correct an old logic error in btree page splitting: when considering a splitTom Lane2007-01-27
| | | | | | | | | | | | exactly at the point where we need to insert a new item, the calculation used the wrong size for the "high key" of the new left page. This could lead to choosing an unworkable split, resulting in "PANIC: failed to add item to the left sibling" (or "right sibling") failure. Although this bug has been there a long time, it's very difficult to trigger a failure before 8.2, since there was generally a lot of free space on both sides of a chosen split. In 8.2, where the user-selected fill factor determines how much free space the code tries to leave, an unworkable split is much more likely. Report by Joe Conway, diagnosis and fix by Heikki Linnakangas.
* Back-port changes of Jan 16 and 17 to "revoke" pending fsync requests duringTom Lane2007-01-27
| | | | | | | | | DROP TABLE and DROP DATABASE. Should prevent unexpected "permission denied" failures on Windows, and is cleaner on other platforms too since we no longer have to take it on faith that ENOENT is okay during an fsync attempt. Patched as far back as 8.1; per recent discussion I think we are not going to worry about Windows-specific issues in 8.0 anymore.
* Get pg_utf_mblen(), pg_utf2wchar_with_len(), and utf2ucs() all on the sameTom Lane2007-01-24
| | | | | | | | | | | | | | | | | | | | | page about the maximum UTF8 sequence length we support (4 bytes since 8.1, 3 before that). pg_utf2wchar_with_len never got updated to support 4-byte characters at all, and in any case had a buffer-overrun risk in that it could produce multiple pg_wchars from what mblen claims to be just one UTF8 character. The only reason we don't have a major security hole is that most callers allocate worst-case output buffers; the sole exception in released versions appears to be pre-8.2 iwchareq() (ie, ILIKE), which can be crashed due to zeroing out its return address --- but AFAICS that can't be exploited for anything more than a crash, due to inability to control what gets written there. Per report from James Russell and Michael Fuhr. Pre-8.1 the risk is much less, but I still think pg_utf2wchar_with_len's behavior given an incomplete final character risks buffer overrun, so back-patch that logic change anyway. This patch also makes sure that UTF8 sequences exceeding the supported length (whichever it is) are consistently treated as error cases, rather than being treated like a valid shorter sequence in some places.
* Relax an Assert() that has been found to be too strict in some situationsTom Lane2007-01-24
| | | | | | | involving unions of types having typmods. Variants of the failure are known to occur in 8.1 and up; not sure if it's possible in 8.0 and 7.4, but since the code exists that far back, I'll just patch 'em all. Per report from Brian Hurt.
* Correct a minor inaccuracy in the pg_dumpall reference page: -g dumpsNeil Conway2007-01-15
| | | | | | roles and tablespaces, no longer users and groups. Per Dave Page. Backport to 8.2 and 8.1.
* Fix autovacuum to avoid leaving non-permanent Xids in non-connectableAlvaro Herrera2007-01-14
| | | | | | | databases. Apply to the 8.1 branch only, as the new 8.2 (and HEAD) coding does not have this problem.
* Fix a performance problem in databases with large numbers of tablesTom Lane2007-01-11
| | | | | | | | | | | (or other types of pg_class entry): the function pgstat_vacuum_tabstat, invoked during VACUUM startup, had runtime proportional to the number of stats table entries times the number of pg_class rows; in other words O(N^2) if the stats collector's information is reasonably complete. Replace list searching with a hash table to bring it back to O(N) behavior. Per report from kim at myemma.com. Back-patch as far as 8.1; 8.0 and before use different coding here.
* Back port patch.Tatsuo Ishii2007-01-10
| | | | | | | | Call srandom() instead of srand(). pgbench calls random() later, so it should have called srandom(). On most platforms except Windows srandom() is actually identical to srand(), so the bug only bites Windows users. per bug report from Akio Ishida.
* Links to GUC variables from HISTORY don't work in back branches...REL8_1_6Tom Lane2007-01-06
|
* tag 8.1.6PostgreSQL Daemon2007-01-06
|
* Fix markup because older releases couldn't link to the reference section.Bruce Momjian2007-01-06
|
* Minor copy-editing for release note updates.Tom Lane2007-01-05
|
* Stamp release 8.1.6.Bruce Momjian2007-01-05
|
* Create release notes for 8.1.6.Bruce Momjian2007-01-05
|
* Fix regex_fixed_prefix() to cope reasonably well with regex patterns of theTom Lane2007-01-03
| | | | | | | | | | form '^(foo)$'. Before, these could never be optimized into indexscans. The recent changes to make psql and pg_dump generate such patterns (for \d commands and -t and related switches, respectively) therefore represented a big performance hit for people with large pg_class catalogs, as seen in recent gripe from Erik Jones. While at it, be more paranoid about case-sensitivity checking in multibyte encodings, and fix some other corner cases in which a regex might be interpreted too liberally.
* Modify local buffer management to request memory for local buffers in blocksTom Lane2006-12-27
| | | | | | | | | | | of increasing size, instead of one at a time. This reduces the memory management overhead when num_temp_buffers is large: in the previous coding we would actually waste 50% of the space used for temp buffers, because aset.c would round the individual requests up to 16K. Problem noted while studying a performance issue reported by Steven Flatt. Back-patch as far as 8.1 --- older versions used few enough local buffers that the issue isn't significant for them.
* Repair bug #2839: the various ExecReScan functions need to resetTom Lane2006-12-26
| | | | | | | | | ps_TupFromTlist in plan nodes that make use of it. This was being done correctly in join nodes and Result nodes but not in any relation-scan nodes. Bug would lead to bogus results if a set-returning function appeared in the targetlist of a subquery that could be rescanned after partial execution, for example a subquery within EXISTS(). Bug has been around forever :-( ... surprising it wasn't reported before.
* Fix convertion for 'PFX flag N num'Teodor Sigaev2006-12-21
|
* Document the recently-understood hazard that a rollback can release row-levelTom Lane2006-12-01
| | | | | | locks that logically should not be released, because when a subtransaction overwrites XMAX all knowledge of the previous lock state is lost. It seems unlikely that we will be able to fix this before 8.3...
* Update timezone data to tzdata2006p zic distribution. It seems WesternTom Lane2006-11-28
| | | | | Australia decided to institute DST with one month's notice ... way to go, politicians.
* Mark to_number() and the numeric-type variants of to_char() as stable, notTom Lane2006-11-28
| | | | | | immutable, because their results depend on lc_numeric; this is a longstanding oversight. We cannot force initdb for this in the back branches, but we can at least provide correct catalog entries for future installations.
* Back-patch HEAD's fixes to recognize __ppc64__ as equivalent to __powerpc64__.Tom Lane2006-11-28
| | | | | Per confirmation from Brian Wipf that this is correct and necessary for Darwin 64-bit.
* Add $(CFLAGS) to the simplified build rule for .so libraries on Darwin.Tom Lane2006-11-28
| | | | | | Arguably we should do this on *all* platforms, but for the moment I'll be conservative and just do it where it's demonstrably needed. Per report from Brian Wipf.
* Fix psql's \copy command to ensure that it cycles libpq back to the idle stateTom Lane2006-11-24
| | | | | | | | | (in particular, causing the ReadyForQuery message to be eaten) before returning from do_copy. The only known consequence of failing to do so is that get_prompt might show a wrong result for the %x transaction status escape, as reported by Bernd Helmle; but it's possible there are other issues. Back-patch as far as 7.4, the oldest version supporting %x.
* Add release entry for 8.1.5 that was missing:Bruce Momjian2006-11-23
| | | | <listitem><para>Fix rare bug in continuous archiving (Tom)</para></listitem>
* Fix 1-byte buffer overrun when OID exceeds 1 billion. This probably can'tTom Lane2006-11-22
| | | | | | cause any serious harm in normal cases, but if you have gcc buffer overrun checking turned on, that will notice. Found by Jack Orenstein. Problem was already fixed in CVS HEAD.
* When truncating a relation in-place (eg during VACUUM), do not try to unlinkTom Lane2006-11-20
| | | | | | | | | | | | | any no-longer-needed segments; just truncate them to zero bytes and leave the files in place for possible future re-use. This avoids problems when the segments are re-used due to relation growth shortly after truncation. Before, the bgwriter, and possibly other backends, could still be holding open file references to the old segment files, and would write dirty blocks into those files where they'd disappear from the view of other processes. Back-patch as far as 8.0. I believe the 7.x branches are not vulnerable, because they had no bgwriter, and "blind" writes by other backends would always be done via freshly-opened file references.
* Repair problems with hash indexes that span multiple segments: the hash code'sTom Lane2006-11-19
| | | | | | | | | | | | | | | | | | preference for filling pages out-of-order tends to confuse the sanity checks in md.c, as per report from Balazs Nagy in bug #2737. The fix is to ensure that the smgr-level code always has the same idea of the logical EOF as the hash index code does, by using ReadBuffer(P_NEW) where we are adding a single page to the end of the index, and using smgrextend() to reserve a large batch of pages when creating a new splitpoint. The patch is a bit ugly because it avoids making any changes in md.c, which seems the most prudent approach for a backpatchable beta-period fix. After 8.3 development opens, I'll take a look at a cleaner but more invasive patch, in particular getting rid of the now unnecessary hack to allow reading beyond EOF in mdread(). Backpatch as far as 7.4. The bug likely exists in 7.3 as well, but because of the magnitude of the 7.3-to-7.4 changes in hash, the later-version patch doesn't even begin to apply. Given the other known bugs in the 7.3-era hash code, it does not seem worth trying to develop a separate patch for 7.3.
* Repair two related errors in heap_lock_tuple: it was failing to recognizeTom Lane2006-11-17
| | | | | | | | | cases where we already hold the desired lock "indirectly", either via membership in a MultiXact or because the lock was originally taken by a different subtransaction of the current transaction. These cases must be accounted for to avoid needless deadlocks and/or inappropriate replacement of an exclusive lock with a shared lock. Per report from Clarence Gardner and subsequent investigation.
* Applied patch by Peter Harris to free auto_mem struct in ECPGconnect.Michael Meskes2006-11-08
|
* Repair bug #2694 concerning an ARRAY[] construct whose inputs are emptyTom Lane2006-11-06
| | | | | | | | | | sub-arrays. Per discussion, if all inputs are empty arrays then result must be an empty array too, whereas a mix of empty and nonempty arrays should (and already did) draw an error. In the back branches, the construct was strict: any NULL input immediately yielded a NULL output; so I left that behavior alone. HEAD was simply ignoring NULL sub-arrays, which doesn't seem very sensible. For lack of a better idea it now treats NULL sub-arrays the same as empty ones.
* Fix recently-identified PITR recovery hazard: the base backup could containTom Lane2006-11-05
| | | | | | | | | | | | | stale relcache init files (pg_internal.init), and there is no mechanism for updating them during WAL replay. Easiest solution is just to delete the init files at conclusion of startup, and let the first backend started in each database take care of rebuilding the init file. Simon Riggs and Tom Lane. Back-patched to 8.1. Arguably this should be fixed in 8.0 too, but it would require significantly more code since 8.0 has no handy startup-time scan of pg_database to piggyback on. Manual solution of the problem is possible in 8.0 (just delete the pg_internal.init files before starting WAL replay), so that may be a sufficient answer.
* Correct documentation error: in 8.1 and 8.2, %p in archive and restoreTom Lane2006-11-04
| | | | | | command strings inserts relative not absolute path of file to process. This is a side-effect of 2005-07-04 change that makes the server use relative paths in general. Noted by Bernd Helmle.
* Fix "failed to re-find parent key" btree VACUUM failure by tweakingTom Lane2006-11-01
| | | | | | | | | _bt_pagedel to recover from the failure: just search the whole parent level if searching to the right fails. This does nothing for the underlying problem that index keys became out-of-order in the grandparent level. However, we believe that there is no other consequence worse than slightly inefficient searching, so this narrow patch seems like the safest solution for the back branches.
* pg_restore failed on tar-format archives if they contained large objectsTom Lane2006-11-01
| | | | | | (blobs) with comments, per bug #2727 from Konstantin Pelepelin. Mea culpa for not having tested this case. Back-patch to 8.1; prior branches don't dump blob comments at all.
* Back-patch second version of AIX getaddrinfo fix.Tom Lane2006-10-20
|