[9.0] (backport #9623) Fix/8544 windows unprivileged reenroll#9794
Merged
Conversation
* fix(8544): implemented windows getOwnerFromPath * fix(8544): refactored windows getFileOwnerFromPath to be more testable, added tests fix(8544): fix build tag * fix(8544): removed windows check from enroll * fix(8544): removed os config from reenroll test, and removed unused struct * fix(8544): update re-enroll tests * fis(8544): added chengelog fragment * fix(8544): ran mage check * fix(8544): fix windows tests (cherry picked from commit 113e6ad)
6 tasks
Contributor
|
Pinging @elastic/elastic-agent-control-plane (Team:Elastic-Agent-Control-Plane) |
|
Contributor
💛 Build succeeded, but was flaky
Failed CI StepsHistorycc @kaanyalti |
kaanyalti
approved these changes
Sep 8, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.




What does this PR do?
Updates the enroll command so that the file permissions are fixed when a privileged user executes enroll. Implemented only for windows. Permission fix is executed every time root executes enroll and enroll is not triggered by install.
Why is it important?
Currently
Checklist
[ ] I have made corresponding changes to the documentation[ ] I have made corresponding change to the default configuration files./changelog/fragmentsusing the changelog toolDisruptive User Impact
None
How to test this PR locally
--unprivilegedflagRelated issues
This is an automatic backport of pull request #9623 done by [Mergify](https://mergify.com).