bgrant wrote on Thu, 08 September 2011 15:04
> No real user is created when you enable the Guest user,
> so you can't assign Guest or Anonymous directly to have
> access rights. As the URL ( 
> http://doc.nuxeo.com/display/KB/How+to+create+web+pages+view
> able+by+anonymous+users) says, you need to set the read
> permission at the Default Domain level - this gives the
> anonymous user read access to the repository. You can then
> create action contributions to control what further rights
> the virtual Guest (anonymous user) will have. As the URL
> suggests, create a filter like...
> 
> <filter id="anonymous">
>       <rule grant="true">
>               <condition>#{currentUser.anonymous}</condition>
>       </rule>
> </filter>
> 
> in your actions contrib xml (ActionServer/actions) and
> then use the filter to further refine what the anonymous
> user can access, for example
> 
> <action id="login" link="logout" label="command.login">
>       <category>USER_SERVICES_BOTTOM</category>
>       <filter-id>anonymous</filter-id>
> </action>


Thanks, but it still not working

Maybe, I'm doing something wrong?

1) I put file anonymous.xml in opt/nuxeo-dm/nxserver/config
(File name 'anonymous' matter? Maybe need another name...)

2) I found file actions-contrib.xml only in 
opt/nuxeo-dm/nxserver/web/root.war/modules/org.nuxeo.admin.c
enter/OSGI-INF

In opt/nuxeo-dm/nxserver/OSGI-INF no files

And I paste code in 
nuxeo-sample-project/src/main/resources/OSGI-INF/actions-con
trib.xml  (I use this directory for projects ((Maven)).

<?xml version="1.0"?>
<component name="org.nuxeo.project.sample.actions">

        <extension
target="org.nuxeo.ecm.platform.actions.ActionService"
                point="filters">
                <filter id="anonymous">
                        <rule grant="true">
                        <condition>#{currentUser.anonymous}</condition>
                        </rule>
                </filter>
        </extension>

        <extension
target="org.nuxeo.ecm.platform.actions.ActionService"
                point="actions">


                <action id="login" link="logout" label="command.login">
                        <category>USER_SERVICES_BOTTOM</category>
                        <filter-id>anonymous</filter-id>
                </action>

        </extension>

</component>

That all I did. What else? Or what I did wrong?
---
Mailing list: [email protected]
Forum: http://forum.nuxeo.org/f/1/

Reply via email to