[ http://issues.apache.org/jira/browse/DERBY-1582?page=all ]

Deepa Remesh updated DERBY-1582:
--------------------------------

    Attachment: d1582_v1.diff
                d1582_v1.status

Attaching a patch 'd1582_v1.diff' which raises a warning when no privileges are 
revoked by the revoke statement.

This patch adds checks for revoke of table and routine permissions. It checks 
return value of DataDictionary.addRemovePermissionsDescriptor method which 
returns true if revoke has removed a privilege. The new SQLState and warning 
added are:
WARNING 01006: Privilege not revoked.
Tests are in lang/grantRevokeDDL.sql.

It is not very clear to me from the spec how the following case should be 
handled - revoking permissions from dba (user who is the owner of the 
database). dba has "implicit" permissions on all objects and we cannot revoke 
privileges from dba. With the current patch we will get the above warning when 
we revoke any privilge from dba. I am thinking this behaviour is okay. It would 
be helpful if someone can confirm this.

I am running derbyall with the patch now. Meantime, any feedback is appreciated.

> REVOKE statement does not generate a warning when no privileges are revoked.
> ----------------------------------------------------------------------------
>
>                 Key: DERBY-1582
>                 URL: http://issues.apache.org/jira/browse/DERBY-1582
>             Project: Derby
>          Issue Type: Bug
>          Components: SQL
>    Affects Versions: 10.2.0.0
>            Reporter: Daniel John Debrunner
>         Attachments: d1582_v1.diff, d1582_v1.status
>
>
> SQL 2003 standard, section 12.7 <revoke statement>, item 17 under general 
> rules indicates the statement completes with the condition 'warning ? 
> privilege not revoked.' when no matching privilege is revoked.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to