knastase / simplesamlphp-duosecurity

Two factor authentication module using Duo Security for SimpleSAMLphp
MIT License
14 stars 7 forks source link

Undefined array key "core:SP" in duosecurity/www/getduo.php #9

Open jerrygarciuh opened 1 year ago

jerrygarciuh commented 1 year ago

It may be a peculiarity of my setup but I don't think so. Have a working vanilla service provider install of SSP 1.19 successfully functioning with DUO thanks to your module! Debian 11 Bullseye, Apache2, PHP 8.2.3.

Every time DUO UI loads I get the following logs:

PHP Warning: Undefined array key "core:SP" in /var/simplesamlphp/modules/duosecurity/www/getduo.php on line 41 simplesamlphp ERR [cf1801ee46] SimpleSAML\Error\Exception: Error 2 - Undefined array key "core:SP" at /var/simplesamlphp/modules/duosecurity/www/getduo.php:41 simplesamlphp ERR [cf1801ee46] Backtrace: simplesamlphp ERR [cf1801ee46] 3 /var/simplesamlphp/www/_include.php:44 (SimpleSAML_error_handler) simplesamlphp ERR [cf1801ee46] 2 /var/simplesamlphp/modules/duosecurity/www/getduo.php:41 (require) simplesamlphp ERR [cf1801ee46] 1 /var/simplesamlphp/lib/SimpleSAML/Module.php:266 (SimpleSAML\Module::process) simplesamlphp ERR [cf1801ee46] 0 /var/simplesamlphp/www/module.php:10 (N/A) PHP Warning: Undefined array key "core:SP" in /var/simplesamlphp/modules/duosecurity/www/getduo.php on line 41

} else if (array_key_exists('saml:sp:State', $state)) {
     $spentityid = $state['saml:sp:State']['core:SP'];
}

Happy to provide more info or test changes if desired.

trf000 commented 1 year ago

Jerry,

You might want to look here: https://github.com/SunsetDesperado/simplesamlphp-module-duouniversal

It's a more current version of this module and the developer is working with SSP to get it ready for SSP 2.0 I believe.

jerrygarciuh commented 1 year ago

Thank you!