Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 61434 invoked from network); 27 Jul 2010 09:25:45 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 27 Jul 2010 09:25:45 -0000 Received: (qmail 510 invoked by uid 500); 27 Jul 2010 09:25:45 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 306 invoked by uid 500); 27 Jul 2010 09:25:43 -0000 Mailing-List: contact derby-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: Delivered-To: mailing list derby-dev@db.apache.org Received: (qmail 287 invoked by uid 99); 27 Jul 2010 09:25:41 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 27 Jul 2010 09:25:41 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 27 Jul 2010 09:25:39 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id o6R9PHVB000965 for ; Tue, 27 Jul 2010 09:25:17 GMT Message-ID: <3077985.20281280222717670.JavaMail.jira@thor> Date: Tue, 27 Jul 2010 05:25:17 -0400 (EDT) From: "Kristian Waagan (JIRA)" To: derby-dev@db.apache.org Subject: [jira] Commented: (DERBY-4551) Allow database user to execute stored procedures with same permissions as database owner and/or routine definer In-Reply-To: <1760926860.327031266376467896.JavaMail.jira@brutus.apache.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/DERBY-4551?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12892702#action_12892702 ] Kristian Waagan commented on DERBY-4551: ---------------------------------------- Thanks for the repro, Thomas. I think Dag is on vacation (as many others in the community), so unless someone else feels the itch it may take a while before this issue is cleared up (sounds like more investigation is needed). > Allow database user to execute stored procedures with same permissions as database owner and/or routine definer > --------------------------------------------------------------------------------------------------------------- > > Key: DERBY-4551 > URL: https://issues.apache.org/jira/browse/DERBY-4551 > Project: Derby > Issue Type: Improvement > Components: SQL > Affects Versions: 10.5.3.0 > Reporter: Tushar Kale > Assignee: Dag H. Wanvik > Attachments: definers_rights.html, definers_rights.html, definers_rights.html, definers_rights.html, definers_rights.html, definers_rights.html, definers_rights.html, definers_rights_typos-1.diff, derby-4551-1.diff, derby-4551-1.stat, derby-4551-1.txt, derby-4551-2.diff, derby-4551-2.stat, derby-4551-3.diff, derby-4551-3.stat, derby-4551-3b.diff, derby-4551-3b.stat, derby-4551-4.diff, derby-4551-4.stat, reproTH-derby-4551.7z > > > Curretnly there is no way to hide data and database structure in embedded derby from the end user. > One way to accomplish the above requirement is as follows: > 1. Create encrypted database so data is protected > 2. Enable authentication and sql authorization in database > 3. Create two users, dbUser and dbOwner > 4. Store application logic as stored procedure in the databse so dbUser does not know what tables are accecced by the application logic, thus hiding table structure > 5. Revoke select permission from dbUser so he cannot describe tables thus protecting table structures > 6. Give only Execute permissions on stored procedures to dbUser > The above steps will ensure that data and data structure is hidden when application is delivered to end user. > The problem is, if user does not have select permission, the stored procedures will not execute. So I am requesting the following enhancement to Derby: > If dbOwner has given Execure permission to stored procecure to a dbUser, then allow stored procedure to execute even if the dbUser has no select permission. > In otherwords, When dbUser calls stored procedure, database will use dbOwners authorization to execute stored procedure rather than dbUsers. > This may be implemented by creating new permission called RunAsDbOwner. > DbOwner can then grant permission to dbUser to execute a stored procedure with RunAsDbOwner. > If this is implemented, applications can be created which will truely hide the database structure and data from end users. Database will behave as a blackbox with only in/out data exposed in stored procedures. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.