Running BankID in Wine

Questions about Wine on Linux
Locked
stemid
Newbie
Newbie
Posts: 2
Joined: Sun Dec 19, 2021 12:37 pm

Running BankID in Wine

Post by stemid »

I'm trying to get a Swedish eID program to run in Wine, this one is called BankID and it's quite popular for many years now. I was surprised to find no threads about it.

This is the first time I use Wine so be gentle. I've installed dotnet4, I'm using Bottles 2021.11.28 on Fedora 34 which means I have Wine 6.21.

I've tried starting it from CLI just to see a full log. I've tried attaching to the process from wine-dbg but I can't, either the process moves too fast for me to get the PID and attach, or something is preventing me. The EXE starts its checks immediately and within about 5 seconds has already failed.

If I manage to run info process and attach 0x<pid> in that time I just get the error 87, I have no idea where to look that up.

Presumably this is an app with some security features so I'm thinking maybe is "NtQuerySystemInformation info_class SYSTEM_PERFORMANCE_INFORMATION" a clue? Is it possible to fake Windows 10 system performance info with Wine?

After a few checks it fails with a message in GUI saying it can't be installed on this operating system. So it's doing some sort of preliminary OS check and not finding what it needs. How can I find out what that is? Is it possible to trace what it's doing inside the Wine OS system files and system calls?

Code: Select all

$ WINEDEBUG=+gdiplus bottles -b BankID -e Hämtningar/BankID_installation_7_11_0.exe
2021-12-19 18:33:35 INFO: Dxvk found: [dxvk-1.9.2]
2021-12-19 18:33:35 INFO: Vkd3d found: [vkd3d-v2.4]
2021-12-19 18:33:35 INFO: Nvapi found: [dxvk-nvapi-v0.4]
2021-12-19 18:33:35 INFO: Runners found: [sys-wine-6.21|vaniglia-6.23]
2021-12-19 18:33:36 INFO: Bottles found: BankID
2021-12-19 18:33:36 INFO: Running an executable on the bottle…
002c:fixme:winediag:LdrInitializeThunk wine-staging 6.23 is a testing version containing experimental patches.
002c:fixme:winediag:LdrInitializeThunk Please mention your exact version when filing bug reports on winehq.org.
002c:err:wineboot:process_run_key Error running cmd L"C:\\windows\\system32\\winemenubuilder.exe -a -r" (2).
010c:fixme:ole:CoInitializeSecurity 0071EC24, -1, 00000000, 00000000, 6, 2, 00000000, 8192, 00000000 stub
0114:fixme:ole:CoInitializeSecurity 0071EC24, -1, 00000000, 00000000, 6, 2, 00000000, 8192, 00000000 stub
[stemid@ryzen ~](1006/0)$ 0114:fixme:imm:ImeSetActiveContext (0x79e270, 1): stub
0114:fixme:imm:ImmReleaseContext (00010078, 0079E270): stub
00b4:fixme:imm:ImeSetActiveContext (0x17d7b0, 0): stub
00b4:fixme:imm:ImmReleaseContext (0000000000010020, 000000000017D7B0): stub
0114:fixme:file:NtLockFile I/O completion on lock not implemented yet
011c:fixme:file:NtLockFile I/O completion on lock not implemented yet
011c:fixme:ntdll:NtQuerySystemInformation info_class SYSTEM_PERFORMANCE_INFORMATION
011c:fixme:imm:ImeSetActiveContext (0x390940, 1): stub
011c:fixme:imm:ImmReleaseContext (000100A8, 00390940): stub
011c:err:msi:ITERATE_Actions Execution halted, action L"LaunchConditions" returned 1603
011c:fixme:wincodecs:jpeg_decoder_get_metadata_blocks stub
jkfloris
Level 12
Level 12
Posts: 3201
Joined: Thu Aug 14, 2014 10:10 am

Re: Running BankID in Wine

Post by jkfloris »

This program needs Windows 8.1 or higher.
You can change Wine's Windows version with the program winecfg.
or use the command line

Code: Select all

winecfg -v win10
The program does install with this setting. I just have no idea what it is supposed to do after that.
stemid
Newbie
Newbie
Posts: 2
Joined: Sun Dec 19, 2021 12:37 pm

