Error CAS after saving configuration
Error CAS after saving configuration
Hi FD team,
In 1.4, after saving configuration, a new parameter appears in cn=config:
fdCasLibraryBool: FALSE
And once the current session expire, or if user disconnect, the CAS connection does not work anymore:
phpCAS error: phpCAS::client(): CAS_TypeMismatchException: type mismatched for parameter $changeSessionID (should be 'boolean '), string given. in /usr/local/share/fusiondirectory/include/login/class_LoginCAS.inc on line 53
This parameter is not read correctly by FusionDirectory: the value FALSE/TRUE in OpenLDAP is not read/passed as PHP boolean.
The only way to get the SSO to work again is to delete the atttribute fdCasLibraryBool.
Link issues together to show that they're related. Learn more.
Activity
- bmortier changed milestone to %FusionDirectory 1.4
changed milestone to %FusionDirectory 1.4
Hi @sfroger,
Could you please share with us your file :
/usr/local/share/fusiondirectory/include/login/class_LoginCAS.inc
It seems we do not have the same variable's name, and I am afraid you possess a wrong version or unofficial one.
Thank you.
By dockx thibault on 2023-05-02T15:35:25 (imported from GitLab)
- bmortier changed milestone to %FusionDirectory 1.5
changed milestone to %FusionDirectory 1.5
os version:
Distributor ID: Debian Description: Debian GNU/Linux 11 (bullseye) Release: 11 Codename: bullseye
PHP version:
PHP 7.4.33 (cli) (built: Feb 22 2023 20:07:47) ( NTS ) Copyright (c) The PHP Group Zend Engine v3.4.0, Copyright (c) Zend Technologies with Zend OPcache v7.4.33, Copyright (c), by Zend Technologies
PhpCas library version:
php-cas/stable,now 1.3.8-1 all [installed] Central Authentication Service client library in php
FD and class_LoginCAS.inc is the version at commit 5b01ee0f. Before opening this ticket, I updated FusionDirectory at the latest of 1.4-dev to make sure the bug had not been fixed since we first install it (early march), because it breaks CAS auth after you save configuration.
By sfroger on 2023-05-04T07:57:48 (imported from GitLab)
Hi @sfroger,
Thank you for your clarification and provided info.
My query about giving me your class_LoginCAS.inc is because the variable you mention :$changeSessionID
, simply does not exist within FusionDirectory. Not in our GitLab sources nor GitHub.The error message you receive :
phpCAS error: phpCAS::client(): CAS_TypeMismatchException: type mismatched for parameter $changeSessionID (should be 'boolean '), string given. in /usr/local/share/fusiondirectory/include/login/class_LoginCAS.inc on line 53
is very peculiar because at line 53 in all our sources we have the following : $config->get_cfg_value('CasClientServiceName')Edit 1 : Although the error might be reported by the library itself, its reported error on "line 53" is confusing.
Now, it does not mean that the error behavior you are reporting is wrong, it's been seen several times that a BOOL is actually seen as STRING while being processed. It might be an easy fix, and I am currently installing necessities to reproduce your problem.
When you say "update to the latest", seeing your installation to
/usr/local/share
I am guessing that you are actually updating directly from the sources (manually) and not via our repositories.Kind regards, Thibault.
By dockx thibault on 2023-05-04T08:43:33 (imported from GitLab)
Edited by bmortier- bmortier added 5m of time spent
added 5m of time spent
By dockx thibault on 2023-05-04T08:41:24 (imported from GitLab)
changeSessionID exists in the PhpCAS library. I agree the error sounds like it is hapening within FD, but it's in fact happening in the PHPCas library because of wrong type given by FD.
You guessed right, we are using 1.4 from source as our clients needs the new REST webservice, and can't wait to be able to deploy it from your repositories. Keep up with the good work !
By sfroger on 2023-05-04T09:02:41 (imported from GitLab)
- bmortier changed milestone to %FusionDirectory 1.4
changed milestone to %FusionDirectory 1.4
- bmortier created branch
6276-error-cas-after-saving-configuration
to address this issuecreated branch
6276-error-cas-after-saving-configuration
to address this issueBy dockx thibault on 2023-05-04T15:29:18 (imported from GitLab)
- bmortier mentioned in merge request !1042
mentioned in merge request !1042
By dockx thibault on 2023-05-04T15:30:01 (imported from GitLab)
- bmortier added 5h of time spent
added 5h of time spent
By dockx thibault on 2023-05-04T15:41:48 (imported from GitLab)
- bmortier closed
closed
- bmortier added Bugs PJ1802-0188 fusiondirectory-core labels
added Bugs PJ1802-0188 fusiondirectory-core labels