delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2017/03/30/12:44:44

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:mime-version:in-reply-to:references:from:date
:message-id:subject:to:content-type:content-transfer-encoding;
q=dns; s=default; b=Vw8aTTZ2qbG5zEoKU702UEABghlQ8cgflgeNIUrwxQr
6TvsklFYPC7iM4/PRng9ocdwYcXz1Lx34lVdv1R76CX9Q/A7JXqDzYon4kxpR96M
mUQTX7o1NKbDq5ornqBcP0C/wbFCp7gRWAxjYRcGZ+gGtW9o5KhCqB9Np/MYvlH0
=
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:mime-version:in-reply-to:references:from:date
:message-id:subject:to:content-type:content-transfer-encoding;
s=default; bh=b13pUACvJtd2sATKV2Sk9ecc+Mk=; b=M/dReF/xbY3hk6iko
YNn0Z5361X0fXm4z0E2/pUSDG+itWoZAuzZWK1BSjf12//4Jstnh3TDWqw+Xv9Aw
J62+9szAO8ndIslsp5Hk8f65/cOnbcNoImfiOA9k7QKjsm0cUV5YsE65O/B26Hs7
Hf7l2YJIr+9V8CgA4qzo7I0idg=
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.1 required=5.0 tests=AWL,BAYES_50,RCVD_IN_DNSWL_NONE,RCVD_IN_SORBS_SPAM,SPF_PASS autolearn=no version=3.3.2 spammy=deployed, listened, UD:So, dose
X-HELO: mail-oi0-f44.google.com
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:content-transfer-encoding; bh=/661frhbestU2CDHyoLSd6nplzMyWKBxeZAjEOVO07Y=; b=YVlQGaQt+Ift+X62IGg12fBPxFrH+mV9j+PBxU2lRCOsNeGH1+oNSw4JBHWz8pR9og e6ekLwhgwPQMfMty8ICNpYAdP7EqDu6I50ST7KPJT9Xjfh1Md7D38s6l9c8pEmt6CqJk 82rpdwEkmUNcpnC+W2L9R2AGJ2Dh635qGG2VLNPuM+WMrjJF9CA/96GYfnXF7QknR84b me/dXzGZ86XioNmbYf0QU3qMPwhz0A84qqPPdC29mMmYDxdy530B5Jfp88My+6P2jLaF JiFIOoSFOi7wsaMnLYT4Q+FleLiXM5GcdgxIoJUtXQlHYfIqQ94vKxRWj9zbc01TtKZS n65A==
X-Gm-Message-State: AFeK/H0slN5uinBmL++4IDBtLUsCMtjvUDXM/c+0VmVy+tM3FTvFyyhZ6cG+BCz7IRID1WKazEs7X8Yrg9EWWw==
X-Received: by 10.157.1.134 with SMTP id e6mr333305ote.168.1490892261250; Thu, 30 Mar 2017 09:44:21 -0700 (PDT)
MIME-Version: 1.0
In-Reply-To: <000701d2a91e$c9b5bed0$5d213c70$@139.com>
References: <000701d2a91e$c9b5bed0$5d213c70$@139.com>
From: Michael Enright <mike AT kmcardiff DOT com>
Date: Thu, 30 Mar 2017 09:44:20 -0700
Message-ID: <CAOC2fq9vVLxCjUGJQUW7e0vagpjsft5oLiZTqzwFdox+8apb9g@mail.gmail.com>
Subject: Re: reply: problem with nc 1.107-4
To: cygwin AT cygwin DOT com
X-IsSubscribed: yes
X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id v2UGigOG026423

On Wed, Mar 29, 2017 at 11:28 PM, 高锋 wrote:
> Two days ago,i wanted to determine whether a udp port of another machine is open or not, which is deployed on different subnet.
> But windows platform does not provide utility that can dose this.So i downloaded a setup.exe from cygwin,of which version is 2.877(64 bit),and i had never use this utility before.

I tried this command on Debian 8.7. My conclusion is that this didn't
tell me that the UDP port is listened to by another machine. I used
your exact command, which had similarly uninformative results as
yours. There is no 10.31.x.x machine that I can reach, yet 'nc -u'
allowed me to send text to that address and port. Strace of 'nc -uz'
showed that the special -z option (zero i/o port scan) code "sent
successfully" a single byte to the destination, even though it doesn't
exist.

I conclude that "nc -uz" can't be used to determine unambiguously if a
UDP host is available, because it will succeed even if the host is not
present. And that carries to all systems that use the same 'nc'
utility as Debian or Cygwin.

--
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