Re: Running BankID in Wine

Post by stemid »

jkfloris wrote: Mon Dec 20, 2021 5:57 pm This program needs Windows 8.1 or higher.
You can change Wine's Windows version with the program winecfg.
or use the command line

Code: Select all

winecfg -v win10
The program does install with this setting. I just have no idea what it is supposed to do after that.
Thanks for the tip, I did try setting Win10 in Wine instead, running it with wine and it did start the install but it gets stuck near the end.

Code: Select all

$ wine Hämtningar/BankID_installation_7_11_0.exe
002c:fixme:winediag:LdrInitializeThunk wine-staging 6.21 is a testing version containing experimental patches.
002c:fixme:winediag:LdrInitializeThunk Please mention your exact version when filing bug reports on winehq.org.
0034:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0034:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0078:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0078:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0060:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0060:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0070:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0070:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
009c:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
009c:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
002c:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
002c:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0024:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0024:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
00fc:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
00fc:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0104:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0104:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0104:fixme:ole:CoInitializeSecurity 0071EC14, -1, 00000000, 00000000, 6, 2, 00000000, 8192, 00000000 stub
010c:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
010c:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
010c:fixme:ole:CoInitializeSecurity 0071EC14, -1, 00000000, 00000000, 6, 2, 00000000, 8192, 00000000 stub
010c:fixme:imm:ImeSetActiveContext (0x7b1c60, 1): stub
010c:fixme:imm:ImmReleaseContext (00010070, 007B1C60): stub
0078:fixme:imm:ImeSetActiveContext (0x48ab0, 0): stub
0078:fixme:imm:ImmReleaseContext (0000000000010020, 0000000000048AB0): stub
010c:fixme:file:NtLockFile I/O completion on lock not implemented yet
0114:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0114:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0114:fixme:file:NtLockFile I/O completion on lock not implemented yet
0114:fixme:ntdll:NtQuerySystemInformation info_class SYSTEM_PERFORMANCE_INFORMATION
0120:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0120:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0114:fixme:wincodecs:jpeg_decoder_get_metadata_blocks stub
0114:fixme:imm:ImeSetActiveContext (0x8157b8, 1): stub
0114:fixme:imm:ImmReleaseContext (000100A4, 008157B8): stub
0114:fixme:wincodecs:jpeg_decoder_get_metadata_blocks stub
0158:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0158:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0160:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0160:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0168:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0168:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
016c:fixme:msi:AutomationObject_GetIDsOfNames Unknown member L"wsh", clsid {000c109e-0000-0000-c000-000000000046}
016c:fixme:msi:AutomationObject_GetIDsOfNames Unknown member L"preapproved_base", clsid {000c109e-0000-0000-c000-000000000046}
016c:fixme:msi:AutomationObject_GetIDsOfNames Unknown member L"elevpolicy_base_bankid", clsid {000c109e-0000-0000-c000-000000000046}
016c:fixme:msi:AutomationObject_GetIDsOfNames Unknown member L"elevpolicy_base_bankidstart", clsid {000c109e-0000-0000-c000-000000000046}
016c:fixme:msi:AutomationObject_GetIDsOfNames Unknown member L"protocol_execute_64", clsid {000c109e-0000-0000-c000-000000000046}
016c:fixme:msi:AutomationObject_GetIDsOfNames Unknown member L"protocol_execute_32", clsid {000c109e-0000-0000-c000-000000000046}
016c:fixme:msi:AutomationObject_GetIDsOfNames Unknown member L"smartcard_base", clsid {000c109e-0000-0000-c000-000000000046}
016c:fixme:wshom:WshShell3_RegDelete (L"HKLM\\Software\\Microsoft\\Windows\\CurrentVersion\\Ext\\PreApproved\\{6969E7D5-223A-4982-9B79-CC4FAC2D5E5E}\\tmp"): stub
0184:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0184:fixme:font:get_name_record_codepage encoding 20 not handled, platform 1.
0184:fixme:toolhelp:CreateToolhelp32Snapshot Unimplemented: heap list snapshot
Locked