Bug 42864 - Default values are not used after installing an App with extended attributes
Default values are not used after installing an App with extended attributes
Status: REOPENED
Product: UCS
Classification: Unclassified
Component: UDM (Generic)
UCS 4.4
Other Linux
: P5 normal (vote)
: ---
Assigned To: UMC maintainers
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2016-11-07 17:00 CET by Stefan Gohmann
Modified: 2019-02-27 18:05 CET (History)
1 user (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?: 3: Will affect average number of installed domains
How will those affected feel about the bug?: 3: A User would likely not purchase the product
User Pain: 0.257
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Ticket number:
Bug group (optional):
Max CVSS v3 score:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Stefan Gohmann univentionstaff 2016-11-07 17:00:23 CET
After installing ownCloud 8.2, the App Center shows the message
 Updating session and module data...

Afterwards, I've created a new user. Unfortunately, the default value for ownCloudEnabled is not set and thus the user is unable to login.
Comment 1 Florian Best univentionstaff 2016-11-08 19:12:12 CET
Please give more information what you did.
I can't reproduce this on a DC Master with owncloud 8.2 or 9.1 using chromium as browser.
Did you open the users/user module in the session before you installed owncloud?

You got the pop up "Install Information" with the [Continue]-button. After clicking this the "Updating session and module data..." message is shown. After this you opened the users/user module, clicked on Add, then Advanced to exit the wizard then on [Advanced settings] → "ownCloud" and the check box "ownCloud aktiviert" is not checked?
Comment 2 Stefan Gohmann univentionstaff 2016-11-08 19:20:55 CET
(In reply to Florian Best from comment #1)
> Please give more information what you did.
> I can't reproduce this on a DC Master with owncloud 8.2 or 9.1 using
> chromium as browser.

I've used ownCloud 8.2 and chromium.

> Did you open the users/user module in the session before you installed
> owncloud?

No.
 
> You got the pop up "Install Information" with the [Continue]-button. After
> clicking this the "Updating session and module data..." message is shown.

Yes.

> After this you opened the users/user module, clicked on Add, then Advanced
> to exit the wizard then on [Advanced settings] → "ownCloud" and the check
> box "ownCloud aktiviert" is not checked?

No, I've clicked on Add, filled firstname, lastname, username, password and created the user. Afterwards, I've opened the user and the ownCloud activated checkbox was not checked.
Comment 3 Florian Best univentionstaff 2016-11-08 19:24:52 CET
How long took the owncloud installation? (It took over 15 minutes on my system, i think this is unusual? some objects where automatically migrated I think).
Comment 4 Florian Best univentionstaff 2016-11-09 13:13:17 CET
The request to create the user contains owncloudEnabled=true:

curl 'http://10.200.4.50/univention-management-console/command/udm/add' -H 'Content-Type: application/json' -H 'Accept: */*' -H 'Cache-Control: no-cache' -H 'X-Requested-With: XMLHttpRequest' --data-binary '{"options":[{"object":{"disabled":"none","CtxRASDialin":"E","lastname":"foobar","password":"univention","CtxShadow":"00000000","overridePWHistory":false,"pwdChangeNextLogin":false,"primaryGroup":"cn=Domain Users,cn=groups,dc=dirk,dc=singlemaster,dc=intranet","CtxStartprogramClient":false,"username":"foobar","shell":"/bin/bash","CtxBrokenSession":"0000","owncloudEnabled":true,"locked":"none","CtxReconnectSession":"0000","CtxCfgClientPrinters":false,"homeSharePath":"foobar","unixhome":"/home/foobar","overridePWLength":false,"CtxCfgDefaultClientPrinters":false,"displayName":"foobar","CtxCfgClientDrivers":false,"CtxCfgTSLogon":false,"$options$":{"samba":true,"kerberos":true,"person":true,"posix":true,"mail":true,"pki":false,"ldap_pwd":false}},"options":{"container":"cn=users,dc=dirk,dc=singlemaster,dc=intranet","objectType":"users/user","objectTemplate":"None"}}],"flavor":"users/user"}'

The user then also contains the object class but not the attribute ownCloudEnabled:
objectClass: ownCloudUser

I see that a new UDM-module python process was started (after the session-reload progressbar):
MAIN        ( INFO    ) : Renewing session

→ The new process also detects the extended attribute:
ADMIN       ( INFO    ) : update_extended_attributes: extended attribute (LDAP): {'cn': ['ownCloudGroupEnabled'], 'objectClass': ['top', 'univentionUDMProperty', 'univentionObject'], 'univentionUDMPropertyModule': ['groups/group'], 'univentionU      DMPropertyLayoutTabName': ['ownCloud'], 'univentionUDMPropertyTranslationLongDescription;entry-de-de': ['Die Gruppe in ownCloud verwenden'], 'univentionUDMPropertyLongDescription': ['Wether Group may be used in ownCloud '], 'univentionUDMPropertyLdapMapping': ['ownCl      oudEnabled'], 'univentionUDMPropertyLayoutTabAdvanced': ['1'], 'univentionUDMPropertyObjectClass': ['ownCloudGroup'], 'univentionUDMPropertyValueNotEditable': ['0'], 'univentionUDMPropertyLayoutOverwritePosition': ['0'], 'univentionUDMPropertyLayoutOverwriteTab': ['0      '], 'univentionUDMPropertyDoNotSearch': ['0'], 'univentionUDMPropertyTranslationShortDescription;entry-de-de': ['ownCloud aktiviert'], 'univentionUDMPropertySyntax': ['boolean'], 'univentionUDMPropertyLayoutPosition': ['1'], 'univentionUDMPropertyMultivalue': ['0'],       'univentionUDMPropertyDeleteObjectClass': ['0'], 'univentionUDMPropertyDefault': ['0'], 'univentionUDMPropertyValueMayChange': ['1'], 'univentionUDMPropertyShortDescription': ['ownCloud enabled'], 'univentionObjectType': ['settings/extended_attribute'], 'univentionUD      MPropertyVersion': ['2'], 'univentionUDMPropertyTranslationTabName;entry-de-de': ['ownCloud'], 'univentionUDMPropertyValueRequired': ['0'], 'univentionUDMPropertyCLIName': ['owncloudEnabled'], 'univentionUDMPropertyHook': ['None']}

The UDM logfile contains also:
MODULE      ( INFO    ) : Setting property owncloudEnabled to True
ADMIN       ( INFO    ) : simpleLdap._create: info[owncloudEnabled]:True = '1'

This means that the extended attribute is known to UDM.
This seems to be a issue in the UDM handler itself.

→ Interesting would be the ldap addlist (is not logged because of Bug #38735).

After removing owncloud and installing it again the error doesn't occur anymore. (owncloud removed the extended attributes).
Comment 5 Florian Best univentionstaff 2017-05-17 13:40:40 CEST
We need to recheck this after Bug #41053 has been published.
Comment 6 Stefan Gohmann univentionstaff 2019-01-03 07:24:05 CET
This issue has been filled against UCS 4.1. The maintenance with bug and security fixes for UCS 4.1 has ended on 5st of April 2018.

Customers still on UCS 4.1 are encouraged to update to UCS 4.3. Please contact
your partner or Univention for any questions.

If this issue still occurs in newer UCS versions, please use "Clone this bug" or simply reopen the issue. In this case please provide detailed information on how this issue is affecting you.