Erlang/OTP Forums

Author Message

<  Erlang questions mailing list  ~  is inet:gethostbyname( IP ) correct?

Guest
Posted: Mon Nov 02, 2009 5:48 pm Reply with quote
Guest
Thanks a lot for the feedback! Then this fix will be in the
next release.


On Wed, Oct 28, 2009 at 11:35:34AM +0000, Robert Raschke wrote:
> Hi Raimo.
>
> On Fri, Oct 23, 2009 at 1:56 PM, Raimo Niskanen <
> raimo+erlang-questions@erix.ericsson.se<raimo%2Berlang-questions@erix.ericsson.se>
> > wrote:
>
> > After a week of bug hunting we can confirm this is really
> > Microsoft's bug, but we have a workaround.
> > (It may be Microsoft's and Comodo's bug, who knows...)
> >
> > It turns out if you mix overlapped I/O with non-overlapped
> > (asyncronous with syncronous) on different pipes, in this
> > case the pipe to inet_gethost.exe from erlang was opened
> > by erlang as non-overlapped and inet_gethost.exe itself
> > used overlapped on all its other sockets and pipes...
> >
> > ...alright if you mix ... I/O something gets not initialized
> > in Microsoft's libs unless you do a gethostname() call
> > before going into recv() of commands from erlang (we already
> > found this out the hard way) but now also if you had certain
> > firewalls installed it was not enough, you had to do
> > gethostbyname() calls with longer domain names to
> > work around Microsoft's bug.
> >
> > Since this felt like a way to shaky workaround we found
> > another that seems much better: now erlang can open the
> > pipe to this specific port program (inet_gethost.exe)
> > for overlapped I/O so inet_gethost.exe now uses overlapped
> > I/O only. This seems to avoid the bug.
> >
> > We reproduced the name lookup freeze with Comodo 2.4.19.185
> > and Microsoft's Client for ISA Server 4.0. Here is
> > a snapshot build (without documentation) that
> > does not freeze for neither of these firewalls.
> >
> > http://www.erlang.org/download/snapshots/otp_win32_R13B03_gethost_fix.exe
> >
> > Try it and see if it solves your problem.
> >
> > / Raimo Niskanen
> >
> >
> >
> Congratulations! You have a winner.
>
> I have gone through the following tests:
>
> R13B02-1 on W2003, no Firewall Client for ISA
> inet:gethostbyname("localhost").
> OK
> inet:gethostbyname("local machine name").
> OK
> inet:gethostbyname("machinename.localdomain").
> OK
> inet:gethostbyname("www.google.com").
> OK
> inet:gethostbyname("www.cisco.com").
> OK
>
> R13B02-1 on W2003, with Firewall Client for ISA
> inet:gethostbyname("localhost").
> OK
> inet:gethostbyname("local machine name").
> OK
> inet:gethostbyname("machinename.localdomain").
> OK
> inet:gethostbyname("www.google.com").
> timeout
> inet:gethostbyname("www.cisco.com").
> timeout
>
>
> R13B03_gethost_fix on W2003, no Firewall Client for ISA
> inet:gethostbyname("localhost").
> OK
> inet:gethostbyname("local machine name").
> OK
> inet:gethostbyname("machinename.localdomain").
> OK
> inet:gethostbyname("www.google.com").
> OK
> inet:gethostbyname("www.cisco.com").
> OK
>
> R13B03_gethost_fix on W2003, with Firewall Client for ISA
> inet:gethostbyname("localhost").
> OK
> inet:gethostbyname("local machine name").
> OK
> inet:gethostbyname("machinename.localdomain").
> OK
> inet:gethostbyname("www.google.com").
> OK
> inet:gethostbyname("www.cisco.com").
> OK
>
>
> Brilliant work for tracking down this obscure behaviour.
>
> Robby

--

/ Raimo Niskanen, Erlang/OTP, Ericsson AB

________________________________________________________________
erlang-questions mailing list. See http://www.erlang.org/faq.html
erlang-questions (at) erlang.org

Post received from mailinglist
Guest
Posted: Mon Nov 02, 2009 11:00 pm Reply with quote
Guest
Hi both,
Nothing to add ... It was not easy to find and resolve this problem !
I changed the firewall version and now everything is ok.
Thank you to Raimo.
John

Hi Raimo.

On Fri, Oct 23, 2009 at 1:56 PM, Raimo Niskanen <
raimo+erlang-questions@erix.ericsson.se <raimo%2Berlang-questions@erix.ericsson.se >
> wrote:

