More in this section

Forums / Developing with Sitefinity / Restricting Blog/Library access at Role or User level.

Restricting Blog/Library access at Role or User level.

5 posts, 0 answered
  1. Andy
    Andy avatar
    62 posts
    Registered:
    01 Aug 2008
    13 Jan 2009
    Link to this post
    I have a new project coming up where a site's content will be modifiable by many users, however each user will have responsibility for different sections of content.

    For example, the site may contain two blogs, each controlled by a different user, but a user shouldn't be able to add or modify content in the other's blog.

    How can this level of control be achieved in Sitefinity 3.5?
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    13 Jan 2009
    Link to this post
    Hello Andy,

    Thank you for using our services.

    It is possible to have this functionality if you add a new provider for blogs, and set appropriate permissions for it. Thus, a dropdown list will appear, from which you could change the providers and manage them if you you have the permissions for this of course. Currently, permissions are implemented per module and per provider. We started working on security implementation for single items and users.

    Let us know if there is anything else that we can do for you.

    Regards,
    Ivan Dimitrov
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  3. Andy
    Andy avatar
    62 posts
    Registered:
    01 Aug 2008
    13 Jan 2009
    Link to this post
    OK, thanks Ivan. I may ask for some help on doing that later!

    I'm impressed by the flexibility of the Sitefinity platform, the level of technical support you guys give, and the continual development effort towards making it a better product.

    Is the improved security model you mention to be included in 4.0, or is it beyond that?
  4. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    13 Jan 2009
    Link to this post
    Hi Andy,

    There are a lot of improvements and new features that will come with 4.0 and the new GenericContent architecture. Here is a link to our RoadMap, http://www.sitefinity.com/product/roadmap.aspx. We have posted some of the main features there.

    As for the setting up additional provider here is an example:

    In <cmsEngine><providers> node add new provider. I have added Blogs_USER as a new provider. Here is an important thing, I have not changed the applicationName below. When you change the applicationName attribute, for instance to Blogs_USERS, you should achieve the required scenario. Otherwise the blogs are shared.

     <cmsEngine defaultProvider="Generic_Content"
          <providers> 
            <clear /> 
            <add name="Generic_Content" urlRewriteFormat="[Publication_Date]/[Name].aspx" urlDateTimeFormat="yy-MM-dd" urlWhitespaceChar="_" visible="True" defaultMetaField="Name" securityProviderName="" allowLocalization="False" allowVersioning="True" allowWorkflow="False" allowComments="false" commentsModeration="true" versioningProviderName="" connectionStringName="GenericContentConnection" type="Telerik.Cms.Engine.Data.Providers.DefaultProvider, Telerik.Cms.Engine.Data" /> 
            <add name="News" allowWorkflow="true" urlRewriteFormat="[Publication_Date]/[Title].aspx" urlDateTimeFormat="yy-MM-dd" urlWhitespaceChar="_" visible="False" defaultMetaField="Title" securityProviderName="" allowVersioning="True" applicationName="/News" versioningProviderName="" commentsModeration="true" connectionStringName="GenericContentConnection" type="Telerik.News.Data.DefaultNewsProvider, Telerik.News.Data" /> 
            <add name="Blogs" urlRewriteFormat="[Publication_Date]/[Title].aspx" urlDateTimeFormat="yy-MM-dd" urlWhitespaceChar="_" visible="False" defaultMetaField="Title" applicationName="/Blogs" allowVersioning="True" allowLocalization="False" localizationProviderName="" allowWorkflow="False" securityProviderName="" versioningProviderName="" connectionStringName="GenericContentConnection" type="Telerik.Blogs.Data.DefaultBlogProvider, Telerik.Blogs.Data" /> 
            <add name="Blogs_USER" urlRewriteFormat="[Publication_Date]/[Title].aspx" urlDateTimeFormat="yy-MM-dd" urlWhitespaceChar="_" visible="False" defaultMetaField="Title" applicationName="/Blogs" allowVersioning="True" allowLocalization="False" localizationProviderName="" allowWorkflow="False" securityProviderName="" versioningProviderName="" connectionStringName="GenericContentConnection" type="Telerik.Blogs.Data.DefaultBlogProvider, Telerik.Blogs.Data" /> 
            <add name="Libraries" urlRewriteFormat="~/{Provider}/{LibraryName}/[Name].sflb.ashx" urlDateTimeFormat="yy-MM-dd" urlWhitespaceChar="_" visible="False" defaultMetaField="Name" applicationName="/Libraries" allowVersioning="False" allowLocalization="False" localizationProviderName="" allowWorkflow="False" securityProviderName="" versioningProviderName="" connectionStringName="GenericContentConnection" type="Telerik.Libraries.Data.DefaultProvider, Telerik.Libraries.Data" tagEditorTemplate="~/Sitefinity/Admin/ControlTemplates/Libraries/BatchTagsEditor.ascx" /> 
            <add name="Events" urlRewriteFormat="[Publication_Date]/[Title].aspx" urlDateTimeFormat="yy-MM-dd" urlWhitespaceChar="_" visible="False" defaultMetaField="Title" securityProviderName="" allowVersioning="True" applicationName="/Events" versioningProviderName="" commentsModeration="true" connectionStringName="GenericContentConnection" type="Telerik.Events.Data.DefaultEventsProvider, Telerik.Events.Data" /> 
          </providers> 

    Then, add new metafields for  your provider.

    <add key="Blogs_USER.Title" valueType="ShortText" visible="True" searchable="True" sortable="True" defaultValue="" /> 
    <add key="Blogs_USER.Author" valueType="ShortText" visible="True" searchable="True" sortable="True" defaultValue="" /> 
    <add key="Blogs_USER.Publication_Date" valueType="DateTime" visible="True" searchable="True" sortable="True" defaultValue="#Now" /> 
    <add key="Blogs_USER.BlogID" valueType="Guid" visible="False" searchable="True" sortable="True" defaultValue="" /> 
    <add key="Blogs_USER.Category" valueType="ShortText" visible="True" searchable="True" sortable="True" defaultValue="" /> 
    <add key="Blogs_USER.View_Count" valueType="Integer" visible="True" searchable="True" sortable="True" defaultValue="0" /> 

    Now you need to copy the templates for the frontend and backend for Blogs module to the same folder. Rename the copies of Blogs' templates to Blogs_USER.

    Finally, go to Blogs module, choose your provider and set up appropriate permissions for a given role. You should add your editors' accounts in this role.

    Regards,
    Ivan Dimitrov
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  5. Andy
    Andy avatar
    62 posts
    Registered:
    01 Aug 2008
    13 Jan 2009
    Link to this post
    Yes, I'm very much looking forward to seeing 4.0!

    Unfortunately the initial phase of this new project is required before 4.0 is released, so I'm going to have to do my best with 3.5.

    Thanks for your notes Ivan, and I'll give that a go when I get around to coding it up and let you know how it goes.

    Cheers!
    Andy
Register for webinar
5 posts, 0 answered