[Bug 37167] IEC 61850 v2.02 example client expects ' wine_pcap_findalldevs_ex' to return adapter names in '<protocol>:// \Device\NPF_<adaptername>' format

wine-bugs at winehq.org wine-bugs at winehq.org
Fri Mar 8 06:07:44 CST 2019


https://bugs.winehq.org/show_bug.cgi?id=37167

Anastasius Focht <focht at gmx.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|-unknown                    |wpcap

--- Comment #2 from Anastasius Focht <focht at gmx.net> ---
Hello folks,

revisiting, still present.

--- snip ---
$ WINEDEBUG=+seh,+relay,+snoop,+wpcap wine ./IEC61850_Example_Client.exe
>>log.txt 2>&1
...
002a:CALL PIS10V2.IEC61850_GetLibraryVersion(<unknown, check return>)
ret=004017e6
002a:RET  PIS10V2.IEC61850_GetLibraryVersion() retval=1005c2c8 ret=004017e6
...
002a:CALL PIS10V2.IEC61850_Create(0033fcf0,0033fd2c) ret=004020b0
...
002a:RET  PIS10V2.IEC61850_Create() retval=0043d7e0 ret=004020b0
002a:CALL PIS10V2.IEC61850_LoadSCLFile(0043d7e0,00403210) ret=00401826
002a:Call msvcr100.fopen(00403210 "../cidFiles/client.cid",1005c2b4 "r")
ret=100201de
...
002e:Call PE DLL (proc=0x100580ef,module=0x10000000
L"PIS10V2.dll",reason=THREAD_ATTACH,res=(nil))
002e:Ret  PE DLL (proc=0x100580ef,module=0x10000000
L"PIS10V2.dll",reason=THREAD_ATTACH,res=(nil)) retval=1
002a:Call KERNEL32.CreateFileW(0043d9f0
L"../cidFiles/client.cid",80000000,00000003,0033fa0c,00000003,00000001,00000000)
ret=7e918c4f
002e:Starting thread proc 0x10056690 (arg=0x43d198) 
...
002a:CALL PIS10V2.IEC61850_Start(<unknown, check return>) ret=0040186f
...
002a:Call iphlpapi.GetAdaptersInfo(004af2d0,0033fae0) ret=1001edcc
002a:Ret  iphlpapi.GetAdaptersInfo() retval=0000006f ret=1001edcc
...
002a:Call iphlpapi.GetAdaptersInfo(004af778,0033fae0) ret=1001edfe
...
002a:Ret  iphlpapi.GetAdaptersInfo() retval=00000000 ret=1001edfe
002a:Call wpcap.pcap_findalldevs_ex(1005e304,00000000,0033faf4,0033fc08)
ret=1001ee20
002a:fixme:wpcap:wine_pcap_findalldevs_ex ("rpcap://" (nil) 0x33faf4 0x33fc08):
partial stub
002a:trace:wpcap:wine_pcap_findalldevs (0x33faf4 0x33fc08)
002a:Ret  wpcap.pcap_findalldevs_ex() retval=00000000 ret=1001ee20
002a:Call msvcr100.memset(0033fb15,00000000,000000ef) ret=1001eede
002a:Ret  msvcr100.memset() retval=0033fb15 ret=1001eede
002a:Call msvcr100._stricmp(7d056850 "enp5s0",0033fb00
"rpcap://\\Device\\NPF_enp5s0") ret=1001ef1f
002a:Ret  msvcr100._stricmp() retval=fffffff3 ret=1001ef1f
002a:Call msvcr100.memset(0033fb15,00000000,000000ef) ret=1001eede
002a:Ret  msvcr100.memset() retval=0033fb15 ret=1001eede
002a:Call msvcr100._stricmp(7d056850 "enp5s0",0033fb00
"rpcap://\\Device\\NPF_wlp4s0") ret=1001ef1f
002a:Ret  msvcr100._stricmp() retval=fffffff3 ret=1001ef1f
002a:Call msvcr100.memset(0033fb15,00000000,000000ef) ret=1001eede
002a:Ret  msvcr100.memset() retval=0033fb15 ret=1001eede
002a:Call msvcr100._stricmp(7d056860 "lo",0033fb00
"rpcap://\\Device\\NPF_enp5s0") ret=1001ef1f
002a:Ret  msvcr100._stricmp() retval=fffffffa ret=1001ef1f
...
002a:RET  PIS10V2.IEC61850_Start() retval=ffffffb7 ret=0040186f
002a:CALL PIS10V2.IEC61850_ErrorString(ffffffb7) ret=00401880
002a:RET  PIS10V2.IEC61850_ErrorString() retval=1005b140 ret=00401880
...
002a:CALL PIS10V2.IEC61850_Stop(<unknown, check return>) ret=004020fd
002a:RET  PIS10V2.IEC61850_Stop() retval=00000000 ret=004020fd
...
--- snip ---

