question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unable to validate data - Error logging into the SSRS Portal

See original GitHub issue

Hi guys, I’m getting an error running the SSRS Portal after configuring CustomAuthentication (as per example provided in the repository) from Reporting Services Custom Security Sample for Power BI Report Server and SQL Reporting Services 2017

The issue is regarding MachineKey as seen from the error logs. I’m following all the instructions given in the above sample but still no luck yet.

I’m running the SSRS 2017 on my Dev PC (Win 10 Pro).

The custom login works well (Register and Login) for the report server at: http://localhost/ReportServer_SSRS, but the portal (http://localhost/Reports) doesn’t work after Login. It returns the 500 Internal Error message. Stack trace is given below:

Exception: System.Web.HttpException (0x80004005): Unable to validate data.
   at System.Web.Configuration.MachineKeySection.EncryptOrDecryptData(Boolean fEncrypt, Byte[] buf, Byte[] modifier, Int32 start, Int32 length, Boolean useValidationSymAlgo, Boolean useLegacyMode, IVType ivType, Boolean signData)
   at System.Web.Security.FormsAuthentication.Decrypt(String encryptedTicket)
   at Microsoft.BIServer.Owin.Common.Middleware.CustomAuthenticationMiddleware.CreateRequestContextFromCookie(IOwinContext context)
   at Microsoft.BIServer.Owin.Common.Middleware.CustomAuthenticationMiddleware.CreatePortalIdentity(IOwinContext context)
   at Microsoft.BIServer.Owin.Common.Middleware.CustomAuthenticationMiddleware.Invoke(IOwinContext context)
   at Microsoft.Owin.Security.Infrastructure.AuthenticationMiddleware`1.<Invoke>d__0.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Microsoft.BIServer.Owin.Common.Middleware.RequestLoggingMiddleWare.<Invoke>d__2.MoveNext() | RequestID = s_562e4f17-7d98-45e0-b744-02509f01e0d8 

RsReportServer.config file is attached here for reference rsreportserver.config.txt

Please suggest if there’s anything wrong in the configuration, or I’m missing out on something. Or probably a bug in the operating environment?

Thanks in advance!

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5

github_iconTop GitHub Comments

1reaction
ravipunjwanicommented, Nov 20, 2018

Thanks @manceelee for suggestion.

It actually worked by adding the following into rsportal.exe.config

  <system.web>
    <machineKey validationKey="xxxxxx" decryptionKey="xxxxxx" validation="AES" decryption="AES" />
  </system.web>

I guess it should have imported the machine key from the reporting service instead of getting from own configuration file.

0reactions
TestO2015commented, Nov 11, 2022

Hi @n1LWeb, have you added your machineKey to rsReportServer.config under <configuration>?

Also make sure it’s in the correct format otherwise it get’s wiped for me.

<MachineKey ValidationKey="BE4663BB11C14E8C7C1DB0A48022D517CB668C65A46174B0C4CFF4D9B7CE2498EA998C4E5A8C15EE5262D5C297479349B2A9783700AB3C1C891B914D12691A0D" DecryptionKey="7121FD4D52F0035DBBB113B9E449ED4467CA01DDD26684FF" Validation="SHA1" Decryption="AES"/>

After this restart the Report Server and it should sync the machineKey to rsportal.exe.config.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Unable to validate data - Error logging into the SSRS Portal
Hi guys, I'm getting an error running the SSRS Portal after configuring CustomAuthentication (as per example provided in the repository) ...
Read more >
Forms authentication machineKey "unable to validate data ...
Forms authentication machineKey "unable to validate data" error in SSRS · Using SQL Server Management Studio check the log files in the explorer ......
Read more >
ConfigMgr and Reporting Services, SSRS, unable to validate ...
When browsing to the Report Service URL we got HTTP 500 Internal Server error and the message contained “Unable to validate data”. Double...
Read more >
Hi I am unable to open SSRS web portal link
According to your log, it seems that the error is not found. Have you configured the SSRS web portal URL correctly? https://learn.microsoft.com/ ...
Read more >
Can't open a Reporting Services report from the SSRS ...
Fixes an issue that prevents you from opening a Reporting Services report from the SSRS portal when the host computer has FIPS compliance...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found