How do you rate this blog

Saturday, September 29, 2012

Forms Authentication in SSRS 2012



After spending 2 days scratching my head on how to implement forms authentication for SSRS 2012, I finally decided to use the forms authentication sample provided for SSRS 2008 R2 although the official Microsoft page says that it only works with SSRS 2008 R2 and earlier versions which was worth a try. Most of the steps are same as in SQL Server 2008 R2.
Given below are the steps taken for implementing the forms authentication sample in SQL Server 2012.

Building the sample -

Step 1 - Download the Security Extension Sample from and install the same on your system from the link given here Link
Step 2 - The sample will be installed in the same folder where you have installed your SQL Server. for example - <SQL Server Installation Folder> \100\Samples\Reporting Services\Extension Samples\FormsAuthentication Sample, you can see that there is one solution file for VB and one for C#. I will be using the solution file for C# in this post. Open the solution you might get a warning symbol next to Microsoft.ReportingServices.Interfaces, in that case open Right Click on the Reference node and say Add Reference which opens a dialog box, the click on browse and go to <ReportingService Directory>/ReportServer/bin and click on add.  Now you can see the warning symbol disappears.
Step 3 - In the AuthenticationExtension.cs and AuthenticationUtilities.cs files replace the localhost in connection string with the <servername>\RS_<instancename> (remember to prefix RS_ to the instance name).
Step 4 - Open the file AuthenticationUtilities.cs and replace the reportserverinstance with RS_<reportserver instance name>.
If you dont prefix RS_ for the instance name you might get invalid namespace error when you restart the reportserver.
Step 5 - In the AuthenticationUtilities.cs go the line where the wmiNameSpace has been declared and replace {0} with the RS_<report server instance name> and replace V10 with V11 so the string should like @"\root\Microsoft\SqlServer\ReportServer\RS_<instancename>\v11"
Step 6 - After making all these changes now you are ready to build the solution, but you would require a keyfile to complete this operation. So go to the VisualStudio command prompt and navigate to the Samples folder and execute the command "sn -k SampleKey.snk". If you navigate to the folder in the windows explorer you should be able to see the SampleKey.snk folder in it. Now right click on the project and click on build. You should be able to see the message  "Build Succeeded" and now you are ready to deploy the sample.


Deploying the sample -

Step 1 - Go to the Solution folder/bin/debug and you can find the files Microsoft.Samples.ReportingServices.CustomSecurity.dll, Microsoft.Samples.ReportingServices.CustomSecurity.pdb files. Copy these 2 files into <SQL Server Reporting Services Path>\ReportServer\bin directory and <SQL Server Reporting Services Path>\ReportManager\bin directory.
Step 2 - Copy Logon.aspx in the solution file into the and <SQL Server Reporting Services Path>\ReportServer directory.
Step 3 - Copy UILogon.aspx from  and <SQL Server Reporting Services Path>\ReportManager\Pages.


Modifying ReportServer and ReportManager configuration files -

Step 1 - Modifying ReportServer.config file located in <SQL Server Reporting Services Path>\ReportServer
a) Open the ReportServer.config file and add replace the <Authentication> tag with the code given below
<Authentication>
<AuthenticationTypes>
<Custom/>
</AuthenticationTypes>
<EnableAuthPersistence>true</EnableAuthPersistence>
<RSWindowsExtendedProtectionLevel>Off</RSWindowsExtendedProtectionLevel>
<RSWindowsExtendedProtectionScenario>Proxy</RSWindowsExtendedProtectionScenario>
</Authentication>
b) Replace the Security tag with the code given below
<Security>
<Extension Name="Forms"
Type="Microsoft.Samples.ReportingServices.CustomSecurity.Authorization,
Microsoft.Samples.ReportingServices.CustomSecurity" >
<Configuration>
<AdminConfiguration>
<UserName>username</UserName>
</AdminConfiguration>
</Configuration>
</Extension>
</Security>
<Authentication>
<Extension Name="Forms"
Type="Microsoft.Samples.ReportingServices.CustomSecurity.AuthenticationExtension,
Microsoft.Samples.ReportingServices.CustomSecurity" />
c) Locate the UI tag and replace it with the code given below -
<UI>
<CustomAuthenticationUI>
<loginUrl>/Pages/UILogon.aspx</loginUrl>
<UseSSL>True</UseSSL>
</CustomAuthenticationUI>
<ReportServerUrl>http://<server>/ReportServer</ReportServerUrl>
</UI>
* Remember to place your url in the ReportServerUrl tag and set UseSSL tag to false if you dont use SSL.

