Repository navigation
The static cache for group policy settings should be cleared when GP settings change #5804
Description
Activity
- addedWG-Enginecore PowerShell engine, interpreter, and runtimecore PowerShell engine, interpreter, and runtime
on Jan 6, 2018 - addedIssue-BugIssue has been identified as a bug in the productIssue has been identified as a bug in the product
on Jan 6, 2018 If I recall registering RegisterGPNotification requires administrative rights in the past. You could register but you wont get any events without admin rights.
Docs don't mention about admin rights but suggest also use WM_SETTINGCHANGE message.
Ilya (@iSazonov) I had script while ago that I needed to listen GP events and I could never get it to receive those events in PowerShell 4. WM_SETTINGCHANGE required a window based app (GUI) to listen for that message.
Greg Zimmerman (@thezim) Thanks for clarify!
I see Chome browser use theRegisterGPNotificationhttps://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/policy/policy_loader_win.cc?pathrev=233603microsoft-github-policy-service commented
on Nov 16, 2023 ContributorMore actionsThis issue has not had any activity in 6 months, if this is a bug please try to reproduce on the latest version of PowerShell and reopen a new issue and reference this issue if this is still a blocker for you.
microsoft-github-policy-service commented
on Nov 16, 2023 ContributorMore actionsThis issue has not had any activity in 6 months, if this is a bug please try to reproduce on the latest version of PowerShell and reopen a new issue and reference this issue if this is still a blocker for you.
- addedResolution-No ActivityIssue has had no activity for 6 months or moreIssue has had no activity for 6 months or more
on Nov 16, 2023 microsoft-github-policy-service commented
on Nov 16, 2023 ContributorMore actionsThis issue has not had any activity in 6 months, if this is a bug please try to reproduce on the latest version of PowerShell and reopen a new issue and reference this issue if this is still a blocker for you.
microsoft-github-policy-service commented
on Nov 23, 2023 ContributorMore actionsThis issue has been marked as "No Activity" as there has been no activity for 6 months. It has been closed for housekeeping purposes.
Open the issue per the ask from #5791 (comment):
We use a static concurrent dictionary
s_cachedPoliciesFromRegistryas a cache for group policy settings retrieved from the registry (inUtils.cs).We should register for GP change notification using
RegisterGPNotification, so that we can clear the cache when GP changes.