Groups | Blog | Home
all groups > sql server reporting services > june 2006 >

sql server reporting services : Prblem with MSDN Article on forms authentication for rs2005


vamsi
6/29/2006 4:42:38 PM
Hi All
i wanted to implement foms authentication to RS2005.i am
using the MSDN article to implement the forms authentication.when build
the project i am getting this error.


'Microsoft.Samples.ReportingServices.CustomSecurity.Authorization' does
not implement interface member
'Microsoft.ReportingServices.Interfaces.IAuthorizationExtension.CheckAccess(string,
System.IntPtr, byte[],
Microsoft.ReportingServices.Interfaces.ModelOperation)' C:\Program
Files\Microsoft SQL Server\MSSQL\Reporting
Services\Samples\Extensions\FormsAuthenticationSample\Authorization.cs



can any one help me with this problem.

Thanks
Amarnath
6/29/2006 10:43:02 PM
Try opening your reference and see any problems otherwise remove the
reference and search for the reference and add it again..

Amarnath

[quoted text, click to view]
vamsi
6/30/2006 9:14:07 AM
Ok Thanks.i will try it.

Thanks
Vamsi
[quoted text, click to view]
vamsi
7/5/2006 8:14:43 AM
everything looks good.i added microsoft.reporting.interfaces and web
services and named as my machine name.still getting the error at the
authorization .

Thanks
[quoted text, click to view]
antikas
8/23/2006 6:04:02 AM
Hi,
apparently the samplel code is not complete for the current version, I faced
the same problem.
The issue is that the code supplied does not include 2 overloads of the
CheckAccess method.
To resolve include the following in Authorisation.cs:
// Overload for a Model operation
public bool CheckAccess(
string userName,
IntPtr userToken,
byte[] secDesc,
ModelOperation modelOperation)
{
// If the user is the administrator, allow unrestricted access.
if (0 == String.Compare(userName, m_adminUserName, true,
CultureInfo.CurrentCulture))
return true;

if (!CheckAccess(userName, userToken, secDesc, modelOperation))
return false;
else
return true;
}

// Overload for a ModelItem operation
public bool CheckAccess(
string userName,
IntPtr userToken,
byte[] secDesc,
ModelItemOperation modelItemOperation)
{
// If the user is the administrator, allow unrestricted access.
if (0 == String.Compare(userName, m_adminUserName, true,
CultureInfo.CurrentCulture))
return true;

if (!CheckAccess(userName, userToken, secDesc, modelItemOperation))
return false;
else
return true;
}
This will allow the code to compile.
Now if only it didnt give me an 'Invalid Namespace' Error when I try to run
it.... :(
Please lt me know if it works for you!

[quoted text, click to view]
antikas
8/25/2006 7:21:02 AM
Update:
The problem is that you are using the Report Services 2000 sample on a 2005
server. You should download the 2005 sample from here:
http://www.microsoft.com/downloads/details.aspx?familyid=E719ECF7-9F46-4312-AF89-6AD8702E4E6E&displaylang=en
hope this helps :-)

[quoted text, click to view]
vamsi
8/25/2006 3:34:36 PM
Hi i downloaded new article from the same page just a week back and it
worked.it is able to authenticate.But i am having little bit doubt on
the member ship role authorization.

where we have to design all the tables for the roles that each
registered user supposed to get.Like i want some users to get the
subscription screated and i dont want for some of the users to do this
and they can just view the reports.

Thanks
Vamsi
[quoted text, click to view]
AddThis Social Bookmark Button