Wrox Programmer Forums
|
BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6
This is the forum to discuss the Wrox book ASP.NET 2.0 Instant Results by Imar Spaanjaars, Paul Wilton, Shawn Livermore; ISBN: 9780471749516
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 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 February 16th, 2008, 03:48 PM
Registered User
 
Join Date: Feb 2008
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default BugBase Roles Do not Appear Windows 2003 IIS 6.0

Hi:

I took the BugBase code from Instant Results 2.0 on a Windows 2003 Server SP2 running IIS 6.0. When I run the code within Visual Studio 2005 (and even on Visual Studio 2008) while on Windows 2003, it runs fine, roles appear, I can add bugs, etc. However, outside Visual Studio, which means running IIS 6.0 in Windows 2003, the roles do not appear on the pages -- I am able to still log in and there are no errors, just the users are not allocated to roles. I did delete and add back the roles using Visual Studio Configuration Tool, but it didn't fix the problem.

Since Visual Studio has its own internal Web Server, could this be something to do with a difference of IIS 6.0 under Windows 2003 vs. the Visual Studio.

Has anybody run Bugbase on Windows 2003 SP2?

thanks,

Barry
 
Old February 16th, 2008, 03:58 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi Barry,

Are you using the default web.config that comes with the book? If not, make sure you have the correct code for the various providers like the roleManager.

Also, check out the aspnet_* tables in your database. Do you see the roles there? And what do you see in the Applications table?

Imar
---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of Beginning ASP.NET 3.5 : in C# and VB, ASP.NET 2.0 Instant Results and Dreamweaver MX 2004
Want to be my colleague? Then check out this post.
 
Old February 27th, 2008, 12:32 PM
Registered User
 
Join Date: Feb 2008
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi,

I am having a similar issue with Roles being displayed. It works fine on my local machine, but when uploaded to the online server, they are not displayed. This does not allow me to do any maintenance or view reports. Everything else seems to work fine. I am using www.aspspider.net as a free hosting service to test things out before I pay to go live. I appreciate any suggestions.

Thank you very much!
Paul
 
Old February 27th, 2008, 12:37 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi Paul,

Same questions for you then:

Are you using the default web.config that comes with the book? If not, make sure you have the correct code for the various providers like the roleManager.

Also, check out the aspnet_* tables in your database. Do you see the roles there? And what do you see in the Applications table?

Imar
---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of Beginning ASP.NET 3.5 : in C# and VB, ASP.NET 2.0 Instant Results and Dreamweaver MX 2004
Want to be my colleague? Then check out this post.
 
Old February 27th, 2008, 01:12 PM
Registered User
 
Join Date: Feb 2008
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi Imar,

Yes, I am using the default web.config file. I do not see a "roles" column in any of the aspnet_* tables. The aspnet_Applications table has 4 columns: ApplicationName, LoweredApplicationName, ApplicationId and Description. There are two records in this table: the first record has a /, /, encrypted value, NULL; the second record has /BugBase, /bugbase, encrypted value, NULL. Does this help?

Thanks!
Paul

 
Old February 27th, 2008, 02:54 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

There isn't a Roles column, only an aspnet_Roles and an aspnet_UsersInRoles table.

Yes, it helps; but you need to track it from there. Each application (in aspnet_Applications) has an ID. This ID connects other objects (like Roles and Users) to specific applications. It's just a matter of following the wire:

1. Each application has an ID
2. Each role is linked to an ApplicationID
3. Each users is linked to an ApplicationID
4. The UsersInRoles connects users to roles.

There's a fair chance there is a mismatch somewhere. E.g. your Roles are defined for application A, while your user belongs to Application B.

To find out, check the contents of these tables and see how everything is related....

Imar
---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of Beginning ASP.NET 3.5 : in C# and VB, ASP.NET 2.0 Instant Results and Dreamweaver MX 2004
Want to be my colleague? Then check out this post.
 
Old February 27th, 2008, 03:02 PM
Registered User
 
Join Date: Feb 2008
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thank you for your reply. But, this does not explain why my user role works on my local machine but not on the web server. Like I said, on my local machine, bugbase works like a million bucks!

 
Old February 27th, 2008, 03:04 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

It does explain it, if your local site uses a different application than the remote one.

How are you browsing to both sites?

Imar
---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of Beginning ASP.NET 3.5 : in C# and VB, ASP.NET 2.0 Instant Results and Dreamweaver MX 2004
Want to be my colleague? Then check out this post.
 
Old February 27th, 2008, 03:09 PM
Registered User
 
Join Date: Feb 2008
Posts: 5
Thanks: 0
Thanked 0 Times in 0 Posts
Default

On my local machine, I simply right-click on the default.aspx file and click "view in browser"

For the deployed site, I browse to the site using Internet Explorer. The default page appears and I can log in. The only thing missing is the role. If I login as superuser, manager or administrator, I have the same rights as tester. I cannot access the administration or reporting features or f the bugbase.

Thanks for the assistance again!
Paul

 
Old February 27th, 2008, 03:14 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

What I meant is: what do the URLs look like?

http://localhost:12345/BugBase uses a different application (by design) than www.mysite.com does.

Did you look at the tables? Is your account linked to the right roles for the right application? The part about the tables and their relations wasn't a theoretical overview of ASP.NET security, but your starting point in fixing the problem.

Cheers,

Imar





Similar Threads
Thread Thread Starter Forum Replies Last Post
IIS - Windows 2003 MAtkins Classic ASP Basics 18 April 27th, 2007 09:57 AM
roles and users in bugbase mrco BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 3 February 6th, 2007 12:32 PM
Problem Connecting to BugBase DB under IIS maxshreck BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 1 October 8th, 2006 07:48 PM
windows groups / roles evander General .NET 0 January 23rd, 2006 08:13 AM
IIS 2003 Can't Debug - Please HELP! MAtkins Classic ASP Basics 0 June 28th, 2005 09:04 PM





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