gpresult.exe

  • File Path: C:\Windows\SysWOW64\gpresult.exe
  • Description: Query Group Policy RSOP Data

Hashes

Type Hash
MD5 24091E39D3C98CD0866002B618801C6E
SHA1 66386E3CB2B37BCC6B98D34D0B3FC32EF0BDA6C7
SHA256 2BAC97558FA6700178EBF89AD80DB4492E21A6C92692F89956FDAB2AA5899D57
SHA384 0E1BC158F4F8D277C12AB840DC6AB4B76DE6082AB0F69CD823940CB61444835FD720FA20600E2FC8956C30ABE4AE0D53
SHA512 FB76E01930FB01176016786CDEDF2349720150E2308138FF585E0B98EC1BF96003A8BF95B87018AC9BEDA7CBE0056356FBB3EA42BEA5A19286F94D09398792B3
SSDEEP 3072:Ja+sOKvkY3L78RtU5eITpgwRO42wtzi8TKnpft9PtgXtmpZmnIMqiNPr5W3qi1Xi:8BHL78R+5ef4O6nv36ayucr2k/MF
IMP C2331BA71CEC644A91EA059F8846B40A
PESHA1 79ED5D211464254315020C72B3957BBF1C86D931
PE256 176AB07D2950A0EA16E860BCA5A0129E50BEA5DA3C4ECEBAF82AED7ABD422B29

Runtime Data

Usage (stdout):


GPRESULT [/S system [/U username [/P [password]]]] [/SCOPE scope]
           [/USER targetusername] [/R | /V | /Z] [(/X | /H) <filename> [/F]]

Description:
    This command line tool displays the Resultant Set of Policy (RSoP)
    information for a target user and computer.

Parameter List:
    /S        system           Specifies the remote system to connect to.

    /U        [domain\]user    Specifies the user context under which the
                               command should run.
                               Can not be used with /X, /H.

    /P        [password]       Specifies the password for the given user
                               context. Prompts for input if omitted.
                               Cannot be used with /X, /H.

    /SCOPE    scope            Specifies whether the user or the
                               computer settings need to be displayed.
                               Valid values: "USER", "COMPUTER".

    /USER     [domain\]user    Specifies the user name for which the
                               RSoP data is to be displayed.

    /X        <filename>       Saves the report in XML format at the
                               location and with the file name specified
                               by the <filename> parameter. (valid in Windows
                               Vista SP1 and later and Windows Server 2008 and later)

    /H        <filename>       Saves the report in HTML format at the
                               location and with the file name specified by
                               the <filename> parameter. (valid in Windows
                               at least Vista SP1 and at least Windows Server 2008)

    /F                         Forces Gpresult to overwrite the file name
                               specified in the /X or /H command.

    /R                         Displays RSoP summary data.

    /V                         Specifies that verbose information should
                               be displayed. Verbose information provides
                               additional detailed settings that have
                               been applied with a precedence of 1.

    /Z                         Specifies that the super-verbose
                               information should be displayed. Super-
                               verbose information provides additional
                               detailed settings that have been applied
                               with a precedence of 1 and higher. This
                               allows you to see if a setting was set in
                               multiple places. See the Group Policy
                               online help topic for more information.

    /?                         Displays this help message.


Examples:
    GPRESULT /R
    GPRESULT /H GPReport.html
    GPRESULT /USER targetusername /V
    GPRESULT /S system /USER targetusername /SCOPE COMPUTER /Z
    GPRESULT /S system /U username /P password /SCOPE USER /V

Usage (stderr):

ERROR: Invalid syntax. Value expected for '/h'.
Type "GPRESULT /?" for usage.

Loaded Modules:

Path
C:\Windows\SYSTEM32\ntdll.dll
C:\Windows\System32\wow64.dll
C:\Windows\System32\wow64cpu.dll
C:\Windows\System32\wow64win.dll
C:\Windows\SysWOW64\gpresult.exe

Signature

  • Status: Signature verified.
  • Serial: 3300000266BD1580EFA75CD6D3000000000266
  • Thumbprint: A4341B9FD50FB9964283220A36A1EF6F6FAA7840
  • Issuer: CN=Microsoft Windows Production PCA 2011, O=Microsoft Corporation, L=Redmond, S=Washington, C=US
  • Subject: CN=Microsoft Windows, O=Microsoft Corporation, L=Redmond, S=Washington, C=US

