CSLA remote data portal
Old forum URL: forums.lhotka.net/forums/t/2326.aspx
atlanta posted on Monday, February 12, 2007
Hi,
This is not regarding PTracker, but my application:
I am trying to use remote data portal.
I have no authentication mechanism between in the web.config for both web UI and remoting.
The common bit on both is <authentication mode="None"/>
I get this error when UI is trying a fetch.
System.Security.SecurityException: Principal must be of type BusinessPrincipal, not System.Security.Principal.GenericPrincipal.
though PTracker with the csla authentication works fine.
Please help.
Thanks,
RockfordLhotka replied on Monday, February 12, 2007
Make sure the CslaAuthentication value in <appSettings> is the same in both client and server config files.RockfordLhotka replied on Monday, February 12, 2007
Oh, and make sure you either logout before trying to use the data portal. If you look at chapters 8, 9 or 10 you'll notice that in all cases the application does a logout before anything else happens - effectively making sure that the current principal on the client is an instance of your custom principal object.atlanta replied on Monday, February 12, 2007
Thanks Rocky,
that worked....I could give anything on both sides as long as it is the same.
I scanned through my ebook, I don't think this is mentioned.
xal replied on Monday, February 12, 2007
Wether or not you want to use security, you need to create a principal (at least a dummy one) and call LogOut() in "Application_AcquireRequestState". Check in the Global.asax file inside the project tracker for an example...
Andrés
atlanta replied on Monday, February 12, 2007
Thanks, will do.
Copyright (c) Marimer LLC