With the adapter names part fixed it still fails (comment #1):

--- snip ---
...
002a:Call wpcap.pcap_findalldevs_ex(1005e304,00000000,0033faf4,0033fc08)
ret=1001ee20
002a:fixme:wpcap:wine_pcap_findalldevs_ex ("rpcap://" (nil) 0x33faf4 0x33fc08):
partial stub
002a:trace:wpcap:wine_pcap_findalldevs (0x33faf4 0x33fc08)
002a:trace:wpcap:wine_pcap_findalldevs entry: 1. enp5s0 ((null))
addr=0x7c921e40 flags=0x16
002a:trace:wpcap:wine_pcap_findalldevs entry new name:
rpcap://\Device\NPF_enp5s0
002a:trace:wpcap:wine_pcap_findalldevs entry: 2. lo ((null)) addr=0x7c921a40
flags=0x37
002a:trace:wpcap:wine_pcap_findalldevs entry new name: rpcap://\Device\NPF_lo
002a:trace:wpcap:wine_pcap_findalldevs entry: 3. any (Pseudo-device that
captures on all interfaces) addr=(nil) flags=0x36
002a:trace:wpcap:wine_pcap_findalldevs entry new name: rpcap://\Device\NPF_any
002a:trace:wpcap:wine_pcap_findalldevs entry: 4. wlp4s0 ((null))
addr=0x7c921ec0 flags=0x2a
002a:trace:wpcap:wine_pcap_findalldevs entry new name:
rpcap://\Device\NPF_wlp4s0
002a:trace:wpcap:wine_pcap_findalldevs entry: 5. bluetooth-monitor (Bluetooth
Linux Monitor) addr=(nil) flags=0x38
002a:trace:wpcap:wine_pcap_findalldevs entry new name:
rpcap://\Device\NPF_bluetooth-monitor
002a:trace:wpcap:wine_pcap_findalldevs entry: 6. nflog (Linux netfilter log
(NFLOG) interface) addr=(nil) flags=0x30
002a:trace:wpcap:wine_pcap_findalldevs entry new name:
rpcap://\Device\NPF_nflog
002a:trace:wpcap:wine_pcap_findalldevs entry: 7. nfqueue (Linux netfilter queue
(NFQUEUE) interface) addr=(nil) flags=0x30
002a:trace:wpcap:wine_pcap_findalldevs entry new name:
rpcap://\Device\NPF_nfqueue
002a:trace:wpcap:wine_pcap_findalldevs entry: 8. bluetooth0 (Bluetooth adapter
number 0) addr=(nil) flags=0x8
002a:trace:wpcap:wine_pcap_findalldevs entry new name:
rpcap://\Device\NPF_bluetooth0
002a:trace:wpcap:wine_pcap_findalldevs entry: 9. usbmon0 (All USB buses)
addr=(nil) flags=0x30
002a:trace:wpcap:wine_pcap_findalldevs entry new name:
rpcap://\Device\NPF_usbmon0
002a:trace:wpcap:wine_pcap_findalldevs entry: 10. usbmon1 (USB bus number 1)
addr=(nil) flags=(nil)
002a:trace:wpcap:wine_pcap_findalldevs entry new name:
rpcap://\Device\NPF_usbmon1
002a:trace:wpcap:wine_pcap_findalldevs entry: 11. usbmon2 (USB bus number 2)
addr=(nil) flags=(nil)
002a:trace:wpcap:wine_pcap_findalldevs entry new name:
rpcap://\Device\NPF_usbmon2
002a:trace:wpcap:wine_pcap_findalldevs entry: 12. usbmon3 (USB bus number 3)
addr=(nil) flags=(nil)
002a:trace:wpcap:wine_pcap_findalldevs entry new name:
rpcap://\Device\NPF_usbmon3
002a:trace:wpcap:wine_pcap_findalldevs entry: 13. usbmon4 (USB bus number 4)
addr=(nil) flags=(nil)
002a:trace:wpcap:wine_pcap_findalldevs entry new name:
rpcap://\Device\NPF_usbmon4
002a:Ret  wpcap.pcap_findalldevs_ex() retval=00000000 ret=1001ee20
002a:Call msvcr100.memset(0033fb15,00000000,000000ef) ret=1001eede
002a:Ret  msvcr100.memset() retval=0033fb15 ret=1001eede
002a:Call msvcr100._stricmp(7c921050 "rpcap://\\Device\\NPF_enp5s0",0033fb00
"rpcap://\\Device\\NPF_enp5s0") ret=1001ef1f
002a:Ret  msvcr100._stricmp() retval=00000000 ret=1001ef1f
002a:Call msvcr100.memset(0033fb15,00000000,000000ef) ret=1001eede
002a:Ret  msvcr100.memset() retval=0033fb15 ret=1001eede 
...
002a:Call msvcr100._stricmp(7c9211f0 "rpcap://\\Device\\NPF_usbmon4",0033fb00
"rpcap://\\Device\\NPF_wlp4s0") ret=1001ef1f
002a:Ret  msvcr100._stricmp() retval=fffffffe ret=1001ef1f
002a:Call msvcr100.free(004af778) ret=1001f035
002a:Call ntdll.RtlFreeHeap(00410000,00000000,004af778) ret=7e9204a7
002a:Ret  ntdll.RtlFreeHeap() retval=00000001 ret=7e9204a7
002a:Ret  msvcr100.free() retval=00000001 ret=1001f035
002a:Call msvcr100.free(004af2b8) ret=1001f04a
002a:Call ntdll.RtlFreeHeap(00410000,00000000,004af2b8) ret=7e9204a7
002a:Ret  ntdll.RtlFreeHeap() retval=00000001 ret=7e9204a7
002a:Ret  msvcr100.free() retval=00000001 ret=1001f04a
002a:RET  PIS10V2.IEC61850_Start() retval=ffffffb7 ret=0040186f
002a:CALL PIS10V2.IEC61850_ErrorString(ffffffb7) ret=00401880
002a:RET  PIS10V2.IEC61850_ErrorString() retval=1005b140 ret=00401880
...
--- snip ---

That seems to be a different issue. The example compares the MAC address of the
matching entries against some strange values, such as 01020304050A and fails.

Another example output:

https://www.winpcap.org/docs/docs_411/html/group__wpcap__tut1.html)

--- quote ---
On Windows, you will need to create a project, following the instructions in
the Using WinPcap in your programs section of this manual. However, we suggest
that you use the WinPcap developer's pack (available at the WinPcap website,
http://www.winpcap.org ), since it provides many examples already configured as
projects including all the code presented in this tutorial and the includes and
libraries needed to compile and run the examples.

Assuming we have compiled the program, let's try to run it. On a particular
WinXP workstation, the result we optained is

   1. \Device\NPF_{4E273621-5161-46C8-895A-48D0E52A0B83} (Realtek RTL8029(AS)
Ethernet Adapter)
   2. \Device\NPF_{5D24AE04-C486-4A96-83FB-8B5EC6C7F430} (3Com EtherLink PCI) 

As you can see, the name of the network adapters (that will be passed to
libpcap when opening the devices) under Windows are quite unreadable, so the
parenthetical descriptions can be very helpful.
--- quote ---

$ sha1sum SET\ IEC61850DLLV2\ Demo.exe 
72ebe36f11e4a3fb5c117db7bd6b367b4e0eb058  SET IEC61850DLLV2 Demo.exe

$ du -sh SET\ IEC61850DLLV2\ Demo.exe 
1.1M    SET IEC61850DLLV2 Demo.exe

$ wine --version
wine-4.3-188-gab7756619c

Regards

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.



More information about the wine-bugs mailing list