GpgFrontend icon indicating copy to clipboard operation
GpgFrontend copied to clipboard

Windows 7 version

Open sergeevabc opened this issue 1 year ago • 3 comments

I see that QT5 version is back.

However, 2.1.3 QT5 does not work on Windows 7. It seems you compiled it without targeting that OS as a minimum, so it tries to use KERNEL32.dll calls introduced in Windows 8 such as CreateFile2 instead of CreateFileW. It leads to the fatal error.

2024-0513-0202 gpgfrontend 216 createfile2 error

If I replace that call in libarchive.dll, then GPGFrontend launches.

$ sfk.exe replace -pat /CreateFile2/CreateFileW/ -dir . -file *.* -yes
[total hits/matching patterns/non-matching patterns]
[003/1/0] libarchive.dll
109 files checked, 1 changed.

sergeevabc avatar May 16 '24 19:05 sergeevabc

https://github.com/libarchive/libarchive/blob/d33f44ad5ce754d61e4e8e193edc52e50bf2896c/libarchive/archive_read_disk_windows.c#L420

That if-else statement at the specified line addresses the current situation. What would happen if I forked this library and recompiled it on Windows 7? Is this a good idea, or is there an already compiled binary available?

saturneric avatar May 16 '24 19:05 saturneric

Sure, let's try that path.

sergeevabc avatar May 16 '24 19:05 sergeevabc

I'm sure it's been stated many times before but it's very discouraged to use Windows 7 for any form of security use case. It hasn't had updates for almost half a decade. This not working on Windows 7 seems more like a feature than a bug.

soulstenance avatar May 29 '24 20:05 soulstenance

@sergeevabc As I've read the document of gpgme, with the new gpgme version, libarchive is not a must. If you can run GnuPG 2.4.1+ on win7, perhaps, I can provide a method to disable or a special release without the dynamic link of libarchive.dll. As @soulstenance said, using win7 is maybe no longer a secure choice, but I do know some users have the need to deal with some old operating systems under some particular situations.

saturneric avatar Dec 18 '24 08:12 saturneric

I don't use Windows 7 since switching to Linux but I am still very passionate about Windows 7, it would be cool to have a version that works on it, unless it's too much trouble. I think KeePassXC does this too. Even global airlines still run on Windows 3.1 haha

NearestWater262 avatar Dec 21 '24 07:12 NearestWater262

GpgFrontend 2.1.7 Qt5 on Windows 7 x64 works fine. Thank you, @saturneric. The lack of symmetric encryption settings makes me sad, but that's another story.

sergeevabc avatar Mar 26 '25 18:03 sergeevabc