[Koha-bugs] [Bug 31393] Shibboleth broken since migration from XML::Simple

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Jun 23 05:01:54 CEST 2023


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31393

--- Comment #6 from David Cook <dcook at prosentient.com.au> ---
Created attachment 152609
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=152609&action=edit
Bug 31393: Use _content as a placeholder when parsing koha-conf.xml

This patch uses '_content' instead of 'content' as a placeholder
when parsing koha-conf.xml, so that elements with a "content"
attribute don't get parsed incorrectly (like with shibboleth config).

Test plan:
0. Apply patch
1. echo 'flush_all' | nc -q 1 memcached 11211
2. koha-plack --reload kohadev
3. Add Shibboleth config to koha-conf.xml
 <shibboleth>
   <matchpoint>userid</matchpoint> <!-- koha borrower field to match upon -->
   <mapping>
     <userid is="eduPersonID"></userid> <!-- koha borrower field to shibboleth
attribute mapping -->
     <branchcode content="foo"/>
   </mapping>
 </shibboleth>
4. vi Koha/Config.pm
5. Dump out the $config from the read_from_file() function
6. Note that the following is shown:
'branchcode' => {
               'content' => 'foo'
             }
7. Note that the following is NOT shown:
'branchcode' => 'foo'
8. git restore Koha/Config.pm
9. Rejoice!

For bonus points, you can actually do a full SAML test and make sure
the Shibboleth integration works as expected

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.


More information about the Koha-bugs mailing list