|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2009-01-05 01:58 UTC] abhargav at in dot ibm dot com
[2009-01-05 12:47 UTC] rod at zend dot com
[2009-01-12 13:41 UTC] rod at zend dot com
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Oct 27 16:00:01 2025 UTC |
Description: ------------ A user profile is not allowed to access a table when a group profile is used to grant that user profile authority to access the table. However, the user profile can access the table in a SQL Interactive Session. Reproduce code: --------------- <?php $i5 = db2_connect("", "", ""); if (!$i5) die(db2_conn_errormsg()); $result = db2_exec($i5,"select * from qgpl.qordhdr"); if (!$result) die(db2_stmt_errormsg()); else echo "Connected OK"; db2_close($i5); ?> Expected result: ---------------- Given that table qgpl.qordhdr has *PUBLIC *EXCLUDE and NOGROUP *USE authorities, the above script should output "Connected OK." Actual result: -------------- Given that table qgpl.qordhdr has *PUBLIC *EXCLUDE and NOGROUP *USE authorities, the above script instead outputs "Not authorized to object QORDHDR in QGPL type *FILE. SQLCODE=-551" If you modify user profile NOBODY to allow sign on, you can sign on to a 5250 session as NOBODY, execute the STRSQL command, and successfully run the statement "select * from qgpl.qordhdr" (provided SQL Naming is used). If you specifically grant *USE authority to user NOBODY for the table, the script will run. However, this should not be necessary, as user NOBODY is part of group NOGROUP, and simply authorizing NOGROUP allows a successful select statement in the SQL Interactive Session.