× How To / General

SSO not working

1 month 1 day ago
Phoenix
Posts: 39
More
Topic Author
SSO not working #1
I have recently updated to Joomla 4. Initially, it seems that SSO seemed to be working through Joomdle. When I checked the menu link, I saw I was also logged in on Moodle.

Now, however, this is no longer the case. I have installed/updated some plugins along the way. Now I notice that I am no longer logged in automatically. I tried different browsers, in incognito mode, and with different accounts. No go.

The system check in the Joomdle component in Joomla is all green, no issues. I have also not changed any settings for Joomdle in either Joomla or Moodle, all remained as it was before. Both Joomla and Moodle are on the same domain.

Only the new Joomla is in a different folder from the old, which I now changed in Moodle (but initially the SSO was working, even before I changed the URL in the Joomdle settings in Moodle).

What can I do to fix this?

Thanks!

Please Log in or Create an account to join the conversation.

1 month 1 day ago
Phoenix
Posts: 39
More
Topic Author
SSO not working #2
A bit of additional information:

I use connection method CURL and have redirectless SSO disabled. It was already this way before. (I have tried to enable it, but no difference, and then disabled it again but still no difference).

Users I try with are in Joomla, Moodle and Joomdle (the 3 checkmarks).
I have tried to regenerate the token and enter that in Moodle, but no difference.

Nothing is entered into the server's error log when I log in to Joomla and go to Moodle.

Please Log in or Create an account to join the conversation.

1 month 1 day ago
Phoenix
Posts: 39
More
Topic Author
SSO not working #3
I just checked the system check again, and now I do have a red cross at Joomdle Web Services. The error says: Invalid response value detected

Web services are in both Joomla and Moodle set to REST

Please Log in or Create an account to join the conversation.

1 month 1 day ago
Phoenix
Posts: 39
More
Topic Author
SSO not working #4
I think I understand now why I was automatically logged in before: it was probably from when I logged in to my old Joomla site (in a different folder), which connected to Moodle. So I probably mistakenly thought that it was working on the new Joomla, while it probably wasn't - and it probably didn't work on Joomla 4 from the start.

My Joomla version: 4.4.6

My Joomdle version: 2.3.1

My Moodle version: 4.1.11

PHP 8.1.29

I hope this helps to find out the cause of the problem!

Please Log in or Create an account to join the conversation.

1 month 1 day ago 1 month 1 day ago by Antonio Durán.
Antonio Durán
Posts: 7754
More
SSO not working #5
Hi.

Check this first:
www.joomdle.com/wiki/System_health_check#Raw_replies k

Also make sure that your URLs are correct in Joomdle config in both Joomla and Moodle.

Please Log in or Create an account to join the conversation.

1 month 23 hours ago 1 month 23 hours ago by Phoenix.
Phoenix
Posts: 39
More
Topic Author
SSO not working #6
Hello,

Joomdle System Check XML (Joomla) gives the following:
This page contains the following errors:
error on line 8 at column 3: Encoding error
Below is a rendering of the page up to the first error.

Joomdle System Check JSON (Moodle) gives the following:
{"error":true,"code":404,"message":"Page not found"}

I have made sure the URL's are correct in both Joomla and Moodle, I checked this several times.

Please Log in or Create an account to join the conversation.

1 month 23 hours ago
Antonio Durán
Posts: 7754
More
SSO not working #7
Sorry, I have not properly updated that doc page, will do soon.

The file you need to check in Joomla is:
administrator/logs/joomdle_system_check.json

Please Log in or Create an account to join the conversation.

1 month 23 hours ago
Phoenix
Posts: 39
More
Topic Author
SSO not working #8
The Joomla /administrator/logs/ map is empty.

Please Log in or Create an account to join the conversation.

1 month 23 hours ago
Antonio Durán
Posts: 7754
More
SSO not working #9
If it is empty, it might indicate a problem connecting to the Moodle server... but you are getting an error from Moodle in the system check: Invalid server response

> {"error":true,"code":404,"message":"Page not found"}

This is what you get in Moodle when connecting to Joomla, so it seems that Moodle is not really able to open the Joomla endpoint for some reason.

Please Log in or Create an account to join the conversation.

1 month 23 hours ago
Phoenix
Posts: 39
More
Topic Author
SSO not working #10
What do I do then? The URL is correct.

Please Log in or Create an account to join the conversation.