Wrox Programmer Forums
ASP.NET 1.x and 2.0 Application Design Application design with ASP.NET 1.0, 1.1, and 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.x and 2.0 Application Design section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
Old June 28th, 2004, 05:34 AM
Authorized User
Join Date: Apr 2004
Posts: 14
Thanks: 0
Thanked 0 Times in 0 Posts
Default Implementation Decision

(Regret any inconvenience about my English)

Greetings from Spain. Just some help to decide how to implement the following.
Just a brief summary about my proyect. We have a company which is composed of several sections. In each section there are different functions - administrator, managers, guests. I have implemented the role-based authenticacion and authorization in the Global.asax file through the GenericPrincipal Class.

There's a general Administrator who can access to all of the data stored by any of the sections, but the sections users are not allowed to see each other info and data.

When the users login I retrieve from the db the user's section. Where is "best practice" to store this info in order to be available all around the app? In the Session object or maybe in the HttpContext.Items object?

Any suggest is welcome. Thanks in advance

Just reading we'll reach our goals.
Just reading we\'ll reach our goals.
Old June 28th, 2004, 08:40 AM
planoie's Avatar
Friend of Wrox
Join Date: Aug 2003
Posts: 5,407
Thanks: 0
Thanked 16 Times in 16 Posts

I would start with the session collection. You could also use a cookie.
Old June 28th, 2004, 11:04 AM
Authorized User
Join Date: Apr 2004
Posts: 14
Thanks: 0
Thanked 0 Times in 0 Posts

Thanks for your answer.

Just thinking out...

'First establishing Session_OnStart:
'Setting the IdSection Value
HttpContext.Current.Session("IdSection") = anyValue
'Now Getting the IdSection in any Stored Procedure
myParam.Value = Current.Session("IdSection")

'If User LogOff I raise Event Session_OnEnd through the
'HttpSessionState Abandon Method.

Public Sub LogOff(sender As System.Object, E As System.EventArgs)
'Removing the authetication ticket if FormsAuthentication Provider
'was used
'I Raise the Session_OnEnd Event to delete the Session("IdSection")
End Sub

'Session_OnEnd Event at global.asax

Would you use this solution?

Thanks in advance

Just reading we'll reach our goals.

Similar Threads
Thread Thread Starter Forum Replies Last Post
jms implementation yanis97 J2EE 0 August 31st, 2006 04:29 AM
pagination implementation vivekkumar_23 Struts 1 July 12th, 2006 05:52 AM
SSL implementation piyush_vish ASP.NET 1.0 and 1.1 Professional 0 January 6th, 2006 07:30 AM
c# implementation help cshanmuganathan ASP.NET 1.0 and 1.1 Basics 1 May 28th, 2005 12:08 AM
Design decision on class library projects? tkubaska BOOK: ASP.NET Website Programming Problem-Design-Solution 2 May 19th, 2004 11:43 AM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.