# Setting audit permission through powershell

**URL:** <https://forums.powershell.org/t/setting-audit-permission-through-powershell/5296>\
**Category:** PowerShell Help\
**Created:** [December 2, 2015, 5:45am UTC](https://forums.powershell.org/t/setting-audit-permission-through-powershell/5296 "2015-12-02T05:45:01Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![aaron-miller](https://avatars.discourse-cdn.com/v4/letter/a/a6a055/32.png) [@aaron-miller](https://forums.powershell.org/u/aaron-miller)\
**Post date:** [December 2, 2015, 5:45am UTC](https://forums.powershell.org/t/setting-audit-permission-through-powershell/5296/1 "2015-12-02T05:45:01Z")

</div>

I have a function that sets audit permissions on folders, I noticed on some folders like ‘C:\windows\system32’ it runs through and sets them, if i do a (get-acl ‘C:\windows\system32’ -audit).audit its shows the permissions fine, but it doesnt actually show the permissions in the GUI (properties \> security \> advanced \> audit).

Am I doing something wrong or is this an issue with the GUI?

On most other folders it does show correctly in the GUI I should add

---

<div class="post-metadata">

**Author:** ![aaron-miller](https://avatars.discourse-cdn.com/v4/letter/a/a6a055/32.png) [@aaron-miller](https://forums.powershell.org/u/aaron-miller)\
**Post date:** [December 2, 2015, 6:54am UTC](https://forums.powershell.org/t/setting-audit-permission-through-powershell/5296/2 "2015-12-02T06:54:20Z")

</div>

Update – Seems to be more than just audits…If i change the audits manually to something else it just shows the audits i set throug hthe script, not the additional one i just set…also if i change the owner, and do a

```
(get-acl c:\windows\system32).owner
```

It still shows trustedinstaller as the owner…pretty weird, has anyone else seen any behavior like this before?

It seems powershell is not pulling any relevant information from system32

---

<div class="post-metadata">

**Author:** ![dotnVo](https://avatars.discourse-cdn.com/v4/letter/d/4af34b/32.png) [@dotnVo](https://forums.powershell.org/u/dotnVo)\
**Post date:** [May 16, 2024, 8:43pm UTC](https://forums.powershell.org/t/setting-audit-permission-through-powershell/5296/3 "2024-05-16T20:43:31Z")

</div>


