Return-Path: Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: (qmail 87764 invoked from network); 16 Dec 2005 19:50:28 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 16 Dec 2005 19:50:28 -0000 Received: (qmail 48370 invoked by uid 500); 16 Dec 2005 19:50:27 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 48331 invoked by uid 500); 16 Dec 2005 19:50:27 -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 48306 invoked by uid 99); 16 Dec 2005 19:50:27 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 16 Dec 2005 11:50:27 -0800 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: domain of francois.orsini@gmail.com designates 64.233.162.207 as permitted sender) Received: from [64.233.162.207] (HELO zproxy.gmail.com) (64.233.162.207) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 16 Dec 2005 11:50:25 -0800 Received: by zproxy.gmail.com with SMTP id 9so779700nzo for ; Fri, 16 Dec 2005 11:50:04 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; b=UGY6cA1xPlkXjHUkqFaEpGLMI1IaqIz83g2QW2HZojDxe+wFl4qwiOnXfobN4r6krIVl4qHkN57RAIzemPXeYnf8+PmzZcZVC8ppxo0Ta9rEgDjjLRGaLZpQ1Padm8F24T0qMVso90jhzksS2M5jtxOwxlMQZhR9hnpNdYKVxxg= Received: by 10.65.35.12 with SMTP id n12mr143063qbj; Fri, 16 Dec 2005 11:50:04 -0800 (PST) Received: by 10.64.209.10 with HTTP; Fri, 16 Dec 2005 11:50:04 -0800 (PST) Message-ID: <7921d3e40512161150u5351ff3fpefde04498dcb919c@mail.gmail.com> Date: Fri, 16 Dec 2005 11:50:04 -0800 From: Francois Orsini To: derby-dev@db.apache.org Subject: Re: [jira] Commented: (DERBY-464) Enhance Derby by adding grant/revoke support. Grant/Revoke provide finner level of privileges than currently provided by Derby that is especially useful in network configurations. In-Reply-To: <43A30C6F.8020504@Sourcery.Org> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_8625_14787887.1134762604149" References: <1439014097.1121475009861.JavaMail.jira@ajax.apache.org> <2047748888.1134361750083.JavaMail.jira@ajax.apache.org> <7921d3e40512152023x3e321809p1ca9258aaddf91d7@mail.gmail.com> <43A30C6F.8020504@Sourcery.Org> X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N ------=_Part_8625_14787887.1134762604149 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Thanks Satheesh - much appreciated ;) On 12/16/05, Satheesh Bandaram wrote: > > Hi Francois, > > I will update functional specification with system table schema. I will > also add a high level design section there with some details. I am little > pressed for time right now, but will get this out next week. (happens to = be > my off week, but open source world never sleeps, right?) > > Satheesh > > Francois Orsini wrote: > > Hi Satheesh, > > I'm reviewing the part I changes you checked-in - there is a lot of > changes and it is somewhat tedious to understand some of the decisions th= at > have been made at the implementation level - not saying anything is wrong= - > it is just hard to follow certain paths without a minimum of high-level > technical details about the implementation (i.e. design specs) and mostly > because of the amount of changes - there are classes without headers, whi= ch > makes it difficult to understand the purpose of a class - sure, one can > always spend a long time trying to understand things but I think for patc= hes > with such amount of changes, some high-level design details would be > appreciated by the reviewers...I know you intended to post details about = the > system catalogs but right now one has to review the changes without a lot= of > details besides the functional specs...a 1-2 pager high-level implementat= ion > details would not just help reviewers to do a better appreciation of the > changes but also incentivize more reviewers to look at the changes... > > Btw, these changes cross a few of the Derby subsystems and am hoping > someone can review the query tree and nodes generation (compiler) stuffs.= .. > > Thanks, > > --francois > > On 12/11/05, Satheesh Bandaram (JIRA) wrote: > > > > [ > > http://issues.apache.org/jira/browse/DERBY-464?page=3Dcomments#action_1= 2360186] > > > > Satheesh Bandaram commented on DERBY-464: > > ----------------------------------------- > > > > I have submitted Grant and Revoke, Part I to trunk. Let me know if > > anyone would like to join developing remaining parts. It is possible to > > coordinate development using a Wiki. > > > > This Phase I implements: > > > > * Grant/Revoke DDL parsing and execution > > * Addition of several new system tables to hold the system metadata. = I > > will update my spec to include detailed schema for new system tables, s= o > > that they can be included in 10.2 documentation. > > * Enhancing the syntax for routine creation to include > > external-security clause > > * Very simple tests to cover only the DDL. I would be expanding on > > the testing in the later submissions, including a JUnit test suite. > > * Grant/Revoke DDL is only supported if > > derby.database.defaultConnectionMode property is set to 'sqlStandard'. > > > > Pending items from Phase I: > > > > 1. dblook needs to be enhanced to emit DDL for grant statements. > > 2. Enhanced JUnit based test suite with many more tests. > > 3. Some implementation improvements possible with the current patch. > > It should be possible to combine several new nodes being added, to redu= ce > > number of nodes and hence foot print. Also, the patch adds a Java objec= t to > > new system tables. While Derby already has some java objects in its sys= tem > > tables, I think, we should discourage adding new java objects to catalo= gs. > > Since Java objects can't be used in SQL easily, this makes metadata har= der > > to use. I will explore rewriting SYSCOLPERMS and SYSREQUIREDPERM to not= use > > FormattableBitSet type. This can be done by having multiple entries in = these > > catalogs for each column referenced. > > 4. Updating specification to include schema for new system tables. > > 5. Need to change how property defaultConnectionMode is set and/or > > used. > > 6. Enhance system tables to store external security clause > > specification. > > > > I am also working on Grant and Revoke, Phase II. This will implement > > permission checking for DML statement. Hopefully I will have something = to > > submit by end of January to complete Phase I and Phase II. > > > > Also need to support upgrade and migration of legacy databases and > > update JDBC metadata. > > > > Let me know if I missed anything else. > > > > > > > Enhance Derby by adding grant/revoke support. Grant/Revoke provide > > finner level of privileges than currently provided by Derby that is > > especially useful in network configurations. > > > > > -----------------------------------------------------------------------= ---------------------------------------------------------------------------= --------------------------------- > > > > > > > > Key: DERBY-464 > > > URL: http://issues.apache.org/jira/browse/DERBY-464 > > > Project: Derby > > > Type: New Feature > > > Components: SQL > > > Versions: 10.0.2.1, 10.1.1.0, 10.2.0.0 > > > Environment: generic > > > Reporter: Satheesh Bandaram > > > Assignee: Satheesh Bandaram > > > Attachments: grant.html, grantRevoke.patch.Dec5, > > grantRevoke.stat.Dec5 > > > > > > Derby currently provides a very simple permissions scheme, which is > > quite suitable for an embedded database system. End users of embedded D= erby > > do not see Derby directly; they talk to a application that embeds Derby= . So > > Derby left most of the access control work to the application. Under th= is > > scheme, Derby limits access on a per database or per system basis. A us= er > > can be granted full, read-only, or no access. > > > This is less suitable in a general purpose SQL server. When end users > > or diverse applications can issue SQL commands directly against the > > database, Derby must provide more precise mechanisms to limit who can d= o > > what with the database. > > > I propose to enhance Derby by implementing a subset of grant/revoke > > capabilities as specified by the SQL standard. I envision this work to > > involve the following tasks, at least: > > > 1) Develop a specification of what capabilities I would like to add t= o > > Derby. > > > 2) Provide a high level implementation scheme. > > > 3) Pursue a staged development plan, with support for DDL added to > > Derby first. > > > 4) Add support for runtime checking of these privileges. > > > 5) Address migration and upgrade issues from previous releases and > > from old scheme to newer database. > > > Since I think this is a large task, I would like to invite any > > interested people to work with me on this large and important enhanceme= nt to > > Derby. > > > > -- > > 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 > > > > > ------=_Part_8625_14787887.1134762604149 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Thanks Satheesh - much appreciated ;)

