You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lenya.apache.org by Doug Chestnut <dh...@virginia.edu> on 2005/08/23 17:38:51 UTC

create publication from template

Hi Devs,
is there a way to restrict access to the 
publication.createPublicationFromTemplate usecase in 1.4 by user/group? 
  Seems like the only way would be to remove it when not needed since it 
is outside of the publication context (where users/groups exist).

Thanks,
--Doug

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org


Re: create publication from template

Posted by Andreas Hartmann <an...@apache.org>.
Andreas Hartmann wrote:

[...]

> - Remove the original usecase from cocoon.xconf

BTW, this can be done using an XPatch file with a @remove attribute.

-- Andreas


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org


Re: create publication from template

Posted by Andreas Hartmann <an...@apache.org>.
Doug Chestnut wrote:
> Hi Devs,
> is there a way to restrict access to the 
> publication.createPublicationFromTemplate usecase in 1.4 by user/group? 
>  Seems like the only way would be to remove it when not needed since it 
> is outside of the publication context (where users/groups exist).

A secure way would be the following:

- Override the usecase handler with a custom usecase handler which checks
   if it is invoked from inside a publication

- Set the appropriate permissions in usecase-policies.xml

- Add the menu item if desired

- Remove the original usecase from cocoon.xconf


This way, you can be sure that new publications can only be created
by particular users / groups.

-- Andreas


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org