Bug 14516 - samba-tool dbcheck: Failed to remove unknown attribute because is is not a valid attribute in schema
Summary: samba-tool dbcheck: Failed to remove unknown attribute because is is not a va...
Status: NEW
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: AD: LDB/DSDB/SAMDB (show other bugs)
Version: 4.11.6
Hardware: x64 Linux
: P5 normal (vote)
Target Milestone: ---
Assignee: Samba QA Contact
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-09-28 10:09 UTC by Andrea Frati
Modified: 2021-06-10 13:23 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Andrea Frati 2020-09-28 10:09:07 UTC
I create a personal Samba Domain Controller and added some users for my family usage.

I created my personal account with wrongly named attribute 
"userCertificate;binary".

When i try to remove wrong user attribute using following command:

samba-tool dbcheck --cross-ncs --fix --yes

i receive the error below:

ERROR: unknown attribute 'userCertificate;binary' in CN=andrea,CN=Users,DC=frati,DC=local
Remove unknown attribute userCertificate;binary [YES]
ERROR: Failed to remove unknown attribute userCertificate;binary : (65, 'replmd_modify_handle_linked_attribs: attribute userCertificate;binary is not a valid attribute in schema')

I'm not able to do that using any other tool like ldapmodify or ldbmodify too.
Comment 1 Andrea Frati 2021-06-09 08:33:33 UTC
The bug is still present, could you solve it ?
Comment 2 Andrew Bartlett 2021-06-09 22:22:41 UTC
This needs more work than a simple dbcheck patch (and there is no such thing as a simple dbcheck patch, sadly), as we really should handle the ;binary case properly and just correct the name in dbcheck. 

Sadly while we are quite happy to record bugs in bugzilla, it isn't the source of our work program, that comes down to developer interest or the needs of Samba commercial support customers.

I realise this makes things difficult for home use, but such is the reality of modern software development.

If you have the time and skill, you could try to fix this yourself, we would gladly work with you on that.

Andrew Bartlett
Comment 3 Andrea Frati 2021-06-10 13:23:58 UTC
I don't expect you to solve my problem. But you could at least try to understand how it was possible to add a malformed attribute that cannot be removed later. The same thing could happen to a business customer which could cause a lot of problems.