* not have permission to open its own current active access token) is evaluated
* as thread does not have that privilege.
*/
-BOOL
+static BOOL
win32_have_privilege(LUID luid_privilege)
{
PRIVILEGE_SET priv;
* used for reverting to this access token. It is set to NULL if the current
* thread previously used primary process access token.
*/
-BOOL
+static BOOL
win32_change_token(HANDLE new_token, HANDLE *old_token)
{
HANDLE current_token;
* token is specified as NULL then revert to the primary process access token.
* Use to revert after win32_change_token() or change_token_to_primary() call.
*/
-VOID
+static VOID
win32_revert_to_token(HANDLE token)
{
/*
}
/* Open process handle with the query right specified by process exe file. */
-HANDLE
+static HANDLE
win32_find_and_open_process_for_query(LPCSTR exe_file)
{
HMODULE ntdll;
* Open primary access token of particular process handle with specified rights.
* If permissions for specified rights are missing then try to grant them.
*/
-HANDLE
+static HANDLE
win32_open_process_token_with_rights(HANDLE process, DWORD rights)
{
HANDLE old_token;
BOOL win32_is_32bit_on_win8_64bit_system(void);
BOOL win32_is_not_native_process(USHORT *native_machine);
UINT win32_change_error_mode(UINT new_mode, BOOL append);
-BOOL win32_have_privilege(LUID luid_privilege);
BOOL win32_enable_privilege(LUID luid_privilege, HANDLE *revert_token, BOOL *revert_only_privilege);
VOID win32_revert_privilege(LUID luid_privilege, HANDLE revert_token, BOOL revert_only_privilege);
-BOOL win32_change_token(HANDLE new_token, HANDLE *old_token);
-VOID win32_revert_to_token(HANDLE token);
-HANDLE win32_find_and_open_process_for_query(LPCSTR exe_file);
-HANDLE win32_open_process_token_with_rights(HANDLE process, DWORD rights);
BOOL win32_call_func_with_tcb_privilege(BOOL (*function)(LPVOID), LPVOID argument);