Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The ultimate Microsoft Fabric, Power BI, Azure AI & SQL learning event! Join us in Las Vegas from March 26-28, 2024. Use code MSCUST for a $100 discount. Register Now

Reply
teros
Helper I
Helper I

PBIRS (March 2018 release) with custom security sample - error

I'm trying to configure the March 2018 PBIRS release to use custom authentication. We have the October 2017 release working fine, but need to move to the latest version. If I customize the March 2018 release with the default configuration as specified in the ReadMe.md, it works properly. I can register new users and log into the PBIRS server through the logon.aspx page. However, our forms authentication requirements are a bit more complicated than that.

 

We are displaying embedded Power BI reports in our existing form-authenticated application, so rather than using the default PassThroughCookies specified for rsreportserver.config, we use the following:

 

          <PassThroughCookies>
            <PassThroughCookie>.ASPXAUTH</PassThroughCookie>
          </PassThroughCookies>

 

Similarly, in web.config, instead of the "forms" configuration with "logon.aspx" and "sqlAuthCookie", we point to our application login:

 

  <forms timeout="120" domain=".productiondomain.com" cookieless="UseCookies" enableCrossAppRedirects="true" name=".ASPXAUTH" loginUrl="http://formsLogin.productiondomain.com" />

 

The server seems to start properly, with no errors in any of the log files -- until I attempt to access the PBIRS portal (https://pbirs.productiondomain.com/Reports). The access attempt results in an HTTP 500 error on my browser, and the following error in the RSPortal log file:

 

2018-06-20 16:33:17.4985|ERROR|5| 192.168.32.221: GET /browse/ - 0:00:00.0315727
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_8746993e-6fe4-4a0d-84d3-ff0d3256c9cc

 

With the October 2017 release of PBIRS and the old version of the CustomSecuritySample, things worked just fine. Using the March 2018 release of PBIRS with either the old version or current version of CustomSecuritySample with our additional customizations fails.

1 ACCEPTED SOLUTION
teros
Helper I
Helper I

Problem solved -- I needed to make sure that the MachineKey value for PBIRS was the same as the one for our forms-authenticated application.

 

Whew!

View solution in original post

6 REPLIES 6
bvenu2712
Helper I
Helper I

Hi @teros

 

I am new to the Power BI Report Server and looking for the steps to share reports/dashboard with external users who are not part of our domain.

 

Did you implement custom security both for internal and external users? appreciate, if you could provide step by step process in implementing custom security.

 

Thanks,

Venu Bolla

Anonymous
Not applicable

Hello @bvenu2712

 

Could you configure the PBIRS to accept external users? I have the same problem as you.

 

In my envirorment I have intalled the Power BI Report Server and I'm trying to embed the application in sharepoint with external user authentication.

 

Did your configuration works?

Thanks

Hi @Anonymous

 

No, we are going with Power BI cloud. Still I am looking for the steps on Report server.

 

Thanks,

Venu Bolla

Anonymous
Not applicable

Hello @bvenu2712

 

Could you configure the PBIRS to accept external users? I have the same problem as you.

 

In my envirorment I have intalled the Power BI Report Server and I'm trying to embed the application in sharepoint with external user authentication.

 

Did your configuration works?

Thanks

teros
Helper I
Helper I

Problem solved -- I needed to make sure that the MachineKey value for PBIRS was the same as the one for our forms-authenticated application.

 

Whew!

Anonymous
Not applicable

Can you please elaborate the answer ?

Helpful resources

Announcements
Fabric Community Conference

Microsoft Fabric Community Conference

Join us at our first-ever Microsoft Fabric Community Conference, March 26-28, 2024 in Las Vegas with 100+ sessions by community experts and Microsoft engineering.

February 2024 Update Carousel

Power BI Monthly Update - February 2024

Check out the February 2024 Power BI update to learn about new features.

Fabric Career Hub

Microsoft Fabric Career Hub

Explore career paths and learn resources in Fabric.

Fabric Partner Community

Microsoft Fabric Partner Community

Engage with the Fabric engineering team, hear of product updates, business opportunities, and resources in the Fabric Partner Community.