Open jderriks opened 1 year ago
Hi there,
Simple saml question:
I added three lines to classes/auth.php to change the schacPersonalUniqueCode to a student number:
if (isset($attributes["schacPersonalUniqueCode"][0])){ $studid = $attributes["schacPersonalUniqueCode"][0]; $attributes["schacPersonalUniqueCode"][0] = preg_replace("/.*:/", "", $studid); }
So that urn:schac:personalUniqueCode:nl:local:diy.surfconext.nl:studentid:123456 becomes the number after the last colon.
But every time the plugin is updated, changes to the auth.php are gone of course.
What is the best way to filter non-standard attributes without creating extra plugins so that changes will remain intact after a Moodle update?
We need the last part of schacPersonalUniqueCode as the Moodle ID number field:
But now the ID number is the complete raw attribute name as:
Current workaround in auth.php works until the next plugin update. There must be an easier way using a config that doesn't change on updates.
Note: The example code in readme.md contains 2 syntax errors.
Hi there,
Simple saml question:
I added three lines to classes/auth.php to change the schacPersonalUniqueCode to a student number:
So that urn:schac:personalUniqueCode:nl:local:diy.surfconext.nl:studentid:123456 becomes the number after the last colon.
But every time the plugin is updated, changes to the auth.php are gone of course.
What is the best way to filter non-standard attributes without creating extra plugins so that changes will remain intact after a Moodle update?
We need the last part of schacPersonalUniqueCode as the Moodle ID number field:
But now the ID number is the complete raw attribute name as:
Current workaround in auth.php works until the next plugin update. There must be an easier way using a config that doesn't change on updates.