Step 2 - Modifying the RSSrvPolicy.config file located in the <SQL Reporting Services Path>\ReportServer
a) Add the below code to the existing policy which has the URL Membership of $CodeGen
<CodeGroup
class="UnionCodeGroup"
version="1"
Name="SecurityExtensionCodeGroup"
Description="Code group for the sample security extension"
PermissionSetName="FullTrust">
<IMembershipCondition
class="UrlMembershipCondition"
version="1"
Url="C:\Program Files\Microsoft SQL Server\MSRS10_50.MSSQLSERVER\Reporting Services\ReportServer\bin\Microsoft.Samples.ReportingServices.CustomSecurity.dll"
/>
</CodeGroup>

Step 3 - Modifying RSMgrPolicy.config file located in <SQL Reporting Services Path>\ReportManager folder.
You should locate the below code in the file and set PermissionSetName to "FullTrust" which has been shown in bold.
<CodeGroup
class="FirstMatchCodeGroup"
version="1"
PermissionSetName="FullTrust"
Description="This code group grants MyComputer code Execution permission. ">
<IMembershipCondition
class="ZoneMembershipCondition"
version="1"
Zone="MyComputer" />

Step 4 - Modifying the Web.config file located in the <SQL Reporting Services Path>\ReportServer folder
a) Locate the authentication mode tag and replace it with the code given below
<authentication mode="Forms">
<forms loginUrl="logon.aspx" name="sqlAuthCookie" timeout="60"
path="/"></forms>
</authentication>
b) Add the below code to below the Authentication Mode tag to restrict access to the users who dont have access rights
<authorization>
<deny users="?" />
</authorization>

Step 5 - Modifying the Web.Config file located in the <SQL Reporting Services Path>\ReportManager folder.
a) set <identity impersonate ="false" />
b) set <authentication mode="forms">
c) Go to appSettings and add the 2 keys given below to it
<add key="ReportServer" value="<Server Name>"/>
<add key="ReportServerInstance" value="<Instance Name>"/>

Creating Database - 
Go to <SQL Server Install directory>\100\Samples\Reporting Services\Extension Samples\FormsAuthentication Sample\cs\FormsAuthentication\Setup you can see 2 scripts, use the CreateUserStore.sql file and create database and tables which will be used for forms authentication.

Setting up admin access to the ReportManager
Step 1 -Open the ReportManager url and add a username and password and click register.
Step 2 - Open <SQL server reporting services install directory>\RSReportServer.config file
locate the Secuirty tag and you will see the tag Username tag in it and it has a dummy value as of now. Replace this with the username which you just registered.
<Security>
<Extension Name="Forms"
Type="Microsoft.Samples.ReportingServices.CustomSecurity.Authorization,
Microsoft.Samples.ReportingServices.CustomSecurity" >
<Configuration>
<AdminConfiguration>
<UserName>Bharath_RS</UserName>
</AdminConfiguration>
</Configuration>
</Extension>
</Security>
this will give that particular user complete access to the ReportServer as well as ReportManager.
So we have a the forms authentication up and running on your report server. If you get any error like unable to load Microsoft.Samples.ReportingServices.CustomSecurity.dll in the log files, restart your system and you should be able to see the login page for the reportserver or reportmanager.  Working on creating my own security extension instead of the one provided in the sample. Will post it if I am successful. If you have any problem while implementing this comment on this post, will try my best to resolve it.

