cancel
Showing results for 
Search instead for 
Did you mean: 

Create users no owners of their space

aac
Champ in-the-making
Champ in-the-making
Hi all.
How can I create one user and assign him an space created before and administered by other user, and avoid that this new user become the owner of this space.

I have tried a lot of ways, but when I assign the existing space to the new user (that I want, for example, to have only consumer rights), the new user has total control over this space because he is the new owner.

Thanks and regards

Alberto
4 REPLIES 4

rogier_oudshoor
Champ in-the-making
Champ in-the-making
You can, through scripting Smiley Wink

zaizi
Champ in-the-making
Champ in-the-making
See http://wiki.alfresco.com/wiki/Security_Services#Defining_a_home_space_that_is_an_existing_space_.28E...

You can specify an existing space for new users and also define what permissions they'll have on the new space through configuration. See the example of guest home space provider, which uses the gives new users consumer rights on the existing Guest space.

aac
Champ in-the-making
Champ in-the-making
Thanks for your help "zaizi".
I have tried to modify the authentication-services-context.xml but it seems Alfresco doesn't notice.

For example I have modified directly the "path" in the bean "userHomesHomeFolderProvider"

        <property name="path">
     <value>/${spaces.company_home.childname}/cm:MYSPACE</value> 
        </property>

To point directly to "MYSPACE" but without success.

Besides, I don't know the correct way of override the authentication-services-context.xml. If I must write the changes in the "extension" dir or if I must modify directly the original file. I have tried the two options, but… again without success.

best regards
Alberto

korfino
Champ in-the-making
Champ in-the-making
Zaizi, I've tried your method with mixed results.  I was able to set the default user home to Guest Home and prevent a new sub-space from being created, but the new user still becomes the owner of Guest Home.  I am creating users via the UI and using Alfresco 3.

My goal: when a new user is created, their home space is set to "Guest Home" with NO access. (Most users will be Alfresco Share only)

I modified authentication-services-context.html:

    <bean name="homeFolderManager" class="org.alfresco.repo.security.person.HomeFolderManager">
        <property name="nodeService">
            <ref bean="nodeService" />
        </property>
        <property name="policyComponent">
            <ref bean="policyComponent" />
        </property>
        <property name="defaultProvider">
            <!– By default, a new user home is not created for each new user; they all get home set
         to the Guest space. –>
         <!–<ref bean="userHomesHomeFolderProvider" /> –>
         <ref bean="guestHomeFolderProvider" />
        </property>
    </bean>

    <bean name="guestHomeFolderProvider" class="org.alfresco.repo.security.person.ExistingPathBasedHomeFolderProvider">
        <property name="serviceRegistry">
            <ref bean="ServiceRegistry" />
        </property>
        <property name="path">
           <value>/${spaces.company_home.childname}/${spaces.guest_home.childname}</value>
        </property>
        <property name="storeUrl">
           <value>${spaces.store}</value>
        </property>
        <property name="homeFolderManager">
            <ref bean="homeFolderManager" />
        </property>
        <property name="userPermissions">
            <set>
                <!– Change so that no access by default  –>
            <!–<value>Consumer</value> –>
             <value></value>
            </set>
        </property>
    </bean>

and web-client-config-custom.xml:
         <!– The path to starting point when creating/finding home folders for new users in the UI –>
         <default-home-space-path>/app:company_home/app:guest_home</default-home-space-path>

Suggestions?

KRO