File Metadata

  • Original Filename: gprslt.exe
  • Product Name: Microsoft Windows Operating System
  • Company Name: Microsoft Corporation
  • File Version: 10.0.19041.1 (WinBuild.160101.0800)
  • Product Version: 10.0.19041.1
  • Language: English (United States)
  • Legal Copyright: Microsoft Corporation. All rights reserved.
  • Machine Type: 32-bit

File Scan

  • VirusTotal Detections: 0/75
  • VirusTotal Link: https://www.virustotal.com/gui/file/2bac97558fa6700178ebf89ad80db4492e21a6c92692f89956fdab2aa5899d57/detection

File Similarity (ssdeep match)

File Score
C:\WINDOWS\SysWOW64\gpresult.exe 27
C:\Windows\SysWOW64\gpresult.exe 96

Possible Misuse

The following table contains possible examples of gpresult.exe being misused. While gpresult.exe is not inherently malicious, its legitimate functionality can be abused for malicious purposes.

Source Source File Example License
stockpile 5c4dd985-89e3-4590-9b57-71fed66ff4e2.yml gpresult /R Apache-2.0

Additional Info*

*The information below is copied from MicrosoftDocs, which is maintained by Microsoft. Available under CC BY 4.0 license.


gpresult

Applies to: Windows Server 2022, Windows Server 2019, Windows Server 2016, Windows Server 2012 R2, Windows Server 2012

Displays the Resultant Set of Policy (RSoP) information for a remote user and computer. To use RSoP reporting for remotely targeted computers through the firewall, you must have firewall rules that enable inbound network traffic on the ports.

Syntax

gpresult [/s <system> [/u <username> [/p [<password>]]]] [/user [<targetdomain>\]<targetuser>] [/scope {user | computer}] {/r | /v | /z | [/x | /h] <filename> [/f] | /?}

[!NOTE] Except when using /?, you must include an output option, /r, /v, /z, /x, or /h.

Parameters

Parameter Description
/s <system> Specifies the name or IP address of a remote computer. Don’t use backslashes. The default is the local computer.
/u <username> Uses the credentials of the specified user to run the command. The default user is the user who is logged on to the computer that issues the command.
/p [<password>] Specifies the password of the user account that is provided in the /u parameter. If /p is omitted, gpresult prompts for the password. The /p parameter can’t be used with /x or /h.
/user [<targetdomain>\]<targetuser>] Specifies the remote user whose RSoP data is to be displayed.
/scope {user | computer} Displays RSoP data for either the user or the computer. If /scope is omitted, gpresult displays RSoP data for both the user and the computer.
[/x | /h] <filename> Saves the report in either XML (/x) or HTML (/h) format at the location and with the file name that is specified by the filename parameter. Can’t be used with /u, /p, /r, /v, or /z.
/f Forces gpresult to overwrite the file name that is specified in the /x or /h option.
/r Displays RSoP summary data.
/v Displays verbose policy information. This includes detailed settings that were applied with a precedence of 1.
/z Displays all available information about Group Policy. This includes detailed settings that were applied with a precedence of 1 and higher.
/? Displays help at the command prompt.
Remarks
  • Group Policy is the primary administrative tool for defining and controlling how programs, network resources, and the operating system operate for users and computers in an organization. In an active directory environment, Group Policy is applied to users or computers based on their membership in sites, domains, or organizational units.

  • Because you can apply overlapping policy settings to any computer or user, the Group Policy feature generates a resulting set of policy settings when the user logs on. The gpresult command displays the resulting set of policy settings that were enforced on the computer for the specified user when the user logged on.

  • Because /v and /z produce a lot of information, it’s useful to redirect output to a text file (for example, gpresult/z >policy.txt).

  • On ARM64 versions of Windows, only the gpresult in SysWow64 works with the /h parameter.

Examples

To retrieve RSoP data for only the remote user, maindom\hiropln with the password p@ssW23, who’s on the computer srvmain, type:

gpresult /s srvmain /u maindom\hiropln /p p@ssW23 /user targetusername /scope user /r

To save all available information about Group Policy to a file named, policy.txt, for only the remote user maindom\hiropln with the password p@ssW23, on the computer srvmain, type:

gpresult /s srvmain /u maindom\hiropln /p p@ssW23 /user targetusername /z > policy.txt

To display RSoP data for the logged on user, maindom\hiropln with the password p@ssW23, for the computer srvmain, type:

gpresult /s srvmain /u maindom\hiropln /p p@ssW23 /r

Additional References


MIT License. Copyright (c) 2020-2021 Strontic.