On 12/16/05, Satheesh Bandaram <satheesh@sourcery.org> wrote:<= /span>
=20 =20 Hi Francois,

I will update functional specification with system table schema. I will also add a high level design section there with some details. I am little pressed for time right now, but will get this out next week. (happens to be my off week, but open source world never sleeps, right?)
=
Satheesh


Francois Orsini wrote:
Hi Satheesh,

I'm reviewing the part I changes you checked-in - there is a lot of changes and it is somewhat tedious to understand some of the decisions that have been made at the implementation level - not saying anything is wrong - it is just hard to follow certain paths without a minimum of high-level technical details about the implementation (i.e. design specs) and mostly because of the amount of changes - there are classes without headers, which makes it difficult to understand the purpose of a class - sure, one can always spend a long time trying to understand things but I think for patches with such amount of changes, some high-level design details would be appreciated by the reviewers...I know you intended to post details about the system catalogs but right now one has to review the changes without a lot of details besides the functional specs...a 1-2 pager high-level implementation details would not just help reviewers to do a better appreciation of the changes but also incentivize more reviewers to look at the changes...

Btw, these changes cross a few of the Derby subsystems and am hoping someone can review the query tree and nodes generation (compiler) stuffs...

Thanks,

--francois

On 12/11/05, Satheesh Bandaram (JIRA) <derby-dev@db.apache.org > wrote:
  &nb= sp; [ http://issues.apache.org/jira/browse/DERBY-464?page=3Dc= omments#action_12360186 ]

Satheesh Bandaram commented on DERBY-464:
-----------------------------------------

I have submitted Grant and Revoke, Part I to trunk. Let me know if anyone would like to join developing remaining parts. It is possible to coordinate development using a Wiki.

This Phase I implements:

  * Grant/Revoke DDL parsing and execution
  * Addition of several new system tables to hold the system metadata. I will update my spec to include detailed schema for new system tables, so that they can be included in 10.2 documentation.
  *  Enhancing the syntax for routine creation to inclu= de external-security clause
  *  Very simple tests to cover only the DDL. I would be expanding on the testing in the later submissions, including a JUnit test suite.
  * Grant/Revoke DDL is only supported if derby.database.defaultConnectionMode property is set to 'sqlStandard'.

Pending items from Phase I:

   1. dblook needs to be enhanced to emit DDL for grant statement= s.
   2. Enhanced JUnit based test suite with many more tests.
   3. Some implementation improvements possible with the current patch. It should be possible to combine several new nodes being added, to reduce number of nodes and hence foot print. Also, the patch adds a Java object to new system tables. While Derby already has some java objects in its system tables, I think, we should discourage adding new java objects to catalogs. Since Java objects can't be used in SQL easily, this makes metadata harder to use. I will explore rewriting SYSCOLPERMS and SYSREQUIREDPERM to not use FormattableBitSet type. This can be done by having multiple entries in these catalogs for each column referenced.    4. Updating specification to include schema for new system tab= les.
   5. Need to change how property defaultConnectionMode is set an= d/or used.
   6. Enhance system tables to store external security clause specification.

I am also working on Grant and Revoke, Phase II. This will implement permission checking for DML statement. Hopefully I will have something to submit by end of January to complete Phase I and Phase II.

Also need to support upgrade and migration of legacy databases and update JDBC metadata.

Let me know if I missed anything else.


> Enhance Derby by adding grant/revoke support. Grant/Revoke provide finner level of privileges than currently provided by Derby that is especially useful in network configurations.
> ---------------------------------------------------------------------------= ---------------------------------------------------------------------------= -----------------------------
>
>          Key: DERBY-= 464
>          URL: http://issues.apache.o= rg/jira/browse/DERBY-464
>      Project: Derby
>         Type: New Feature
>   Components: SQL
>     Versions: 10.0.2= .1, 10.1.1.0, 10.2.0.0
>  Environment: generic
>     Reporter: Satheesh Bandaram
>     Assignee: Satheesh Bandaram
>  Attachments: grant.html, grantRevoke.patch.Dec5, grantRevoke.stat.Dec5
>
> Derby currently provides a very simple permissions scheme, which is quite suitable for an embedded database system. End users of embedded Derby do not see Derby directly; they talk to a application that embeds Derby. So Derby left most of the access control work to the application. Under this scheme, Derby limits access on a per database or per system basis. A user can be granted full, read-only, or no access.
> This is less suitable in a general purpose SQL server. When end users or diverse applications can issue SQL commands directly against the database, Derby must provide more precise mechanisms to limit who can do what with the database.
> I propose to enhance Derby by implementing a subset of grant/revoke capabilities as specified by the SQL standard. I envision this work to involve the following tasks, at least:
> 1) Develop a specification of what capabilities I would like to add to Derby.
> 2) Provide a high level implementation scheme.
> 3) Pursue a staged development plan, with support for DDL added to Derby first.
> 4) Add support for runtime checking of these privileges.
> 5) Address migration and upgrade issues from previous releases and from old scheme to newer database.
> Since I think this is a large task, I would like to invite any interested people to work with me on this large and important enhancement to Derby.

--
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



------=_Part_8625_14787887.1134762604149--