Wednesday, March 28, 2012

Problem Report Viewer Control

I am having an authentication problem using the Report Viewer Control. The
situation is that I have developed a simple ASP.NET application that will
used as an interface for Report Viewing. First, I have a TreeView Control
located on the default page that is being populated with the current reports
that are published on the Report Server. Second, I have a aspx page called
ReportViewer that holds the Report Viewer Control. Third, when a user clicks
on one of the reports in the TreeView control the report is generated in an
IFrame located in a table cell on the default page.
My Problem is that everytime I click to generate a report I am asked for
windows credentials. I am passing the full network credentials(testing
environment going to use an application pool when live and pass default
credentials) example System.Net.NetworkCredential("username", "password",
"domain") in the load event of both aspx pages and IIS directory security is
setup with anonymous access & integrated windows authentication(I have tried
about everything in IIS Directory Security). I have tried about everything
and for the life of me cannot get around this issue any assistance would be
greatly appreciated.
Thanks,
--
Andrew
MCSA,MCDBAIf your asp app is on a different machine then I think you are hitting the
double hop issue. You need to be using Kerberos to support double hop. This
is an IIS issue. Here is a good link:
http://support.microsoft.com/default.aspx?scid=kb;en-us;264921
I notice that you have enable anonymous on IIS where RS is located. This is
a bad idea. It will cause difficulties with managing Report Server. Either
you need to setup your security using Kerberos or you will have to implement
forms based authentication. If there is another way around it I am not sure
what it would be.
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Andrew" <Andrew@.discussions.microsoft.com> wrote in message
news:60F64653-3B04-4E3C-9ADA-D06A191AB9EE@.microsoft.com...
>I am having an authentication problem using the Report Viewer Control. The
> situation is that I have developed a simple ASP.NET application that will
> used as an interface for Report Viewing. First, I have a TreeView Control
> located on the default page that is being populated with the current
> reports
> that are published on the Report Server. Second, I have a aspx page called
> ReportViewer that holds the Report Viewer Control. Third, when a user
> clicks
> on one of the reports in the TreeView control the report is generated in
> an
> IFrame located in a table cell on the default page.
> My Problem is that everytime I click to generate a report I am asked for
> windows credentials. I am passing the full network credentials(testing
> environment going to use an application pool when live and pass default
> credentials) example System.Net.NetworkCredential("username", "password",
> "domain") in the load event of both aspx pages and IIS directory security
> is
> setup with anonymous access & integrated windows authentication(I have
> tried
> about everything in IIS Directory Security). I have tried about everything
> and for the life of me cannot get around this issue any assistance would
> be
> greatly appreciated.
> Thanks,
> --
> Andrew
> MCSA,MCDBA|||Bruce,
Thanks for the response and I am just using windows authentication on the
live report server. I enabled the anonymous access in a testing environment
just to try to get around the authentication problems I was encountering. My
issue was that I am developing in a different domain and I am accessing the
report server by IP address. Well when I implemented the application on the
production domain I never changed the report server path to the actual report
server machine name and this caused my authentication problem. Just one of
those little slip ups that seem to cause the biggest problems. Thanks,
--
Andrew
MCSA,MCDBA
--
Andrew
MCSA,MCDBA
"Bruce L-C [MVP]" wrote:
> If your asp app is on a different machine then I think you are hitting the
> double hop issue. You need to be using Kerberos to support double hop. This
> is an IIS issue. Here is a good link:
> http://support.microsoft.com/default.aspx?scid=kb;en-us;264921
> I notice that you have enable anonymous on IIS where RS is located. This is
> a bad idea. It will cause difficulties with managing Report Server. Either
> you need to setup your security using Kerberos or you will have to implement
> forms based authentication. If there is another way around it I am not sure
> what it would be.
>
> --
> Bruce Loehle-Conger
> MVP SQL Server Reporting Services
>
> "Andrew" <Andrew@.discussions.microsoft.com> wrote in message
> news:60F64653-3B04-4E3C-9ADA-D06A191AB9EE@.microsoft.com...
> >I am having an authentication problem using the Report Viewer Control. The
> > situation is that I have developed a simple ASP.NET application that will
> > used as an interface for Report Viewing. First, I have a TreeView Control
> > located on the default page that is being populated with the current
> > reports
> > that are published on the Report Server. Second, I have a aspx page called
> > ReportViewer that holds the Report Viewer Control. Third, when a user
> > clicks
> > on one of the reports in the TreeView control the report is generated in
> > an
> > IFrame located in a table cell on the default page.
> >
> > My Problem is that everytime I click to generate a report I am asked for
> > windows credentials. I am passing the full network credentials(testing
> > environment going to use an application pool when live and pass default
> > credentials) example System.Net.NetworkCredential("username", "password",
> > "domain") in the load event of both aspx pages and IIS directory security
> > is
> > setup with anonymous access & integrated windows authentication(I have
> > tried
> > about everything in IIS Directory Security). I have tried about everything
> > and for the life of me cannot get around this issue any assistance would
> > be
> > greatly appreciated.
> >
> > Thanks,
> >
> > --
> > Andrew
> > MCSA,MCDBA
>
>|||Ahh, same symptom as double hop but different reason. Glad you got it figure
out.
Bruce Loehle-Conger
MVP SQL Server Reporting Services
"Andrew" <Andrew@.discussions.microsoft.com> wrote in message
news:28AC4137-F5A4-4F09-8B00-80126775DBB6@.microsoft.com...
> Bruce,
> Thanks for the response and I am just using windows authentication on the
> live report server. I enabled the anonymous access in a testing
> environment
> just to try to get around the authentication problems I was encountering.
> My
> issue was that I am developing in a different domain and I am accessing
> the
> report server by IP address. Well when I implemented the application on
> the
> production domain I never changed the report server path to the actual
> report
> server machine name and this caused my authentication problem. Just one
> of
> those little slip ups that seem to cause the biggest problems. Thanks,
> --
> Andrew
> MCSA,MCDBA
> --
> Andrew
> MCSA,MCDBA
>
> "Bruce L-C [MVP]" wrote:
>> If your asp app is on a different machine then I think you are hitting
>> the
>> double hop issue. You need to be using Kerberos to support double hop.
>> This
>> is an IIS issue. Here is a good link:
>> http://support.microsoft.com/default.aspx?scid=kb;en-us;264921
>> I notice that you have enable anonymous on IIS where RS is located. This
>> is
>> a bad idea. It will cause difficulties with managing Report Server.
>> Either
>> you need to setup your security using Kerberos or you will have to
>> implement
>> forms based authentication. If there is another way around it I am not
>> sure
>> what it would be.
>>
>> --
>> Bruce Loehle-Conger
>> MVP SQL Server Reporting Services
>>
>> "Andrew" <Andrew@.discussions.microsoft.com> wrote in message
>> news:60F64653-3B04-4E3C-9ADA-D06A191AB9EE@.microsoft.com...
>> >I am having an authentication problem using the Report Viewer Control.
>> >The
>> > situation is that I have developed a simple ASP.NET application that
>> > will
>> > used as an interface for Report Viewing. First, I have a TreeView
>> > Control
>> > located on the default page that is being populated with the current
>> > reports
>> > that are published on the Report Server. Second, I have a aspx page
>> > called
>> > ReportViewer that holds the Report Viewer Control. Third, when a user
>> > clicks
>> > on one of the reports in the TreeView control the report is generated
>> > in
>> > an
>> > IFrame located in a table cell on the default page.
>> >
>> > My Problem is that everytime I click to generate a report I am asked
>> > for
>> > windows credentials. I am passing the full network credentials(testing
>> > environment going to use an application pool when live and pass default
>> > credentials) example System.Net.NetworkCredential("username",
>> > "password",
>> > "domain") in the load event of both aspx pages and IIS directory
>> > security
>> > is
>> > setup with anonymous access & integrated windows authentication(I have
>> > tried
>> > about everything in IIS Directory Security). I have tried about
>> > everything
>> > and for the life of me cannot get around this issue any assistance
>> > would
>> > be
>> > greatly appreciated.
>> >
>> > Thanks,
>> >
>> > --
>> > Andrew
>> > MCSA,MCDBA
>>|||Andrew wrote:
> Bruce,
> Thanks for the response and I am just using windows authentication on the
> live report server. I enabled the anonymous access in a testing environment
> just to try to get around the authentication problems I was encountering. My
> issue was that I am developing in a different domain and I am accessing the
> report server by IP address. Well when I implemented the application on the
> production domain I never changed the report server path to the actual report
> server machine name and this caused my authentication problem. Just one of
> those little slip ups that seem to cause the biggest problems. Thanks,
Andrew,
you will not be authenticated with IIS if you have anonymous access
enabled.Even if you pass credentials with
System.Net.NetworkCredential(user,pass,domain).

No comments:

Post a Comment