Skip to content

Conversation

@Naksen
Copy link
Collaborator

@Naksen Naksen commented Feb 10, 2026

Задача: 1256

Изменения:

  • Добавлена проверка прав на модификацию атрибута name для ModifyDN запроса переименования (без перемещения).
  • Добавлена проверка на удаление директории, когда происходит перемещение директории.
  • Исправлена обработка AccessControlEntry.
  • В Delete запрос добавлена подгрузка EntityType, его авто-подгрузку в какой-то момент убрали и забыли добавить вручную.
  • В подгрузку ACE добавлена подгрузка EntityType, его авто-подгрузку в какой-то момент убрали и забыли добавить вручную.
  • Добавлены два теста - на переименование и перемещение.

Copilot AI review requested due to automatic review settings February 10, 2026 10:10
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adjusts LDAP ModifyDN authorization and related ORM loading so ModifyDN operations can correctly evaluate access control entries (ACEs) for rename and move scenarios.

Changes:

  • Refactors AccessManager.mutate_query_with_ace_load to build loader options more flexibly and eager-load additional ACE relations.
  • Updates ModifyDN handling to differentiate rename vs move-to-new-superior, adding explicit rename and delete checks and refactoring ACE membership update logic into helpers.
  • Adds eager-loading of Directory.entity_type in the Delete request query.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 8 comments.

File Description
app/ldap_protocol/roles/access_manager.py Refactors ACE loader option construction and changes what related ACE data is always eager-loaded.
app/ldap_protocol/ldap_requests/modify_dn.py Adds/changes ModifyDN access checks (rename vs move) and refactors ACE cleanup/update logic into helper methods.
app/ldap_protocol/ldap_requests/delete.py Adds eager loading of Directory.entity_type in delete query options.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant