Bug 47958 - SchoolDC detection does not seem to be correct
SchoolDC detection does not seem to be correct
Status: RESOLVED WONTFIX
Product: UCS@school
Classification: Unclassified
Component: Ucsschool-lib
UCS@school 4.3
Other Linux
: P5 normal (vote)
: ---
Assigned To: UCS@school maintainers
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2018-10-11 12:08 CEST by Sönke Schwardt-Krummrich
Modified: 2023-06-12 15:45 CEST (History)
1 user (show)

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

Note You need to log in before you can comment on or make changes to this bug.
Description Sönke Schwardt-Krummrich univentionstaff 2018-10-11 12:08:17 CEST
"univentionObjectClass" doesn't look good to me. Maybe univentionObjectType is meant. So I think, there is always an KeyError exception.

→ ucs-school-lib/python/models/computer.py


class SchoolDC(UCSSchoolHelperAbstractClass):
	# NOTE: evaluate filter (&(service=UCS@school)(service=UCS@school Education)) # UCS@school Administration
	# vs. group memberships

	@classmethod
	def get_container(cls, school):
		return 'cn=dc,cn=server,%s' % cls.get_search_base(school).computers

	@classmethod
	def get_class_for_udm_obj(cls, udm_obj, school):
		try:
			univention_object_class = udm_obj['univentionObjectClass']
		except KeyError:
			univention_object_class = None
		if univention_object_class == 'computers/domaincontroller_slave':
			return SchoolDCSlave
		return cls
Comment 1 Jan-Luca Kiok univentionstaff 2023-06-12 15:45:20 CEST
This issue has been filed against UCS@school 4.3 or earlier.

UCS 4.3 is out of maintenance and UCS components have vastly changed in later
releases. Thus, this issue is now being closed.

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