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.

Error on the server side : Cannot read property 'SAMLResponse' of undefined

See original GitHub issue

Hey there ! I am trying to sort my onelogin sso authentification following this example : https://samlify.js.org/#/onelogin

I’m a bit confused by this bit :

router.get('/spinitsso-redirect', (req, res) => {
    const url = sp.createLoginRequest(idp, 'redirect');
    return res.redirect(url);
});

The “url” returned is actually an object ? I had to do url.context to get the url back

I am now trying to access myurl/sso/spinitsso-redirect but getting the following error : TypeError: Cannot read property 'SAMLResponse' of undefined

Any ideas why ? Am I missing something ?

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:1
  • Comments:16 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
tngancommented, Dec 14, 2017

Then I guess you need the body-parser middleware, (https://www.npmjs.com/package/body-parser) when you receive and parse the POST/ response from the onelogin side.

0reactions
hackintoshsacommented, Aug 8, 2019

@Antho2407 I need help @tngan i need help, wanted to run this but keep getting this error TypeError: Cannot read property ‘SAMLResponse’ of undefined

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cannot read property 'on' of undefined? -> ERROR
I want my server.js to contact with the client.js (there's nothing written in it) and run as a normal server! Every advice is...
Read more >
Troubleshooting SAML 2.0 federation with AWS
This error can occur when the SAML response from the identity provider does not include an attribute with the Name set to https://aws.amazon.com/SAML/Attributes ......
Read more >
Troubleshoot single sign-on (SSO) - Google Support
This document provides steps to resolve common error messages encountered during the integration or use of SAML-based single sign-on (SSO) with Google ...
Read more >
Common Issues with SAML Authentication - Blackboard Help
The IdP signs the SAML response with a certificate that is not issued by a valid certificate authority, and the SP's keystore doesn't...
Read more >
NowSupport Public Knowledge Base Articles - Page 17
TypeError: Cannot read property 'style' of undefined function on ... MID Server Down - StartupSequencer SEVERE *** ERROR - Could Not Authenticate User....
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