Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Development Tools
 Reporting Services Development
 Object moved when executing a web method

Author  Topic 

wall
Starting Member

4 Posts

Posted - 2006-03-28 : 18:59:27
I posted this as a reply to another issue (http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=59930) because the topic was similar but I am not sure it was the right place to post, so....

Hello.

I am hoping that someone can help me with this. We are using forms authentication with Reporting Services 2005. The forms auth works very well when accessing the ReportManager website or requesting a report via URL from the ReportServer website.

But we need to display a list of reports (filtered for the authenticated user) and create our own report parameters form for users to select run-time values for a selected report. This involves calling web methods in the Reporting Services web services - for example, ListChildren(), GetReportParameters(). This works nicely with Windows authentication.

But with forms authentication, I am having a problem getting the Reporting Services web methods to run.

When my code attempts to execute one of these web methods I get an error that reads:

<html><head><title>Object moved</title></head><body>
<h2>Object moved to <a href="/ReportServer/logon.aspx?ReturnUrl=%2freportserver%2fReportExecution2005.asmx">here</a>.</h2>
</body></html>

I have a week old incident with Microsoft and it is difficult to get their time. Our Reporting Services project has come to a grinding halt.

Can anyone help me with this?

Thank you, thank you.

Merkin
Funky Drop Bear Fearing SQL Dude!

4970 Posts

Posted - 2006-03-28 : 22:25:09
That makes sense, nobody is filling out the login form.
In your web.config, allow access to the webservice urls to unauthenticated users.



Damian
"A foolish consistency is the hobgoblin of little minds." - Emerson
Go to Top of Page

wall
Starting Member

4 Posts

Posted - 2006-03-29 : 15:20:40
Thanks for the feedback Merkin.

In the web.config in the ReportServer virt dir I changed <deny users="?" /> to <allow users="*" />. My Logon.aspx doesn't get hit now but I have managed to find a work around for now.

Now I am able to execute one web method and unable to execute another: for example, I can execute ListRenderingExtensions() but I am unable to execute ListChildren(). ListRenderingExtensions return an array of extensions (HTML, EXCEL, PDF, etc) but attempting to execute ListChildren causes this SoapException: The permissions granted to user '' are insufficient for performing this operation.

Apparently I am now unable to get the credentials to pass... I've tried:

Dim mycred = Net.CredentialCache.DefaultNetworkCredentials
rs.Credentials = mycred
AND
Dim mycred As New New NetworkCredential("myuser", "mypass")
rs.Credentials = mycred


Before all this I authenticate the user (forms auth) and set a cookie.

I can't seem to find any documentation on this part of forms auth: calling web methods for custom rendering.

Thanks again for the first reply. Look forward to hearing from you again.
Go to Top of Page

zzz
Starting Member

5 Posts

Posted - 2006-04-10 : 09:48:32
Hello,

I am using forms authentication with Reporting Services 2005. When I try calling web methods in the Reporting Services web services - for example, GetReportDefinition(), I am having a problem getting the Reporting Services web methods to run with forms authentication.

When my code attempts to execute one of these web methods I get an error as following:

<html><head><title>Object moved</title></head><body>
<h2>Object moved to <a href="/ReportServer/logon.aspx?ReturnUrl=%2freportserver%2fReportExecution2005.asmx">here</a>.</h2>
</body></html>

Can anyone help me with this?

Thank you.
Go to Top of Page

wall
Starting Member

4 Posts

Posted - 2006-04-10 : 11:31:39
Well, I have been wrestling with this for about 2 weeks now. I have a case open with Microsoft support. MS tells me that "they have not heard of anyone attempting SOAP calls (against Reporting Services) while using Forms Authentication" and that "Reporting Services was not intended to be an Internet reporting application". I don't quite believe this because Microsoft's own doc (http://msdn2.microsoft.com/en-us/library/ms157198(SQL.90).aspx) suggests:
"If you are deploying Reporting Services on an Internet-facing Web server, you should replace Windows authentication with a custom authentication scheme ...". There is a link in this article to information on how to implement a security extension, which contains a link to instructions on how to set up and run the Security Extension Sample that is installed with SQL Server 2005.

After debugging the sample (I seemed to have a problem with the GetPermissions method in the Authorization (.vb) class-reply back and I'll elaborate), I found the same "Object Moved" error that I was getting with my other attempts at running Reporting Services (2005) with Forms Authentication.

MS has suggested that I use Basic Authentication over SSL. While this may be a viable, and secure (SSL) way to authenticate users, it still requires that everyone who needs access to Reporting Services have a domain account with you. There are many cases where this is not possible or fesible.

If anyone figures this out, please post some help here. I will do the same.

Thank you.
Go to Top of Page

zzz
Starting Member

5 Posts

Posted - 2006-04-11 : 17:23:17
If replacing

rs.Credentials = System.Net.CredentialCache.DefaultCredentials;
with:
rs.Credentials = new System.Net.NetworkCredential(uid, pwd, dom);

Calling Web service works if no security extension implemented on the report server.

But, no matter what I do, unable to make the server with security extension works.

Anyone knows why?





Go to Top of Page
   

- Advertisement -