From: cunha17 at uol dot com dot br Operating system: Redhat Linux 9.0 - Kernel 2.4.21 PHP version: 4.3.3RC3 PHP Bug Type: PostgreSQL related Bug description: pgsql causes segmentation fault
Description: ------------ I found out that pgsql functions cause segmentation fault if the connection user has no read access on pg_ system tables. I'm using John Lim's ADOdb class to access a PostgreSQL 7.2.4 database. This problem has nothing to do with apache since it happens with the CLI interface too. Reproduce code: --------------- With an empty postgresql installation, I created an empty database, connected to it, created an user and set all privileges on this new database to this user. Connected as the new user on the new database I created some tables. When trying to access this new tables with PHP and ADOdb classes, I got a segmentation fault. At the very end, when running with strace, I got a message before the segmentation fault saying: 'pg_class access denied' When I grant read access on this table to the new user, I got: 'pg_attribute access denied' and so on... When I grant read access to all pg_* tables, the problem disappear and PHP runs ok. Expected result: ---------------- PgSQL Error: Access denied to pg_* system table or something like that. Actual result: -------------- Segmentation Fault if the connection user has no read access on system tables -- Edit bug report at http://bugs.php.net/?id=25109&edit=1 -- Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=25109&r=trysnapshot4 Try a CVS snapshot (php5): http://bugs.php.net/fix.php?id=25109&r=trysnapshot5 Fixed in CVS: http://bugs.php.net/fix.php?id=25109&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=25109&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=25109&r=needtrace Try newer version: http://bugs.php.net/fix.php?id=25109&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=25109&r=support Expected behavior: http://bugs.php.net/fix.php?id=25109&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=25109&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=25109&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=25109&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=25109&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=25109&r=dst IIS Stability: http://bugs.php.net/fix.php?id=25109&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=25109&r=gnused
