[Bug 45175] New: Icinga 2 'check_ping' tool with IPv4 address/ host crashes due to ntdll.RtlIpv4StringToAddressW stub
wine-bugs at winehq.org
wine-bugs at winehq.org
Fri May 11 09:19:22 CDT 2018
https://bugs.winehq.org/show_bug.cgi?id=45175
Bug ID: 45175
Summary: Icinga 2 'check_ping' tool with IPv4 address/host
crashes due to ntdll.RtlIpv4StringToAddressW stub
Product: Wine
Version: 3.7
Hardware: x86-64
OS: Linux
Status: NEW
Severity: normal
Priority: P2
Component: ntdll
Assignee: wine-bugs at winehq.org
Reporter: focht at gmx.net
Distribution: ---
Hello folks,
the stub was added here:
https://source.winehq.org/git/wine.git/commitdiff/71e04aaa38b35ab1607962ad30da2e54238fd0ac
https://github.com/Icinga/icinga2
--- quote ---
Icinga 2 is an open source monitoring system which checks the availability of
your network resources, notifies users of outages, and generates performance
data for reporting.
--- quote ---
Download: http://packages.icinga.com/windows/Icinga2-v2.8.4-x86.msi
--- snip ---
$ pwd
/home/focht/.wine/drive_c/Program Files (x86)/ICINGA2/sbin
$ WINEDEBUG=+seh,+relay,+ntdll wine ./check_ping.exe --host www.google.com
>>log.txt 2>&1
...
008f:Call ws2_32.GetAddrInfoW(004a2818
L"www.google.com",00000000,0032fb0c,0032fb2c) ret=00419d0a
...
008f:Ret ws2_32.GetAddrInfoW() retval=00000000 ret=00419d0a
008f:Call ws2_32.InetNtopW(00000002,0015d9ac,0032fb30,0000002e) ret=00419d5f
008f:Call KERNEL32.MultiByteToWideChar(00000000,00000000,0032fa3f
"172.217.21.228",ffffffff,0032fb30,0000002e) ret=7e59bde3
008f:Ret KERNEL32.MultiByteToWideChar() retval=0000000f ret=7e59bde3
008f:Ret ws2_32.InetNtopW() retval=0032fb30 ret=00419d5f
...
008f:Call ntdll.RtlIpv4StringToAddressW(004a2840
L"172.217.21.228",00000001,0032fba8,0032fba4) ret=00414d82
008f:fixme:ntdll:RtlIpv4StringToAddressW (L"172.217.21.228", 1, 0x32fba8,
0x32fba4): stub
008f:Ret ntdll.RtlIpv4StringToAddressW() retval=c0000002 ret=00414d82
008f:trace:seh:raise_exception code=c0000005 flags=0 addr=0x414db5 ip=00414db5
tid=008f
008f:trace:seh:raise_exception info[0]=00000000
008f:trace:seh:raise_exception info[1]=00000001
008f:trace:seh:raise_exception eax=00000001 ebx=00000000 ecx=0032fba8
edx=7bd0d548 esi=0032fe30 edi=00000000
008f:trace:seh:raise_exception ebp=0032fbb4 esp=0032fb78 cs=0023 ds=002b
es=002b fs=0063 gs=006b flags=00010297
008f:trace:seh:call_stack_handlers calling handler at 0x462aa6 code=c0000005
flags=0
008f:trace:seh:call_stack_handlers handler at 0x462aa6 returned 1
008f:trace:seh:call_stack_handlers calling handler at 0x45ce91 code=c0000005
flags=0
...
Backtrace:
=>0 0x00414db5 in check_ping (+0x14db5) (0x0032fbb4)
1 0x0041ae23 in check_ping (+0x1ae22) (0x0032fe68)
2 0x0045c6f5 in check_ping (+0x5c6f4) (0x0032feb0)
3 0x7b46d860 call_process_entry+0xb() in kernel32 (0x0032fec8)
4 0x7b46d99b start_process+0x12c(entry=<couldn't compute location>,
peb=<couldn't compute location>)
[/home/focht/projects/wine/mainline-src/dlls/kernel32/process.c:1099] in
kernel32 (0x0032ffd8)
5 0x7b46d86e start_process_wrapper+0x9() in kernel32 (0x0032ffec)
0x00414db5: cmpw %bx,0x0(%eax)
Modules:
Module Address Debug info Name (66 modules)
PE 400000- 49c000 Export check_ping
ELF 7b400000-7b7f3000 Dwarf kernel32<elf>
\-PE 7b420000-7b7f3000 \ kernel32
ELF 7bc00000-7bd0e000 Deferred ntdll<elf>
\-PE 7bc30000-7bd0e000 \ ntdll
...
Threads:
process tid prio (all id:s are in hex)
...
0000008e (D) C:\Program Files (x86)\ICINGA2\sbin\check_ping.exe
0000008f 0 <==
...
--- snip ---
Source:
https://github.com/Icinga/icinga2/blob/5bd69b4a490b77ac5c3bf748606d4fffb9b3e1ee/plugins/check_ping.cpp#L289
--- snip ---
static int check_ping4(const printInfoStruct& pi, response& response)
{
if (l_Debug)
std::wcout << L"Parsing ip address" << '\n';
in_addr ipDest4;
LPCWSTR term;
if (RtlIpv4StringToAddress(pi.ip.c_str(), TRUE, &term, &ipDest4) ==
STATUS_INVALID_PARAMETER) {
std::wcout << pi.ip << " is not a valid ip address\n";
return 3;
}
if (*term != L'\0') {
std::wcout << pi.ip << " is not a valid ip address\n";
return 3;
}
....
--- snip ---
$ sha1sum Icinga2-v2.8.4-x86.msi
5bd6dfdd5e437ef12e20b580a2745564055a0ea3 Icinga2-v2.8.4-x86.msi
$ du -sh Icinga2-v2.8.4-x86.msi
28M Icinga2-v2.8.4-x86.msi
$ wine --version
wine-3.7-156-g6d6b4bffb3
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