Forums | Mahara Community

Support /
need help with mahara simplesamlphp SAML2 intergration


shpetim aliaj's profile picture
Posts: 6

28 April 2023, 1:38

Hi All,

 

I am trying to port mahara authentication to SAML.

I finished setting the requirements for the plugin, but having issues filling the field required on the wizard for the SAML.

Does anyone has notes for how to do the config on the plugin.

 

=Tim

shpetim aliaj's profile picture
Posts: 6

16 May 2023, 10:01

Hi Guys,

 

I made some progress and put a custom field "eduPersonOrgDN" on the IDP to pass to the mahara to find the institution "Institution attribute". So i am able to create the saml2 authentication plugin configuration.

 

the issue is when i try to login i get these errrors:

[WAR] 0d (auth/saml/extlib/simplesamlphp/vendor/robrichards/xmlseclibs/src/XMLSecurityKey.php:563) openssl_sign(): supplied key param cannot be coerced into a private key

 

Call stack (most recent first):
  • log_message(string(size 71), integer, true, true, string(size 104), integer) at /var/www/html/mahara/lib/errors.php:514
  • error(integer, string(size 71), string(size 104), integer, array(size 3)) at Unknown:0
  • openssl_sign(string(size 688), null, false, string(size 6)) at /var/www/html/mahara/auth/saml/extlib/simplesamlphp/vendor/robrichards/xmlseclibs/src/XMLSecurityKey.php:563
  • RobRichards\XMLSecLibs\XMLSecurityKey->signOpenSSL(string(size 688)) at /var/www/html/mahara/auth/saml/extlib/simplesamlphp/vendor/robrichards/xmlseclibs/src/XMLSecurityKey.php:644
  • RobRichards\XMLSecLibs\XMLSecurityKey->signData(string(size 688)) at /var/www/html/mahara/auth/saml/extlib/simplesamlphp/vendor/simplesamlphp/saml2/src/SAML2/HTTPRedirect.php:65
  • SAML2\HTTPRedirect->getRedirectURL(object(SAML2\AuthnRequest)) at /var/www/html/mahara/auth/saml/extlib/simplesamlphp/vendor/simplesamlphp/saml2/src/SAML2/HTTPRedirect.php:88
  • SAML2\HTTPRedirect->send(object(SAML2\AuthnRequest)) at /var/www/html/mahara/auth/saml/extlib/simplesamlphp/modules/saml/lib/Auth/Source/SP.php:722
  • SimpleSAML\Module\saml\Auth\Source\SP->sendSAML2AuthnRequest(array(size 18), object(SAML2\HTTPRedirect), object(SAML2\AuthnRequest)) at /var/www/html/mahara/auth/saml/extlib/simplesamlphp/modules/saml/lib/Auth/Source/SP.php:704
  • SimpleSAML\Module\saml\Auth\Source\SP->startSSO2(object(SimpleSAML\Configuration), array(size 18)) at /var/www/html/mahara/auth/saml/extlib/simplesamlphp/modules/saml/lib/Auth/Source/SP.php:746
  • SimpleSAML\Module\saml\Auth\Source\SP->startSSO(string(size 59), array(size 15)) at /var/www/html/mahara/auth/saml/extlib/simplesamlphp/modules/saml/lib/Auth/Source/SP.php:844
  • SimpleSAML\Module\saml\Auth\Source\SP->authenticate(array(size 15)) at /var/www/html/mahara/auth/saml/extlib/simplesamlphp/lib/SimpleSAML/Auth/Source.php:210
  • SimpleSAML\Auth\Source->initLogin(string(size 51), null, array(size 3)) at /var/www/html/mahara/auth/saml/extlib/simplesamlphp/lib/SimpleSAML/Auth/Simple.php:169
  • SimpleSAML\Auth\Simple->login(array(size 3)) at /var/www/html/mahara/auth/saml/extlib/simplesamlphp/lib/SimpleSAML/Auth/Simple.php:111
  • SimpleSAML\Auth\Simple->requireAuth(array(size 2)) at /var/www/html/mahara/auth/saml/index.php:129
  •  

[WAR] 0d (lib/errors.php:529) [SimpleSAML\Error\UnserializableException]: Failure Signing Data: error:0907B068:PEM routines:PEM_READ_BIO_PRIVATEKEY:bad password read - SHA256 at /var/www/html/mahara/auth/saml/extlib/simplesamlphp/lib/SimpleSAML/Auth/Source.php:214

 

Please has anyone stumbled on this error before?

 

 

=Tim

Kristina Hoeppner's profile picture
Posts: 4863

16 May 2023, 13:31

Hi Tim,

What version of SAML are you using? Currently, Mahara doesn't support SAML 2.x yet.

Cheers

Kristina

Simon Mui's profile picture
Posts: 15

26 April 2024, 15:43

Hi Kristina,

I'm using SAML 2022020100, and has the same issue as Tim, may I know if this is any solution in the current state? Thanks.

 

Simon

Simon Mui's profile picture
Posts: 15

26 April 2024, 15:57

Hi All,

 

I'm able to resolve the issue by following below case's solution, thanks.

https://mahara.org/interaction/forum/topic.php?id=9329&post36780

Simon

5 results