Git: Windows "File version" metadata incorrect for git.exe

Created on 8 Apr 2016  路  4Comments  路  Source: git-for-windows/git

  • [X] I was not able to find an open
    or closed issue
    matching what I'm seeing

    Setup

  • Which version of Git for Windows are you using? 32-bit or 64-bit? Include the
    output of git version as well.

64 bit

$ git --version
git version 2.7.4.windows.1
  • Which version of Windows are you running? 32-bit or 64-bit?

Windows 7 Enterprise Service Pack 1, 64 bit

  • What options did you set as part of the installation? Or did you choose the
    defaults?

Here is the ini used by the installer with the /loadinf flag

[Setup]
Lang=default
Dir=C:\Program Files\Git
Group=Git
NoIcons=0
SetupType=default
Components=ext,ext\shellhere,ext\guihere,assoc,assoc_sh
Tasks=
PathOption=Cmd
SSHOption=OpenSSH
CRLFOption=CRLFAlways
BashTerminalOption=MinTTY
PerformanceTweaksFSCache=Disabled
  • Any other interesting things about your environment that might be related
    to the issue you're seeing?

Not that I know of.

Details

  • Which terminal/shell are you running Git from? e.g Bash/CMD/PowerShell/other

Any
- What commands did you run to trigger this issue? If you can provide a
Minimal, Complete, and Verifiable example
this will help us understand the issue.
1. Right-click on C:\Program Files\Git\cmd\git.exe in Windows Explorer
2. Choose Properties
3. Choose Details tab
4. Examine File version and Product version.
- What did you expect to occur after running these commands?

I expected "File version" to be some variant of 2.7.4. Note that "Product version" is correctly set to 2.7.4.windows.1.

  • What actually happened instead?

"File version" was 2.7.0.0.

git-exe-properties

  • If the problem was occurring with a specific repository, can you provide the
    URL to that repository to help us with testing?

No

Rationale

We'd like to restrict which versions of Git are allowed to run via Windows Group Policy (to prevent versions vulnerable to CVE-2016-2324 and CVE-2016-2315 from running). Group Policy is only able to detect versions based upon "File version", not "Product version".

Thank you!

All 4 comments

Does this reproduce with the latest version of Git for Windows?

@whoisj I just checked the current version (2.8.1.windows.1 64-bit), and the Properties/Details tab shows "2.8.0.0" for File Version.

Interesting. I do see the "File Version" to be "2.8.0.0", but I also see Product Version to be "2.8.1.windows.1".

image

Thank you very much!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

sschlesier picture sschlesier  路  3Comments

dlk-pavan picture dlk-pavan  路  4Comments

Snaptags picture Snaptags  路  4Comments

yegorich picture yegorich  路  3Comments

drewnoakes picture drewnoakes  路  5Comments