Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP .Net Security > Replace Windows Logon Box for SQL Reporting Services

Thread Tools

Replace Windows Logon Box for SQL Reporting Services

Posts: n/a
I want to customize the windows authentication of my SQL Reporting Service,
so that I can:
1. Replace the Logon Popup Box with my own webform
2. Maintain the user profile in my Windows 2003 server
3. User can logout even using Windows Authentication

I tried to make a separated web application for Form Authentication on my
web server (http://localhost/auth/login.aspx), it will be used as first page
to access my report server.
Then I use the LogonUser API from ADVAPI32.dll for password verification
like the following code:

Dim t1 as Integer
Dim bOK As Boolean = LogonUser(userID, domain, password, 2, 0, t1)
Dim pt1 As IntPtr = New IntPtr(t1)
Dim wi As WindowsIdentity = New WindowsIdentity(pt1)
Dim wp As WindowsPrincipal = New WindowsPrincipal(wi)
HttpContext.Current.User = wp
FormsAuthentication.SetAuthCookie(context.User.Ide ntity.Name, False)

But the Identity used in Reporting Service is still my local machine's user
id, not the one I logon in my customized login page.
What should I do? is there any other way to do it?
Can I use impersonation to do it? But the impersonated user is dynamically
change according to the logon user. How can I do it? Thanks.
Reply With Quote

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Question Help: Logon vs Account Logon, Local Logon vs Authentication CJH Microsoft Certification 0 01-04-2006 04:03 PM
What is best practice: Combining anonymous logon with windows logon? Kjell Kristiansson ASP .Net Security 0 11-30-2005 12:53 PM
Is it possible to use Dataset with Sql Reporting Services ? Oney ASP .Net 3 11-12-2004 02:27 PM
Problem in SQL Reporting services Raju ASP .Net 0 08-02-2004 04:01 AM
SQL Server Reporting Services with ASP.NET Mark ASP .Net 1 11-25-2003 06:23 AM