Forums | Mahara Community

Mahara/Moodle integration /
Networking error


Remy Olasoji's profile picture
Posts: 37

05 July 2016, 10:17 PM

Hi,

We have Mahara 15.04 installed on Ubuntu VM / Apache & PHP.. with an MNET SSO with Moodle (Moodle users are able to login to Mahara but there's no traffic the other way.

However, our SSO suddenly stopped working after some changes were made to SSL on Moodle.  To resolve the problem, I decided to delete the public key on Mahara and generate a new key but Moodle is not picking the changes up.  Reading some forum posts, I then deleted entries for openssl_history, openssl_keyrepair, openssl_keypair_expires and refreshed Administration >> Configure site >> Networking but got this error:

"A nonrecoverable error occurred. This probably means you have encountered a bug in the system"

Please help!  How can I get the networking page / section back!

Regards,

Remy

Ghada El-Zoghbi's profile picture
Posts: 121

05 July 2016, 11:23 PM

Hi Remy,

Are you able to put those records back into the tables? Perhaps from a recent database backup.

I wouldn't delete those records. What usually works for me is to copy the Moodle key (from networking) into Mahara's MNET configuration.

You may also find this post helpful.

https://mahara.org/interaction/forum/topic.php?id=7639

Please let me know how you go.

Cheers,
Ghada
Remy Olasoji's profile picture
Posts: 37

06 July 2016, 12:32 AM

Thanks Ghada.

I've actually had to roll back to the previous day's data for that table so I've got the page back now - Phew!.

Regards,

Remy

Remy Olasoji's profile picture
Posts: 37

06 July 2016, 12:35 AM

Further to this problem, I've got networking page back now but still not able to SSO from Moodle to Mahara. Adding error logging to config.php produced the following errors:

[WAR] de (api/xmlrpc/lib.php:1269) Undefined index: keypair_PEM
Call stack (most recent first):
  • log_message("Undefined index: keypair_PEM", 8, true, true, "/var/www/mahara/api/xmlrpc/lib.php", 1269) at /var/www/mahara/lib/errors.php:441
  • error(8, "Undefined index: keypair_PEM", "/var/www/mahara/api/xmlrpc/lib.php", 1269, array(size 8)) at /var/www/mahara/api/xmlrpc/lib.php:1269
  • OpenSslRepo->openssl_open() at /var/www/mahara/api/xmlrpc/lib.php:996
  • xmlenc_envelope_strip(object(SimpleXMLElement), true) at /var/www/mahara/api/xmlrpc/client.php:95
  • Client->send("https://moodle.uel.ac.uk") at /var/www/mahara/auth/xmlrpc/lib.php:103
  • AuthXmlrpc->request_user_authorise("397ff1bb84b8f63f9d71f259d771ce6da2c0702e", "https://moodle.uel.ac.uk") at /var/www/mahara/auth/xmlrpc/land.php:78
[WAR] de (api/xmlrpc/lib.php:1270) openssl_open(): unable to coerce parameter 4 into a private key
Call stack (most recent first):
  • log_message("openssl_open(): unable to coerce parameter 4 into ...", 8, true, true, "/var/www/mahara/api/xmlrpc/lib.php", 1270) at /var/www/mahara/lib/errors.php:441
  • error(2, "openssl_open(): unable to coerce parameter 4 into ...", "/var/www/mahara/api/xmlrpc/lib.php", 1270, array(size 8)) at Unknown:0
  • openssl_open() at /var/www/mahara/api/xmlrpc/lib.php:1270
  • OpenSslRepo->openssl_open() at /var/www/mahara/api/xmlrpc/lib.php:996
  • xmlenc_envelope_strip(object(SimpleXMLElement), true) at /var/www/mahara/api/xmlrpc/client.php:95
  • Client->send("https://moodle.uel.ac.uk") at /var/www/mahara/auth/xmlrpc/lib.php:103
  • AuthXmlrpc->request_user_authorise("397ff1bb84b8f63f9d71f259d771ce6da2c0702e", "https://moodle.uel.ac.uk") at /var/www/mahara/auth/xmlrpc/land.php:78
[WAR] de (api/xmlrpc/client.php:105) An error occurred while decrypting a message sent by https://moodle.uel.ac.uk. Unable to authenticate the user.
Call stack (most recent first):

Hope someone can help.

Regards,

Remy

Remy Olasoji's profile picture
Posts: 37

06 July 2016, 1:57 AM

Update

Glad to report SSO's now working between Moodle and Mahara but still unsure why it suddenly stopped. Decided to try Ghada's suggestion and manually copied the public key from Mahara to Moodle and that did the trick.

Remy

Ghada El-Zoghbi's profile picture
Posts: 121

06 July 2016, 8:32 AM

Hi Remy,

Glad to hear your Mahara is working again.  I hope you didn't lose too much data from the rollback.

It's weird because I just had the error you got about the keypair_PEM but it had to do with exporting data from Moodle to Mahara.

I've raised a bug and put in a patch yesterday. Not sure when it will be accepted and merged.

Cheers,
Ghada
Remy Olasoji's profile picture
Posts: 37

06 July 2016, 7:39 PM

Thanks Ghada.  Luckily I didn't.

Really weird and I hope the patch resolve all the problems.

Regards,

Remy

7 results