Showing posts with label myserver. Show all posts
Showing posts with label myserver. Show all posts

Monday, March 26, 2012

ReportViewer (ASP.NET) and Forms Authentication

I have successfully implemented forms authentication in RS. It works great to navigate to https://myserver/Reports. I get redirected to the login-page etc. It also works great to use the ReportViewer from within my WinForms app, using the

reportViewer.ServerReport.ReportServerCredentials.SetFormsCredentials

method. I'm also able to communicate with RS through it's web services by first calling the 'LogonUser' method. However, to get that to work I had to inherit the ReportExecutionService for the cookie-handling to work.

Now over to my problem (the only thing so far I haven't got working). I'm trying to use a ReportViewer on an ASP.net web page to access the reports. I have understood that 'SetFormsCredentials' is not avaliable here. Instead, as far as I have understood, I should implement my own IReportServerCredentials . The critical method there I guess is

GetFormsCredentials(out Cookie authCookie, out string formsUser, out string formsPassword, out string formsAuthority)

, am I right?

It's here my problem starts. The examples I have seen haven't implemented this method since they use other types of authentication. So, I would need an example of what to fill that method with...

Regards Andreas

Is there at least some documentation where I can read about this...?

(Can't find any examples on it...)

|||

After some more testing, I'm now able to render a report. This is possible if I implement the method like this:

public bool GetFormsCredentials(out Cookie authCookie, out string user, out string password, out string authority)

{

authCookie = null;

user = "validUser";

password = "validPassword";

authority = "";

return true;

}

But from what I can understand this method should be returning a cookie...

And I have done testings with the method described here: http://blogs.msdn.com/bimusings/archive/2005/11/04/489100.aspx, but if I return something else then null as cookie-Value, I get an exception like this:

Client found response content type of 'text/html; charset=utf-8', but expected 'text/xml'.....

So, if I return null as cookie-value I'm able to render the report, but I run into trouble when clicking on a link in the report that navigates to another report. The report isn't rendered, instead the message

  • Execution 'lvzt54q0lq1nrbjjmmubr02b' cannot be found
    is shown.

    Any kind of help here would be of great value!

    Regards Andreas

  • Monday, February 20, 2012

    reporting services works over internet ?

    Is it possible to access reports from internet, using a public address like
    http://www.mydomain.com/reports instead of http://myserver/reports ? How can
    I do it ?
    Thanks
    MorenoChange the <ReportServerUrl> entry in C:\Program Files\Microsoft SQL
    Server\MSSQL\Reporting Services\ReportManager\RSWebApplication.config
    -Steve
    "Moreno" <movendra@.yahoo.com> wrote in message
    news:%23$u5fFQXEHA.3716@.TK2MSFTNGP11.phx.gbl...
    > Is it possible to access reports from internet, using a public address
    like
    > http://www.mydomain.com/reports instead of http://myserver/reports ? How
    can
    > I do it ?
    > Thanks
    > Moreno
    >|||I did that, restarted Reporting services as well. But doesnt work.
    It says "Directory Listing Denied"
    "Stephen Walch" wrote:
    > Change the <ReportServerUrl> entry in C:\Program Files\Microsoft SQL
    > Server\MSSQL\Reporting Services\ReportManager\RSWebApplication.config
    > -Steve
    > "Moreno" <movendra@.yahoo.com> wrote in message
    > news:%23$u5fFQXEHA.3716@.TK2MSFTNGP11.phx.gbl...
    > > Is it possible to access reports from internet, using a public address
    > like
    > > http://www.mydomain.com/reports instead of http://myserver/reports ? How
    > can
    > > I do it ?
    > >
    > > Thanks
    > > Moreno
    > >
    > >
    >
    >|||Hello,
    Have you tried the url http://www.mydomain.com/reportserver ?
    you will be independant of web application parameters ReportManager.
    Have you set Directory Security of your Web Application under IIS ?
    Is your client authenticated against your application ?
    HTH
    Jerome Berthaud (MCSD)
    http://www.winsight.fr
    "AbiBaby" <AbiBaby@.discussions.microsoft.com> wrote in message
    news:05359046-2E28-4402-BED3-8F3F3FC70B1A@.microsoft.com...
    > I did that, restarted Reporting services as well. But doesnt work.
    > It says "Directory Listing Denied"
    > "Stephen Walch" wrote:
    > > Change the <ReportServerUrl> entry in C:\Program Files\Microsoft SQL
    > > Server\MSSQL\Reporting Services\ReportManager\RSWebApplication.config
    > >
    > > -Steve
    > >
    > > "Moreno" <movendra@.yahoo.com> wrote in message
    > > news:%23$u5fFQXEHA.3716@.TK2MSFTNGP11.phx.gbl...
    > > > Is it possible to access reports from internet, using a public address
    > > like
    > > > http://www.mydomain.com/reports instead of http://myserver/reports ?
    How
    > > can
    > > > I do it ?
    > > >
    > > > Thanks
    > > > Moreno
    > > >
    > > >
    > >
    > >
    > >|||Jerome,
    I have the same problem in earlier post of 10/15 that received no replies.
    I've had 5 folks email me with the same problem.
    I have Server2003/SQL2000/IIS6 and have just installed Reporting services. I
    have two websites on the server. Access to reports is fine using the
    http://servername/reportServer, and using IUSR_servername, but even when
    adding the following:
    <Configuration>
    <UI>
    <ReportServerUrl>http://servername/ReportServer</ReportServerUrl
    <ReportServerExternalURL>http://www.domain.org/ReportServer</ReportServerExternalURL>
    </UI>
    and
    I've added virtual directories under above domain for reportManager and
    reportServer giving appropriate read/execute permissions and security under
    IIS to IUSR account only - no clear no windows authentication.
    I continue to get: HTTP Error 403.8 - Forbidden
    I've reset permission on website with ISUR account, flushed dns on
    webserver, and flushed dns on domain controller.
    Multiple websites continue to work fine, but same error whenever I try to
    use a domain instead of server name.
    Thanks,
    Janet
    "Jerome BERTHAUD" wrote:
    > Hello,
    > Have you tried the url http://www.mydomain.com/reportserver ?
    > you will be independant of web application parameters ReportManager.
    > Have you set Directory Security of your Web Application under IIS ?
    > Is your client authenticated against your application ?
    > HTH
    > Jerome Berthaud (MCSD)
    > http://www.winsight.fr
    > "AbiBaby" <AbiBaby@.discussions.microsoft.com> wrote in message
    > news:05359046-2E28-4402-BED3-8F3F3FC70B1A@.microsoft.com...
    > > I did that, restarted Reporting services as well. But doesnt work.
    > > It says "Directory Listing Denied"
    > >
    > > "Stephen Walch" wrote:
    > >
    > > > Change the <ReportServerUrl> entry in C:\Program Files\Microsoft SQL
    > > > Server\MSSQL\Reporting Services\ReportManager\RSWebApplication.config
    > > >
    > > > -Steve
    > > >
    > > > "Moreno" <movendra@.yahoo.com> wrote in message
    > > > news:%23$u5fFQXEHA.3716@.TK2MSFTNGP11.phx.gbl...
    > > > > Is it possible to access reports from internet, using a public address
    > > > like
    > > > > http://www.mydomain.com/reports instead of http://myserver/reports ?
    > How
    > > > can
    > > > > I do it ?
    > > > >
    > > > > Thanks
    > > > > Moreno
    > > > >
    > > > >
    > > >
    > > >
    > > >
    >
    >