When testing this script, it does not write the $userToRemove.logarchive log file which should be logging the activity during elevation.
Because of this the script does not log activity during the elevated session, and therefore is not tracking what the users did during that time. Which is a security concern.
When testing this script, it does not write the $userToRemove.logarchive log file which should be logging the activity during elevation. Because of this the script does not log activity during the elevated session, and therefore is not tracking what the users did during that time. Which is a security concern.