[Zope-CMF] Delete (and edit) permissions within portal folders...

Andy Bramah andrewbramah@yahoo.co.uk
Sat, 27 Jul 2002 01:38:29 +1100


Florent,

I have had a play round with a million check boxes and have found...

...you are right - like you say, I need a 'BeforeDeleteException' which says
something like "yes, you have permission to delete within this folder, but
you do not own the content you are trying to delete, so NO!!!!!!!!!".

I'm sure I can't be the only one trying for the same, so I'll have a look
round later for some specialised permissions...

>From what I can see, the security within Zope is based strongly around what
your role is, and less priority is given to the object.

Objects have rights too!!!!!

Content should have permissions, as well as *containers*.

Disco Infernos has made me far too boozed - must sleeeeeeeep.

Bit drunk,
Andy.

-----Original Message-----
From: zope-cmf-admin@zope.org [mailto:zope-cmf-admin@zope.org]On Behalf Of
Florent Guillaume
Sent: 27 July 2002 03:57
To: zope-cmf@zope.org
Subject: Re: [Zope-CMF] Delete (and edit) permissions within portal
folders...

Sidnei da Silva  <sidnei@x3ng.com.br> wrote:
> You must give the 'Delete object' permission to owner and give the user a
> local role of owner on the objects you want them to be able to delete.

It doesn't work like that. The 'Delete object' permission is a
permission on the *container*, not the content.

The only way to do what you want is to have the content objects derive
from a class that has a manage_beforeDelete that checks deletability and
raises a BeforeDeleteException if it's not ok.

But beware, that can render certain objects or containers undeletable
even by Manager if it's not done correctly.

Florent

--
Florent Guillaume, Nuxeo (Paris, France)
+33 1 40 33 79 87  http://nuxeo.com  mailto:fg@nuxeo.com

_______________________________________________
Zope-CMF maillist  -  Zope-CMF@zope.org
http://lists.zope.org/mailman/listinfo/zope-cmf

See http://collector.zope.org/CMF for bug reports and feature requests

__________________________________________________
Do You Yahoo!?
Everything you'll ever need on one web page
from News and Sport to Email and Music Charts
http://uk.my.yahoo.com