> After a week of bug hunting we can confirm this is really
> Microsoft's bug, but we have a workaround.
> (It may be Microsoft's and Comodo's bug, who knows...)
>
> It turns out if you mix overlapped I/O with non-overlapped
> (asyncronous with syncronous) on different pipes, in this
> case the pipe to inet_gethost.exe from erlang was opened
> by erlang as non-overlapped and inet_gethost.exe itself
> used overlapped on all its other sockets and pipes...
>
> ...alright if you mix ... I/O something gets not initialized
> in Microsoft's libs unless you do a gethostname() call
> before going into recv() of commands from erlang (we already
> found this out the hard way) but now also if you had certain
> firewalls installed it was not enough, you had to do
> gethostbyname() calls with longer domain names to
> work around Microsoft's bug.
>
> Since this felt like a way to shaky workaround we found
> another that seems much better: now erlang can open the
> pipe to this specific port program (inet_gethost.exe)
> for overlapped I/O so inet_gethost.exe now uses overlapped
> I/O only. This seems to avoid the bug.
>
> We reproduced the name lookup freeze with Comodo 2.4.19.185
> and Microsoft's Client for ISA Server 4.0. Here is
> a snapshot build (without documentation) that
> does not freeze for neither of these firewalls.
>
> http://www.erlang.org/download/snapshots/otp_win32_R13B03_gethost_fix.exe
>
> Try it and see if it solves your problem.
>
> / Raimo Niskanen
>
>
>
Congratulations! You have a winner.

I have gone through the following tests:

R13B02-1 on W2003, no Firewall Client for ISA
inet:gethostbyname("localhost").
OK
inet:gethostbyname("local machine name").
OK
inet:gethostbyname("machinename.localdomain").
OK
inet:gethostbyname("www.google.com").
OK
inet:gethostbyname("www.cisco.com").
OK

R13B02-1 on W2003, with Firewall Client for ISA
inet:gethostbyname("localhost").
OK
inet:gethostbyname("local machine name").
OK
inet:gethostbyname("machinename.localdomain").
OK
inet:gethostbyname("www.google.com").
timeout
inet:gethostbyname("www.cisco.com").
timeout


R13B03_gethost_fix on W2003, no Firewall Client for ISA
inet:gethostbyname("localhost").
OK
inet:gethostbyname("local machine name").
OK
inet:gethostbyname("machinename.localdomain").
OK
inet:gethostbyname("www.google.com").
OK
inet:gethostbyname("www.cisco.com").
OK

R13B03_gethost_fix on W2003, with Firewall Client for ISA
inet:gethostbyname("localhost").
OK
inet:gethostbyname("local machine name").
OK
inet:gethostbyname("machinename.localdomain").
OK
inet:gethostbyname("www.google.com").
OK
inet:gethostbyname("www.cisco.com").
OK


Brilliant work for tracking down this obscure behaviour.

Robby


Post received from mailinglist
wuji
Posted: Mon Aug 13, 2012 7:06 am Reply with quote
User Joined: 10 Aug 2012 Posts: 654
Anderson has ordered a review of police response to the the imitation designer *beep* the incident.Luther was remembered as an "awesome guy" and was
well loved," Jay Allis, the kitchen manager at the restaurant, restaurant, cheap polo shirts restaurant, told ABC News' Nashville affiliate WKRN.A recording at the
East Cafe said it would remain closed for "an indeterminate indeterminate jordan 6s indeterminate amount of time due to a tragedy in out
Cafe family."Police Pursuits in California Have Injured More Than 10,000Nearly 10,000Nearly jordan 6 10,000Nearly 90 Percent of Pursuits are for Non-Violent OffensesBy DAVID
19, 2012 More bystanders are injured or killed during high-speed high-speed [h3]cheap polo ralph lauren[/h3] high-speed police chases than by stray bullets. In California, more
10,000 people have been injured and over 300 people killed killed [h4]cheap designer *beep*[/h4] killed because of police chases in the last decade, according
newly released statistics from the California Highway Patrol.Nationally, it's estimated estimated [h2]jordan 6[/h2] estimated nearly 300 people die each year as a result
View user's profile Send private message
wuji
Posted: Thu Sep 13, 2012 7:53 am Reply with quote
User Joined: 10 Aug 2012 Posts: 654
even by some very close family members, though."That was bad because they they cheap authentic air jordans they loved me and I loved them," she said. "And they didn't
me in the house."She said that wanting to be accepted for who who cheap jordan shoes who she is drove her to come out on television that year
Jerry Falwell, Pat Robertson and other members of the evangelical community who who cheap designer *beep* who said they were disappointed. Some called her "Ellen Degenerate.""You know Ellen
such a good person," her mother said. "Now, I don't want to to cheap polo shirts to get weepy, I don't, but she's so good that she shouldn't
all this directed at her."Today Betty DeGeneres fights for gay rights. She She [h1]designer replica *beep*[/h1] She is devoted and always tolerant.Bill Clinton Boosts President Obama - So
George W. Bush for Mitt Romney?2 Prior Presidents Take Dramatically Different Approaches Approaches cheap Ralph Lauren Polo Approaches to 2012 CampaignBy JOEL SIEGELMay 4, 2012 — He was once
View user's profile Send private message

Display posts from previous:  

All times are GMT
Page 3 of 3
Goto page Previous  1, 2, 3
This forum is locked: you cannot post, reply to, or edit topics.

Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum