Bug 46438 - GSuite service provider metadata configuration should be replicated to all ucs-sso systems
GSuite service provider metadata configuration should be replicated to all uc...
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: Google Apps for Work
UCS 4.3
Other other
: P5 normal (vote)
: ---
Assigned To: Erik Damrose
Daniel Tröder
:
Depends on: 47309
Blocks: 47414
  Show dependency treegraph
 
Reported: 2018-02-27 15:43 CET by Erik Damrose
Modified: 2018-08-21 10:08 CEST (History)
2 users (show)

See Also:
What kind of report is it?: Bug Report
What type of bug is this?: 5: Major Usability: Impairs usability in key scenarios
Who will be affected by this bug?: 2: Will only affect a few installed domains
How will those affected feel about the bug?: 5: Blocking further progress on the daily work
User Pain: 0.286
Enterprise Customer affected?: Yes
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number: 2018020221000321
Bug group (optional):
Max CVSS v3 score:


Attachments
move update_saml_configuration code into separate script (2.22 KB, patch)
2018-08-06 16:42 CEST, Daniel Tröder
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Erik Damrose univentionstaff 2018-02-27 15:43:33 CET
see also Bug #45537

The SAML SSO metadata for the gsuite service provider (/etc/simplesamlphp/metadata.include/univention-google-apps-for-work.php) is only present on the UCS Master.

When using the "ucs-sso" DNS record to perform a SAML-login, the UCS Master *or* one of the existing UCS Backups delivers the login page. Unfortunately, all UCS Backups will complain that the SAML metadata configuration is missing and show a simplesamlphp error message about metadata not found.
Comment 1 Daniel Tröder univentionstaff 2018-02-27 15:53:44 CET
Could the relevant data be stored in LDAP and a listener module write the required files on master & backups?
I think I'd prefer that over the way SSL-certificates are distributed.
Comment 2 Erik Damrose univentionstaff 2018-02-27 16:08:44 CET
Workaround is to copy /etc/simplesamlphp/metadata.include/univention-google-apps-for-work.php to all Backups (or systems registered for ucs-sso) and include the file in the template for saml20-sp-remote.php
Comment 3 Erik Damrose univentionstaff 2018-07-19 16:30:47 CEST
f226d52f
* Replicate SAML metadata to all SSO servers by storing it in LDAP
* Store values for UCRv saml/idp/ldap/get_attributes for the app in LDAP

Package: univention-google-apps
Version: 2.0.0-6A~4.3.0.201807191630
Branch: ucs_4.3-0
Scope: univention-google-apps
Comment 4 Daniel Tröder univentionstaff 2018-07-23 16:42:54 CEST
Please make univention-google-apps depend on "univention-saml (>= 5.0.4-23)".
It may even have to be "Predepend", so that schema, listener module etc have
all been configured... not sure.
Comment 5 Stefan Gohmann univentionstaff 2018-07-23 16:44:51 CEST
(In reply to Daniel Tröder from comment #4)
> Please make univention-google-apps depend on "univention-saml (>= 5.0.4-23)".

In this case, you need to add the univention-saml package into the app repository. Otherwise, the update could fail.
Comment 6 Daniel Tröder univentionstaff 2018-07-23 16:54:53 CEST
(In reply to Stefan Gohmann from comment #5)
> (In reply to Daniel Tröder from comment #4)
> > Please make univention-google-apps depend on "univention-saml (>= 5.0.4-23)".
> 
> In this case, you need to add the univention-saml package into the app
> repository. Otherwise, the update could fail.
Could a app setting be used instead?
The app settings allow to depend on a certain UCS version. Could a patch (errata) level also be specified?
Comment 7 Erik Damrose univentionstaff 2018-07-23 16:55:46 CEST
I will add the dependency, and in addition add the required errataversion to the app metadata. That way, the update for the app will only be installable once the u-saml package is updated
Comment 8 Erik Damrose univentionstaff 2018-07-24 11:45:48 CEST
78ad0b5b Add dependency to required univention-saml version

univention-google-apps 2.0.0-7A~4.3.0.201807241145

I think it is ok to add it as Depends, not Pre-Depends. I will add the required erratalevel to the new app version. That way, the package will have to be installed before the app update is possible.
Comment 9 Erik Damrose univentionstaff 2018-07-25 10:31:12 CEST
reopen: the app update is not handled correctly, the metadata will not be replicated.
Comment 10 Erik Damrose univentionstaff 2018-07-30 13:59:58 CEST
5d1b2893 
Fix package update and metadata replication

Small refactoring: Registering the simplesaml SP config was moved to a
separate class method to allow calling only this functionality from
multiple places. It is now called on package update to move the saml
config into ldap.
Also fixed the path to the metadata template file.

univention-google-apps 2.0.0-9A~4.3.0.201807301357
Comment 11 Daniel Tröder univentionstaff 2018-08-06 16:41:10 CEST
Please move update_saml_configuration code from 40univention-google-apps.inst into separate script.
Comment 12 Daniel Tröder univentionstaff 2018-08-06 16:42:44 CEST
Created attachment 9621 [details]
move update_saml_configuration code into separate script
Comment 13 Erik Damrose univentionstaff 2018-08-08 16:19:38 CEST
41d46711 Move metadata generation to separate script

univention-google-apps 2.0.0-10A~4.3.0.201808081617

App updated
Comment 14 Daniel Tröder univentionstaff 2018-08-14 12:02:24 CEST
OK: metadata is replicated
Comment 15 Erik Damrose univentionstaff 2018-08-21 10:08:48 CEST
App Update released