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

Fix-FilePermissionInternal Errors on User 'APPLICATION PACKAGE AUTHORITY\ALL APPLICATION PACKAGES' #750

Closed
DarwinJS opened this issue Jun 4, 2017 · 5 comments
Assignees
Milestone

Comments

@DarwinJS
Copy link

DarwinJS commented Jun 4, 2017

This problem is cropping up again with OpenSSHUtils.psm1, only now since I am not writing the code I can't skip over "APPLICATION PACKAGE AUTHORITY". (previously mentioned in #719)

image

I do not believe I have any third party elements on my Windows 10 machine that would add virtual accounts with these names - so I am hoping you can find out something internally in Microsoft as to what these virtual accounts are?

I have applied creators update to this machine (1703)- however - I originally reported this while still on 1607.

The believe line of code doing this is here:

return Remove-RuleProtection -FilePath $FilePath -Message $message -Quiet:$Quiet

@DarwinJS
Copy link
Author

DarwinJS commented Jun 4, 2017

I can submit a PR for this request if that is acceptable.

@manojampalam
Copy link
Contributor

Yes please.

@bingbing8
Copy link
Contributor

bingbing8 commented Jun 5, 2017

@DarwinJS, I found the cause of the problem. The line you pointed above has no problem since it just remove the inheritance. The real problem is here:
'APPLICATION PACKAGE AUTHORITY\ALL RESTRICTED APPLICATION PACKAGES'- can't translate fully qualified name. it is a win32 API bug. To workaround, we need to use the shortValue of the IdentityReference
'ALL APPLICATION PACKAGES' exists only on Win2k12 and Win2k16 and 'ALL RESTRICTED APPLICATION PACKAGES' exists only in Win2k16
I submitted a PR for the fix
PowerShell/openssh-portable#158

Please let me know if you want this fix in v0.0.15.0 package, or it is okay to have the fix in your chocolatey package. Thanks!

@bingbing8
Copy link
Contributor

@DarwinJS i checked in the fix for this. I also exposed Fix-FilePermissions per your request from issue #744

@DarwinJS
Copy link
Author

DarwinJS commented Jun 7, 2017

Ahh yes - I realize that the comment I put on #756 was for this issue - I had found the code on the pull request and tested it. Thanks!

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

No branches or pull requests

3 participants