Bug 50573 - [O365] wizard traceback when downloading public cert
[O365] wizard traceback when downloading public cert
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: Office 365
UCS 4.4
Other Linux
: P5 normal (vote)
: ---
Assigned To: Erik Damrose
Jürn Brodersen
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2019-11-27 18:08 CET by Erik Damrose
Modified: 2020-02-13 09:51 CET (History)
0 users

See Also:
What kind of report is it?: Development Internal
What type of bug is this?: ---
Who will be affected by this bug?: ---
How will those affected feel about the bug?: ---
User Pain:
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional):
Max CVSS v3 score:


Attachments
proposed patch (3.09 KB, patch)
2019-11-29 08:33 CET, Jürn Brodersen
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Erik Damrose univentionstaff 2019-11-27 18:08:06 CET
Request: office365/o365_public_signing_cert.pem

Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/univention/management/console/base.py", line 358, in __error_handling
    six.reraise(etype, exc, etraceback)
  File "/usr/lib/python2.7/dist-packages/univention/management/console/base.py", line 261, in execute
    function.__func__(self, request, *args, **kwargs)
  File "/usr/lib/pymodules/python2.7/univention/management/console/modules/office365/__init__.py", line 145, in public_signing_cert
    with open(AzureADConnectionHandler.get_conf_path('SSL_CERT'), 'rb') as fd:
TypeError: get_conf_path() takes exactly 3 arguments (2 given)
Comment 1 Erik Damrose univentionstaff 2019-11-28 13:20:22 CET
d1140eb2 Fix issues in wizard with certificate download and saml setup script creation

* Fixed function call to get the correct certificate when clicking the
  download link
* write_saml_setup_script() now respects the adconnection alias when
  creating the saml setup script. The issuer is also calculated
  correctly, and is derived directly from UCR ucs/server/sso/fqdn instead
  of umc/saml/idp-server - which is indirectly calculated from
  ucs/server/sso/fqdn anyway.

univention-office365 2.0.2-45A~4.4.0.201911281319
Comment 2 Erik Damrose univentionstaff 2019-11-28 14:43:03 CET
The o365_usertokens script executed by a cronjob does not work - it has to iterate over the initialiazed connections and reset the tokens there.
Comment 3 Erik Damrose univentionstaff 2019-11-28 16:21:57 CET
c272a81b o365_usertokens now iterates over all azure ads the user is part of, and resets the tokens.

univention-office365 2.0.2-47A~4.4.0.201911281619
Comment 4 Jürn Brodersen univentionstaff 2019-11-29 08:33:25 CET
Created attachment 10235 [details]
proposed patch

Two bugs:
If A user is created on the umc without the o365 Template but with a ConnectionAlias a traceback is thrown.
-> Problem with the udm hook

The listener only deactivates/activates one ConnectionAlias.

Otherwise it looks good:
Cert download works
Saml Powershell Skript is modified
Tokens are renewed for all connections
Login at multiple Azure ADs works
Comment 5 Erik Damrose univentionstaff 2019-11-29 10:10:14 CET
Thank you for the patch, which i applied. There was a small copy+paste error for the group listener, and i fixed style issues in the hook while committing it.

2f8ea93c Adapt user and group listener with QA feedback, fix hook
univention-office365 2.0.2-48A~4.4.0.201911291006
Comment 6 Erik Damrose univentionstaff 2019-12-02 15:33:37 CET
As discussed, the user listener delete_user function has been adapted.

I also fixed the subscriptions test and improved the adconnection parsing in print_users_and_groups 

git a18ae83d; univention-office365 2.0.2-50A~4.4.0.201912021530
Comment 7 Jürn Brodersen univentionstaff 2019-12-02 19:14:16 CET
What I tested (see comment 4 as well):
Delete works -> OK
print_users_and_groups -> OK
Migration works -> OK
jenkins -> https://jenkins.knut.univention.de:8181/job/UCS-4.4/job/UCS-4.4-2/job/product-test-component-office365/36/ -> OK

-> verified
Comment 8 Erik Damrose univentionstaff 2020-02-13 09:51:16 CET
Closed: Released with App Version 3.0 for UCS 4.4