DomainDataSource and User Roles Authentication

2 posts, 1 answers
  1. Martyn
    Martyn avatar
    18 posts
    Member since:
    Mar 2011

    Posted 31 May 2011 Link to this post

    I have a Silverlight Business Application configured to use Membership and Roles.

    I have a page within my Silverlight application that can only be accessed by user's belonging to the "Admin" role.

    I have a RadDomainDataSource on that page which is attempting to access a query names "GetAllUsersQuery", which within the service definition has an attribute [RequiresRole("Admin")], however, that Domain Data Source is returning a DomainException as it is trying to load before the user has been authenticated and checked to be within the Admin role.

    How do I go about fixing this problem?
  2. Answer
    Rossen Hristov
    Rossen Hristov avatar
    2478 posts

    Posted 31 May 2011 Link to this post

    Hello Martyn,

    I am not sure what is your exact setup, but most probably you should not use AutoLoad=true and turn it on once you have authenticated the user. If AutoLoad is false, RadDomainDataSource will not try to load unless told to do so by calling its Load method.

    On the other hand, how would you go about solving the problem if you were using the stock MS DomainDataSource? If you know the answer to this question, I guess it will be the same with RadDomainDataSource, since the two controls have one and the same internal logic. In other words, this might really be a WCF RIA Services problem/question and not specifically a Telerik control one.

    I hope this helps.

    All the best,

    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. DevCraft R3 2016 release webinar banner
Back to Top