Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Backport][ipa-4-6] add default access control when migrating trust objects #3658

Closed
wants to merge 3 commits into from

Conversation

abbra
Copy link
Contributor

@abbra abbra commented Sep 12, 2019

This PR was opened automatically because PR #3643 was pushed to master and backport to ipa-4-6 is required.

@abbra abbra added the ack Pull Request approved, can be merged label Sep 12, 2019
@rcritten rcritten added the re-run Trigger a new run of PR-CI label Sep 12, 2019
@freeipa-pr-ci freeipa-pr-ci removed the re-run Trigger a new run of PR-CI label Sep 12, 2019
@rcritten
Copy link
Contributor

I don't know if you want to accept this suggestion or add an exception. I'm inclined to add an exception to keep the code consistent between versions.

************* Module ipaserver.install.plugins.adtrust
ipaserver/install/plugins/adtrust.py:586: [W0110(deprecated-lambda), update_tdo_to_new_layout.set_krb_principal] map/filter on lambda could be replaced by comprehension)
ipaserver/install/plugins/adtrust.py:773: [W0110(deprecated-lambda), update_tdo_default_read_keys_permissions.execute] map/filter on lambda could be replaced by comprehension)

@abbra
Copy link
Contributor Author

abbra commented Sep 16, 2019

It is interesting that we don't have this problem with newer Python and pylint versions. I agree to ignore it for compatibility with newer releases.

abbra and others added 3 commits September 16, 2019 09:50
It looks like for some cases we do not have proper set up keytab
retrieval configuration in the old trusted domain object. This mostly
affects two-way trust cases. In such cases, create default configuration
as ipasam would have created when trust was established.

Resolves: https://pagure.io/freeipa/issue/8067

Signed-off-by: Alexander Bokovoy <abokovoy@redhat.com>
Reviewed-By: Florence Blanc-Renaud <frenaud@redhat.com>
If trusted domain object (TDO) is lacking ipaAllowedToPerform;read_keys
attribute values, it cannot be used by SSSD to retrieve TDO keys and the
whole communication with Active Directory domain controllers will not be
possible.

This seems to affect trusts which were created before
ipaAllowedToPerform;read_keys permission granting was introduced
(FreeIPA 4.2). Add back the default setting for the permissions which
grants access to trust agents and trust admins.

Resolves: https://pagure.io/freeipa/issue/8067

Signed-off-by: Alexander Bokovoy <abokovoy@redhat.com>
Reviewed-By: Florence Blanc-Renaud <frenaud@redhat.com>
It is interesting that we don't have this problem with newer
Python and pylint versions. Ignoring to try to keep the code
more in line with newer releases.
@flo-renaud
Copy link
Contributor

@rcritten
thanks for adding the pylint: disable to the code. We can commit this backport now.

@flo-renaud flo-renaud added the pushed Pull Request has already been pushed label Sep 16, 2019
@flo-renaud
Copy link
Contributor

ipa-4-6:

  • 5741e03 add default access control when migrating trust objects
  • b764b38 adtrust: add default read_keys permission for TDO objects
  • 582e7a3 Disable deprecated-lambda check in adtrust upgrade code

@flo-renaud flo-renaud closed this Sep 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ack Pull Request approved, can be merged pushed Pull Request has already been pushed
Projects
None yet
4 participants