delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2016/01/10/04:09:46

X-Recipient: archive-cygwin AT delorie DOT com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:to:from:subject:date:message-id:references
:mime-version:content-type:content-transfer-encoding; q=dns; s=
default; b=ROQ94qFnPOnqKMrhZW1w1vPRMKAMOkln49yPSnzhr3h98/2mu7eWC
EuY7hytwlsbK3MFr3ztUsbxVhGQAkfUiX8KqusdSonZsGdREP5UAY3+pVLtdL1cj
7gv6Ndda83nTs36XjhGjaaxbZypI2WHjiMBDM4taNEGp9Wg7UMEUzc=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:to:from:subject:date:message-id:references
:mime-version:content-type:content-transfer-encoding; s=default;
bh=/i/UM9nFTm4rhKKBFW2dKMhCgsA=; b=LsjE7erQKR1L44b/F1VNChtBRA/M
px++4yQKIxS7dNXHNoWzWGBQquO4pWgsDNJP30EKDWvMufm/wYmZSSgbSvBt801Q
SYzuM6PNx2NEQZc1qaNIqdW0bKPTXn+9g46/lSx4sWcHd+1gaNLFjxwnpSxlfQrG
LQ+8MIQxszb6Ga8=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Authentication-Results: sourceware.org; auth=none
X-Virus-Found: No
X-Spam-SWARE-Status: No, score=1.6 required=5.0 tests=AWL,BAYES_50,RCVD_IN_DNSWL_LOW,RP_MATCHES_RCVD,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.2 spammy=H*MI:sk:loom.20, Hall, falling, H*MI:sk:5690039
X-HELO: plane.gmane.org
To: cygwin AT cygwin DOT com
From: Brian Inglis <Brian DOT Inglis AT SystematicSw DOT ab DOT ca>
Subject: Re: getaddrinfo fails with =?utf-8?b?RUFJX05PREFUQQ==?= for some valid hosts with A records
Date: Sun, 10 Jan 2016 09:09:10 +0000 (UTC)
Lines: 67
Message-ID: <loom.20160110T091145-463@post.gmane.org>
References: <loom DOT 20160107T163448-78 AT post DOT gmane DOT org> <20160108111408 DOT GH20447 AT calimero DOT vinschen DOT de> <5690039E DOT 6000704 AT gmail DOT com> <20160108185205 DOT GL20447 AT calimero DOT vinschen DOT de> <004701d14a4f$b0182820$10487860$@comcast.net>
Mime-Version: 1.0
User-Agent: Loom/3.14 (http://gmane.org/)
X-IsSubscribed: yes

Andy Hall <fixpertise-consulting <at> comcast.net> writes:
>> On Jan  8 13:44, cyg Simple wrote:
>>> On 1/8/2016 6:14 AM, Corinna Vinschen wrote:
>>>> $ ./gai leapsecond.utcd.org
>>>> ret = 11004
>>>> I have no idea why Windows' getaddrinfo chokes on leapsecond.utcd.org
>>>> at all.
>>> utcd.org doesn't resolve for me.  So getaddrinfo has no info to get.
>> Why then does it work on Linux?
> nslookup works for me:
> Win7 64-bit
> $ nslookup leapsecond.utcd.org
> Non-authoritative answer:
> Server:  UnKnown
> Address:  192.168.1.1
> Name:    leapsecond.utcd.org
> Address:  244.34.36.97
> Win10 64-bit
> C:\Users\Andy>nslookup leapsecond.utcd.org
> Server:  UnKnown
> Address:  192.168.1.1
> Non-authoritative answer:
> Name:    leapsecond.utcd.org
> Address:  244.34.36.97
> However,  tracert and ping  yield this on both W7 & W10:
> $ tracert leapsecond.utcd.org
> Unable to resolve target system name leapsecond.utcd.org.
> $ tracert 244.34.36.97
> Tracing route to 244.34.36.97 over a maximum of 30 hops
>   1  Transmit error: code 1231.
> Trace complete.
> $ ping 244.34.36.97
> Pinging 244.34.36.97 with 32 bytes of data:
> PING: transmit failed. General failure.
> PING: transmit failed. General failure.
> PING: transmit failed. General failure.
> PING: transmit failed. General failure.
> Ping statistics for 244.34.36.97:
>     Packets: Sent = 4, Received = 0, Lost = 4 (100% loss),
> Weird!

Everything works in my STC except Cygwin x86/x64 
"getent ahosts leapsecond.utcd.org" 
on Windows 7 x64 which uses Cygwin getaddrinfo. 
Windows getaddrinfo (ASCII names) in Corinna's STC; Cygwin getaddrinfo, and
Windows GetAddrInfoW (UCS2-LE names) used in the Cygwin implementations,
fail in my code. 
Identical code works from Linux via the same router, and Corinna's MinGW STC
indicates the problem is Windows code, not a BLODA, unless we define Windows
as a likely BLODA. ;^> 

Worked around the problem by falling back to trying gethostbyname when gai
returns 7 EAI_NODATA because GAIW returns 11004 WSANO_DATA. That error is
normally reported when there are no A (and/or AAAA, depending on family and
flags in the call) records for a domain name (most commonly only MX for mail
server, possibly CNAME misspelled or with missing associated A/AAAA, or
other DNS mis-configuration). 

Running whois utcd.org replies normally; whois, traceroute/tracert, and ping
all fail on the name and address as there is host at that address. 
The domain, name, address, SOA, NS, A, and PTR records were set up by P-HK
(phk.freebsd.dk) to provide leapsecond info from IERS Bulletin C encoded in
an address in the IP V4 global class E experimental 240/8 space, see code at
http://phk.freebsd.dk/time/20151122.html. 
An update is due next week for the end of June, when no change is expected,
except the date updated to be valid until after then. 



--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019