69 comments:

  1. Bharath
    I got the following error while registering a user in the step "Setting up admin access to the ReportManager"

    The connection string as suggested is as follows

    using (SqlConnection conn = new SqlConnection(
    "Server=CHITTARANJAN\\RS_MSSQLSERVER;" +
    "Integrated Security=SSPI;" +
    "database=UserAccounts"))

    My Server name is CHITTARANJAN and the instance name is MSSQLSERVER. as suggested I have put RS_ before the instance name.

    Please help

    Error Message
    ------------------

    An error occurred while attempting to add the account. A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)

    ReplyDelete
  2. Hi Chitta,

    the server name is wrong in the sql connection. it should not be RS_MSSQLSERVER it should be just MSSQLServer. RS_ should be used only in wminamespace. If you just use Server=CHITTARANJAN\\MSSQLSERVER it will solve this issue.

    Regards,
    Bharath R S

    ReplyDelete
  3. Bharath,

    I've followed al your steps, I've double checked the set of instructions and I get the following error:

    An error occurred while attempting to add the account. A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)

    I too, like Chitta put RS_ in front of my Server Instance, however, I've now changed them and I still have the same error.

    using (SqlConnection conn = new SqlConnection(
    "Server=asif-laptop/ReportServer_SQLSERVER2012;" +
    "Integrated Security=SSPI;" +
    "database=UserAccounts"))

    Thanks

    ReplyDelete
  4. Hi Asif,

    The server name is written as asif-laptop/ReportServer_SQLSERVER2012
    is your sql server name ReportServer_SQLSERVER2012? or is it just SQLSERVER2012? IF you change that then this should work.

    Regards,
    Bharath RS

    ReplyDelete
  5. Hi Bharath,

    It is indeed ReportServer_SQLSERVER2012, confirmed through RS Config Manager with the web url.

    Thanks

    ReplyDelete
  6. Hi Asif,

    The connection is used to connect to the database server and not the report server. Please use the database server name there.

    Regards,
    Bharath R S

    ReplyDelete
  7. Hi Bharath,

    Thank you, I completely missed the boat there :)

    I have a second issue that I've been looking into. It says:

    An error occurred while attempting to add the account. Cannot open database "UserAccounts" requested by the login. The login failed. Login failed for user 'NT SERVICE\ReportServer$SQLSERVER2012'.

    I checked through logins on my server, I don't have anything for NT SERVICE\ReportServer$SQLSERVER2012 rather, NT SERVICE\MSSQLSERVER.

    I've looked through the references within the config files and I can only seem to find NT Service\ReportServer$SQLSERVER2012 within the rsreportserver.config file and no other references.

    Thank you for your support, much appreciated.

    ReplyDelete
  8. Hi Asif,

    The issue might be with credentials the RS is passing to the database which will not rights over the new database UserAccounts.

    Instead of using Integrated Security in the connection string you can provide the username and password which has access to the database.

    Regards,
    Bharath R S

    ReplyDelete
  9. Hello Bharath,

    I finally got it working with various adjustments. I now want to move over the sample and hook it up to my Users database.

    Currently only one user can be authorised to access the reports as specified here:





    Bharath_RS





    How could I set the config file to accept any valid user within my DB?

    Thanks

    ReplyDelete
    Replies
    1. <'Configuration>
      <'AdminConfiguration>
      <'UserName>Bharath_RS
      <'/AdminConfiguration>
      <'/Configuration>
      <'/Extension>
      <'/Security>

      How bizarre, it missed out the XML format, so I just escaped any interpreters.

      Delete
    2. Hi, have you figured out how to allow other users instead of just one user? I'm in the same boat as you are. Thanks!

      Delete
    3. Hi Sleek,

      You can configure multiple user, the above config is used to provide a default admin, Once you have the forms authentication up then you can see two buttons one is for login other is to register. Register other users and provide them Admin rights or normal user rights based on the requirement.

      Delete
    4. Hi Bharath,

      I did register other users and I saw new records were inserted on the [users] table. But still only the user defined in the config is the only one who can view the report. If I change the user in config to another user, let's say "Bob", then only the user Bob can view the report.

      Thanks

      Delete
    5. Hi,

      The reason being you have not assigned any roles or access to the folders in the SSRS manager. If you provide the permissions they can go ahead and run the reports.

      Regards,
      Bharath R S

      Delete
    6. Hi,

      It's working now! Thanks! You're right, we just added users to the report folder in SSRS manager and they were able to access and generate the reports now.

      Joe

      Delete
  10. Hi Asif,

    For in the initial set up only one user can be the authorized to access the reports who will be the admin, but you can go ahead and register users in the portal and then you can go ahead make the registered user as a ADmin or a read only person.

    ReplyDelete
  11. I am currently getting the error: Could not load file or assembly 'ReportingServicesWebServer' or one of its dependencies. The parameter is incorrect. Any ideas? I can't figure it out.

    ReplyDelete
  12. Hi Rabid,

    There can be many reasons for it.
    One of the reasons might be due to the Report Server dll file.
    Copy the Reporting Service dll file from the Report Server bin directory and use the same when you build the solution and the put the dll generated into the reportserver and report manager folder.

    ReplyDelete
  13. I'm not sure what you mean. The only Reporting Services dll my project references is "Microsoft.ReportingServices.Interfaces" which I grabbed from the ReportManager/bin folder. Then after building my project I copied the dll to both the ReportManager and ReportServer bin.

    If you wish to see the exact error that Reporting Services is logging I can post it or send it to you. I would be very grateful if you had an answer to this problem as I've been trying to figure this out for days lol.

    ReplyDelete
  14. Yup thats the dll which I was talking about. In that case I suggest you to redo the entire procedure once again. If it does not work please forward the log file to me will have a look at it. Also send across the other files which you have edited will have a look at it.

    ReplyDelete
  15. Do you have an email address that you would like me to send the files too? And thanks a lot for your help! I've been pulling my hair out over this.

    ReplyDelete
  16. Thanks again! I've just sent you a zip file containing my project and config files.

    ReplyDelete
  17. Have you been able to figure anything out with the code and config files i sent yet? Thanks!

    ReplyDelete
  18. Hi Bharath,

    I have Implemented the sample as you mention but I am getting Service Unavailable Error. When i tried to re start the "SQL reporting services" I am getting time out exception and service is not triggered. Please clarify me regarding this. I removed the time out entry "
    " in the report server web config and then able to start the server. But still then I am getting the same service unavailable error. Please clarify me regarding this.

    Thanks,
    Darsan.

    ReplyDelete
  19. Hi Bharath,

    AFter trying serveral times, I am getting the below error Webservice url of report server.

    The report server encountered an unhandled exception in HttpApplication. (rsUnhandledHttpApplicationError) Get Online Help
    Could not load the assembly 'Microsoft.Samples.ReportingServices.CustomSecurity'. Make sure that it is compiled before accessing the page.
    Could not load the assembly 'Microsoft.Samples.ReportingServices.CustomSecurity'. Make sure that it is compiled before accessing the page.
    Could not load the assembly 'Microsoft.Samples.ReportingServices.CustomSecurity'. Make sure that it is compiled before accessing the page

    ReplyDelete
    Replies
    1. This comment has been removed by the author.

      Delete
  20. Hi Darshan,

    I was unable to reply for the past few days because of work.
    Saw your mail, there will be something wrong in the configuration, check if all the tags are proper and also if you have declared the custom security framework in the Report server configuration file. Also if you are using the correct microsoft interface dll file which is present in the bin folder of report server folder. Let me know if you are still facing the same issue.

    Regards,
    Bharath R S

    ReplyDelete
  21. This comment has been removed by the author.

    ReplyDelete
  22. Hi Bharath,

    Thank you for response. I cross checked the configuration twice and everything is perfect. "Check if you have declared custom security framework"?? I think you mean the below configuration
    Security
    Extension Name="Forms" Type="Microsoft.Samples.ReportingServices.CustomSecurity.Authorization,Microsoft.Samples.ReportingServices.CustomSecurity"
    ......Authentication
    I am using the correct dll which is inside the report server instance directory. I have tried the same by installing different instance of SSRS also. But I am facing the same Issue. The only part in which I feel I would ve missed something is Step 3 to Step 5. And also I am not sure whether the sample will run in 64 bit operating systems. Please provide me your ideas for implementing this. Thank you very much.

    ReplyDelete
  23. Hi Bharath,

    If possible could you please mail me the sample you..

    Thanks,
    Darsan.

    ReplyDelete
  24. Hi Darshan,


    Send across your config files. Will have a look at it next week.

    Regards,
    Bharath R S

    ReplyDelete
  25. This comment has been removed by the author.

    ReplyDelete
  26. Hi,
    I implemented the forms authentication sample using custom security extension. Single sign on is working fine..I deployed few reports in report server. When trying to check out the reports i am getting the below error
    "An error has occurred during report processing. (rsProcessingAborted)
    Cannot impersonate user for data source 'AdSource'. (rsErrorImpersonatingUser)
    This data source is configured to use Windows integrated security. Windows integrated security is either disabled for this report server or your report server is using Trusted Account mode. (rsWindowsIntegratedSecurityDisabled)"

    I found few sources that since the authentication type is configured as Integrated security I am getting the above error. So, I again installed a new instance of reporting server with mixed mode authentication(Initially i installed report server with windows authentication mode only since I read somewhere that the custom security extension only works when report server is initially configured as Windows authentication,, not sure how far this is true). I made the configuration and code changes and when trying to restart the service. The service is not started. Please advise.

    Thanks.

    ReplyDelete
  27. Hi Darshan,
    you need to configure the credentials to the data source
    select Credentials stored securely in the report server
    Provide User name and password
    click on Use as Windows credentials when connecting to the data source

    Click on test connection and if it says Connection successful then click on apply and it should work fine now.

    ReplyDelete
  28. Hi Bharath,

    I am not able to add multiple users. Please help.

    Arijit

    ReplyDelete
  29. Hi Arijit,

    You need to register user and then provide them access to the reports.

    Bharath

    ReplyDelete
    Replies
    1. Will I do it in Site Settings -> New Role Assignment ? Not sure actually !

      Delete
  30. Yes, you need to do this and give access to the user on the folder which you have deployed the reports.

    ReplyDelete
  31. Hi Bharath,

    Do we really need to create a user accounts database? since i am using the reportserver database and validating the user and I am getting an error "Authorization ticket not received by LogonUser"

    1. I am passing the user information in query string and validate the user information and redirect
    2. I am not getting any message even i put response.write line by line.

    Please let me know if you could help


    ReplyDelete
    Replies
    1. Hi Nathan,

      If you are using Forms authentication mode then yes you need accounts database. When I mean accounts database there is a table which stores the user id and password+ has the sql stored procedures. If you can include these in different database then no need of creating a new database. The reason is in Windows AD the security framework validates the user against the AD but here it needs to validate against the user stored in the database and not in the AD. So we need these tables.

      Delete
  32. This comment has been removed by the author.

    ReplyDelete
    Replies
    1. I am getting Input string error when I try to login via application, after I register the account.Please advise me where am I going wrong.

      Input string was not in a correct format.
      Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

      Exception Details: System.FormatException: Input string was not in a correct format.

      Source Error:

      An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

      Stack Trace:


      [FormatException: Input string was not in a correct format.]
      System.Text.StringBuilder.AppendFormat(IFormatProvider provider, String format, Object[] args) +10063798
      System.String.Format(IFormatProvider provider, String format, Object[] args) +89
      Microsoft.Samples.ReportingServices.CustomSecurity.UILogon.BtnLogon_Click(Object sender, EventArgs e) +1161
      System.Web.UI.WebControls.Button.OnClick(EventArgs e) +115
      System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +140
      System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +29
      System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2981



      Delete
    2. Hi,

      Are you using the login.aspx provided by microsoft or have you created your own custom login page? If you are using the login page let me know the way you have configured the database connection in the config files.

      Delete
  33. 0 down vote favorite


    I want to verify the username and password from the Local Database not from Reporting Server database. I have configured Reporting Server and Manager in SSRS 2008 R2.

    The Report Server is able to Login with the username and password from the Local Database, but the Report Manager it is showing the Error Message as "Authorization ticket not received by LogonUser".

    How can i resolve this issue in Windows Server 2008

    ReplyDelete
    Replies
    1. Hi,

      If you want to use local database there are two approaches:
      a) You go ahead and make sure the encryption of the pwd and the salt length is same as in the SSRS forms authentication code then you need to just point to the database and make sure you change the table name in the code to point to your local database.
      b) If you are using different encryption then go ahead and modify the authentication mode to use the same encryption as yours.

      Hopefully I have answered your question.

      Delete
  34. This blog helped a lot but I still struggled to get it working. I thought I'd add a couple of things I learned for those having the same problem.

    1. If you keep getting a invalid namespace error. You can look in Reporting Services\ReportServer\bin\reportingservices.mof file for the namespace. For me it was \root\Microsoft\SqlServer\ReportServer\RS_MSSQLSERVER\V12 in SQL Server 2013
    2. When you switch to forms based auth everything switches. You need to re-setup your data connections for reports as they won't work with windows auth anymore (same with deployments).
    3. The user you configure in RSReportServer.config is a forms based user which will be the admin

    ReplyDelete
  35. Hi Ajit,

    Thanks for your feedback. Yes I had not mentioned the first point, thanks for bringing this up.

    ReplyDelete
  36. hi bharath, I can register the username and password and it is getting stored in the database. After that, when try to log in using the saved username and password, it is throwing error: "An error occured while attempting to get the report server url."

    ReplyDelete
  37. I downloaded the sample for formsauthentication from MSDN and build the DLL's and deployed it on our server and made all necessary config changes as per the steps in document. I am good with registering the user and can see the username registered getting saved in the database.
    I am having issue while logging in with the user registered. It is throwing the below exception. Can you please review and help with this issue
    Exception Details
    An error occured while attempting to get the ReportServer Url. Not found
    System.Exception: An error occurred while attempting to get the ReportServer Url. Not found ---> System.Management.ManagementException: Not found
    at System.Management.ManagementException.ThrowWithExtendedInfo(ManagementStatus errorCode)
    at System.Management.ManagementObject.Initialize(Boolean getObject)
    at System.Management.ManagementBaseObject.get_wbemObject()
    at System.Management.ManagementBaseObject.get_ClassName()
    at System.Management.ManagementClass.GetInstances(EnumerationOptions options)
    at Microsoft.Samples.ReportingServices.CustomSecurity.AuthenticationUtilities.GetReportServerUrl(String machineName, String instanceName)
    --- End of inner exception stack trace ---
    at Microsoft.Samples.ReportingServices.CustomSecurity.AuthenticationUtilities.GetReportServerUrl(String machineName, String instanceName)
    at Microsoft.Samples.ReportingServices.CustomSecurity.UILogon.BtnLogon_Click(Object sender, EventArgs e)

    ReplyDelete
  38. I downloaded the sample for formsauthentication from MSDN and build the DLL's and deployed it on our server and made all necessary config changes as per the steps in document. I am good with registering the user and can see the username registered getting saved in the database.
    I am having issue while logging in with the user registered. It is throwing the below exception. Can you please review and help with this issue
    Exception Details
    An error occured while attempting to get the ReportServer Url. Not found
    System.Exception: An error occurred while attempting to get the ReportServer Url. Not found ---> System.Management.ManagementException: Not found
    at System.Management.ManagementException.ThrowWithExtendedInfo(ManagementStatus errorCode)
    at System.Management.ManagementObject.Initialize(Boolean getObject)
    at System.Management.ManagementBaseObject.get_wbemObject()
    at System.Management.ManagementBaseObject.get_ClassName()
    at System.Management.ManagementClass.GetInstances(EnumerationOptions options)
    at Microsoft.Samples.ReportingServices.CustomSecurity.AuthenticationUtilities.GetReportServerUrl(String machineName, String instanceName)
    --- End of inner exception stack trace ---
    at Microsoft.Samples.ReportingServices.CustomSecurity.AuthenticationUtilities.GetReportServerUrl(String machineName, String instanceName)
    at Microsoft.Samples.ReportingServices.CustomSecurity.UILogon.BtnLogon_Click(Object sender, EventArgs e)

    ReplyDelete
    Replies
    1. Hi,

      Can you please check
      1) if you have added the proper reportserver url in all the places?
      2) if the v11 change is made
      3) make sure the dll which you need to add into the solution is correct.

      I was also intially stuck for 1 month with this issue. The best thing to do is to redo the whole thing rather than debugging.

      Let me know if you need more help.

      Delete
  39. Hi
    I am getting "An error occurred while attempting to get the ReportServer Url. Invalid parameter" ,whenever I log on in Report Manager Page. I am using SERVERNAME\\MSSQLSERVER in sql connection string and my wmi namespace is @"\root\Microsoft\SqlServer\ReportServer\RS_MSSQLSERVER\v11" How can I fix that error?

    ReplyDelete
  40. At the same time, I can't log in to Reporting Services via SSMS.

    ReplyDelete
  41. Are you using SQL Server 2012? if then check for the reportserver name. I usually got this when the report server name was not configured properly.

    ReplyDelete
  42. Hi Sir,
    I 've checked but the error still exists. Is the configuration file?
    Connecting to report server fails too. How can I fix it? I have followed every steps mentioned above.
    Thank you. I was having this error for weeks and can't proceed any further.

    ReplyDelete
  43. Hey Bharath,

    I am trying to use the forms authentication with Active Directory but once i logged in i am getting user do not have permissions. Can you help me with that.

    Thanks

    ReplyDelete
  44. Bharath,

    How to provide permissions to the folders in the Report Manager for the users created .

    Thanks

    ReplyDelete
  45. hello

    I have implemented the custom authentication.
    How can I launch the explorer and view the report directly.
    the request url is http://localhost/Reports/Pages/Report.aspx?ItemPath=%2fFOLDERNAME%2fReportNAme

    ReplyDelete
  46. This comment has been removed by the author.

    ReplyDelete
  47. if i put Servername\RS_MSSQLSERVER it show unrecognised escape sequence i am not able to build the solution so i put one more slah ServerName\\RS_MSSQLSERVER now i am able to build so after performing all the above steps i got the UILogon screen and i am not able to register user it shows the error Keyword not supported: 'Servername\\rs_mssqlserver;integrated security'.

    ReplyDelete
  48. Guidelines to Solve MS SQL Server Error 40 through Microsoft SQL Server Support
    The Error 40 in MS SQL Server connotes "Couldn't open a relationship with SQL Server" this sort of botch has happened while you setting up a relationship with the server while interfacing with SQL Server 2005. This kind of issue generally cause by the under default setting SQL Server does not allow remote affiliation. If you have to deal with this issue by then contact to Online MS SQL Server Support or Remote Infrastructure Management Support for Microsoft SQL Server.
    For More Info: https://cognegicsystems.com/
    Contact Number: 1-800-450-8670
    Email Address- info@cognegicsystems.com
    Company’s Address- 507 Copper Square Drive Bethel Connecticut (USA) 06801

    ReplyDelete
  49. Hello, I am stuck on the Could not load the assembly 'Microsoft.Samples.ReportingServices.CustomSecurity'. Make sure that it is compiled before accessing the page.
    Could not load the assembly 'Microsoft.Samples.ReportingServices.CustomSecurity'. Make sure that it is compiled before accessing the page and have used same configs in other servers with no issue. Can anyone advise the resolution for this ?

    ReplyDelete
  50. Hello Bharath,

    Please let me know, If form authentication will support in ssrs 2019 ?

    Reach me out on mainoddin2010@gmail.com, I have some requirement for you.

    Hope ,You will contact me soon.

    Thanks

    ReplyDelete