读取 Windows 上的性能数据计数器是否需要任何特殊的安全权限?

Are any special security rights required to read performance data counters on Windows?

我正在努力将 Windows 应用程序从始终 运行 作为 SYSTEM 帐户迁移到 运行 作为受限用户帐户。此应用程序所做的许多事情之一是查询 Windows Performance Counters in order to log the overall system memory and CPU usage. MSDN's list of Privilege Constants is vague, but SE_PROF_SINGLE_PROCESS_NAME or SE_SYSTEM_PROFILE_NAME strike me as being potentially required for this sort of operation. However, MSDN's documentation of functions such as PdhOpenQuery, PdhAddCounter, and PdhCollectQueryData 不要提及任何所需的权限。

鉴于此,查询性能数据计数器是否需要任何权限?或者,SE_PROF_SINGLE_PROCESS_NAMESE_SYSTEM_PROFILE_NAME 权限具体授予什么权限?

描述中提到了所需的权限 "About Performance Counters" here:

Only the administrator of the computer or users in the Performance Logs User Group can log and view counter data. Users in the Administrator group can log and view counter data only if the tool they use to log and view counter data is started from a Command Prompt window that is opened with Run as administrator.... Users in the Performance Monitoring Users group can view counter data.

Windows XP: The Administrator or users in the Administrator group can log and view counter data without restriction.