derricksmith / phpsaml

GLPI Plugin - SAML integration using the Onelogin SAML Library
MIT License
32 stars 24 forks source link

Cannot modify header information headers already sent by ... #149

Open jbtele29 opened 1 year ago

jbtele29 commented 1 year ago

Hello,

I have this error in php log on my glpi

[2023-09-28 17:16:01] glpiphplog. WARNING: *** PHP Warning (2): Cannot modify header information - headers already sent by (output started at /var/www/html/glpi/plugins/phpsaml/hook.php:113) in /var/www/html/glpi/front/inventory.php at line 110 Backtrace : front/inventory.php:110 header() ...tplace/glpiinventory/front/communication.php:72 include_once() marketplace/glpiinventory/index.php:45 include_once() public/index.php:82 require()

I use glpi-agent 1.5 and glpi 10.0.9

Thanks

DonutsNL commented 11 months ago

Please use the latest version in my repository: https://github.com/DonutsNL/phpsaml. It has various excludes for the latest inventory agents not present in this version of the plugin. Rgrds,

jbtele29 commented 11 months ago

Hello, thanks for update but i still have same problem after upgrade with your latest version [2023-12-26 11:04:08] glpiphplog.WARNING: *** PHP Warning (2): Cannot modify header information - headers already sent by (output started at /var/www/html/glpi/plugins/phpsaml/hook.php:115) in /var/www/htm> Backtrace : front/inventory.php:112 header() ...tplace/glpiinventory/front/communication.php:72 include_once() marketplace/glpiinventory/index.php:45 include_once() public/index.php:82 require()

DonutsNL commented 11 months ago

Sorry this is my bad.

I forgot to comment out some debugging lines in the partially implemented rule engine code. I commented out the problematic code. This should solve the problem. Be aware that the rules for assigning user properties is not yet implemented and will not yet work. Best not to create phpsaml rules at this moment.