Avatar of ISDNO
ISDNO
Flag for Norway asked on

%Username% variable into AppLocker rule

How would I add an username environment variable into an AppLocker rule?

For instance I would like to whitelist applications in this directory:

C:\Users\%username%\Appdata\Local\Apps\CompanyAPP.

In the audit it logs the exact username.
OS SecurityMicrosoft Legacy OSIT Administration

Avatar of undefined
Last Comment
McKnife

8/22/2022 - Mon
SOLUTION
arnold

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
ASKER CERTIFIED SOLUTION
McKnife

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
Daniel Morrison

For some reason the * did not work for in the user profile area in applocker.  I had to use %OSDRIVE%\Users\%USERPROFILE%\Appdata\Local\Apps\CompanyAPP.  Just in case someone has the same issue.
McKnife

You have had success with variables (in this case: %USERPROFILE%) that applocker does not even know?!
I don't think so, it will have another reason (like another rule is in effect).
Experts Exchange has (a) saved my job multiple times, (b) saved me hours, days, and even weeks of work, and often (c) makes me look like a superhero! This place is MAGIC!
Walt Forbes