delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2020/06/07/14:20:35

X-Recipient: archive-cygwin AT delorie DOT com
DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org DA3EF386F457
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cygwin.com;
s=default; t=1591553990;
bh=xbbbJlbvxD0h4T5L/qxuOF5LtIG7RXqNX69vajetx2Y=;
h=Subject:To:References:Date:In-Reply-To:List-Id:List-Unsubscribe:
List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:
From;
b=joHs1JBDkVyKgdIDcWx8doxKrMkxsqoOnzayREnn0iVfdA+tW3c1ENdjqpMdm2mdS
DhNTp2c/w/RIT9+DE1KYyAVBnyFLtWloNU4UfdJDHtFXijLBFl2+6RZB9TFHm6G+jJ
lANxpQRwoqAzgByL3B63OB/zt1Ld5BoAh40HlX0g=
X-Original-To: cygwin AT cygwin DOT com
Delivered-To: cygwin AT cygwin DOT com
DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 8741E3858D34
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none;
b=n/vlKoxJrqzulLZ53j+u0qudOSP5b3aZMSY0bTnhISCL+xzLx4zKYzN9MoOrbQgrueQFBpxp1ey6uut6fOYp7tpS/ZVCaBfFtwrHsoKd0B+Ok55R5ExZmMLDPe3wuXCDAb8Rd66XHX3YxtYjE+VBeeaVPGHR0VT8g1A8lYDW03dOaB4GK4kpQLaB/au/1SPF2HkubSW6SMxXeyCGdweNM7DQblqi152PSanGYa8pLUrnuqDlz4W/emYn+Qq2QDEn4n7QBX+TGCGU09wTRrzvjkIvrnAVKAlysuZf481leCGkvModv74zgS6eZN0eiYTM3Ik+qFfLqqvoLg+88qy2eQ==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com;
s=arcselector9901;
h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck;
bh=y0o3xl3Yiwub2MG5GYY8TqZKXl69+34Ia9ZOCmciotU=;
b=Azybh5TJIpeo1/fjs/olgX1C+P3mAdpV1cE0ysl/CtjLv/J1HcX3nS1nm0jQPaxDTo12SPga+yCj6dFlSqhXRwYrvePz97b0OV0HhtnNq/YlQGA3IyAu4GB6IXb6N666xKq3+p7o3zDo51RgnakO/wa56ACVitu220Ja8L29yrRgC+FrCB2XTE5+cm39XVHh43izv3+8RoZgKNF04Z0+4zxAlbqfp/PedsRpW6QZVTbZwofd1nPeIea+p91y3Gcg/5YxGmPUMshCzLYZFBBjs7iRqmS8wRMpT/4PMBpApzNR+pafTQxaIgeGqlddgP8DOQG4Ueds20NaDVX+F5AG4A==
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass
smtp.mailfrom=cornell.edu; dmarc=pass action=none header.from=cornell.edu;
dkim=pass header.d=cornell.edu; arc=none
Subject: Re: TCP_KEEPINVTL and TCP_KEEPIDLE - Socket Keep Alives not working
To: cygwin AT cygwin DOT com
References: <CAEF1h+WHsGXzSykQ0G3aXG=8jY5VmpYQQiYNP7DjHJTS1Bkpsw AT mail DOT gmail DOT com>
Message-ID: <ba71f855-276d-9d45-5c78-6d0a91dc57dd@cornell.edu>
Date: Sun, 7 Jun 2020 14:19:40 -0400
User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101
Thunderbird/68.8.1
In-Reply-To: <CAEF1h+WHsGXzSykQ0G3aXG=8jY5VmpYQQiYNP7DjHJTS1Bkpsw@mail.gmail.com>
X-ClientProxiedBy: CH2PR05CA0010.namprd05.prod.outlook.com (2603:10b6:610::23)
To MN2PR04MB6176.namprd04.prod.outlook.com
(2603:10b6:208:e3::13)
MIME-Version: 1.0
X-MS-Exchange-MessageSentRepresentingType: 1
X-Originating-IP: [2604:6000:b407:7f00:1147:7d51:7b1e:cfcd]
X-MS-PublicTrafficType: Email
X-MS-Office365-Filtering-Correlation-Id: 0e878999-530f-4141-a507-08d80b0f5a24
X-MS-TrafficTypeDiagnostic: MN2PR04MB6270:
X-Microsoft-Antispam-PRVS: <MN2PR04MB62702E5FCE210F5AF39C9C5DD8840 AT MN2PR04MB6270 DOT namprd04 DOT prod DOT outlook DOT com>
X-MS-Oob-TLC-OOBClassifiers: OLM:6790;
X-Forefront-PRVS: 04270EF89C
X-MS-Exchange-SenderADCheck: 1
X-Microsoft-Antispam: BCL:0;
X-Microsoft-Antispam-Message-Info: fGCSWDh3xsms+fW8zURsI+hs7JWguzmvJKZMhPp9vs8dSUY6vrXLjKow95HFQVAtl8QvvB4AxSVVmdtngiXwFhAcM4BeC9puAUCYz0dkEf2IYnMqIDkE0waudZ7l5g0wnbnWj+1T0VKBjKaa1teW8SkNkrKV1wbPJ9EZZDCiJcFGTXUTot1XfbQCOWePss38KpBd5noHYF1bIzFuEsMwmlJyovaoKOJgv6JjEo41E1SkNhxIk8YW+gvfoRm+r9qArUDznBnRCLrjrclX64JR/EqIBPSrxsXnS8vfCLjjtNl05vNQwetPQ7V0S8vcWLiF7s01UDb6M3vBmN2x8Jt39esni/eWMs0H/14uomuq80s0nEsdy/B01Lf1l6YCAxyT
X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:;
IPV:NLI; SFV:NSPM; H:MN2PR04MB6176.namprd04.prod.outlook.com; PTR:; CAT:NONE;
SFTY:;
SFS:(4636009)(396003)(376002)(346002)(366004)(136003)(39860400002)(52116002)(66476007)(66556008)(53546011)(86362001)(2906002)(31686004)(66946007)(31696002)(36756003)(2616005)(8936002)(6486002)(6916009)(75432002)(5660300002)(478600001)(8676002)(786003)(316002)(186003)(16526019)(43740500002);
DIR:OUT; SFP:1102;
X-MS-Exchange-AntiSpam-MessageData: 9aEgAhr0wW5uari9TodxHZX7ouK98b2J7XA7V32/xCzLmktY5X1qhRjAzzBs4SfDgmpZDr5zmz89EloE/1Spsc3kYng2OYR6xHVkir7d79VbFEu7xMdvG+sD7SrkOsQCJTYSaEcfPtemziVr7PkNiVAkYT/FfFMvRyFnphWdkfaDe+UXeI2sNFaLhTjDY3YmEUCNDZBra7YkRE64RzTPuGiolfcafin4tZ1uRUiWNCeOWuVpzILFtsJaZ/81KiKSL58uwQPgr1ID6YU13tlsnzXT8zCcJYPD7Y9jHNBXo+IU4ACdoArsR16c9rs1gsoxUr1bsH5pZK05U66GWqGwt+N4/eLbqbc+gXeObHqHAhfGQwHuMK0nbFQqRl0kBLB5NjGZ7x3qXh6k2fxXN5CQ4hoT/4vZDvTfl5U0ZMKzanevAX3DS48zfRRUlDAPrJ61MGfvP2/Ty6NX8IselCdeZZylreGzkGCA0ugu086YIz+bmC8WHg67u3jgwAUNSTL/SM6TrCSKgQT/sVeTTtqo5Izil3zCwuQ2uzthMqaYRDk=
X-OriginatorOrg: cornell.edu
X-MS-Exchange-CrossTenant-Network-Message-Id: 0e878999-530f-4141-a507-08d80b0f5a24
X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Jun 2020 18:19:43.8810 (UTC)
X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted
X-MS-Exchange-CrossTenant-Id: 5d7e4366-1b9b-45cf-8e79-b14b27df46e1
X-MS-Exchange-CrossTenant-MailboxType: HOSTED
X-MS-Exchange-CrossTenant-UserPrincipalName: gY9g5nLzYJRdelmqcKwCpkbPivDOCexeZ4rBZTivNtO5M518p3FqPu8wj+fpnOGvsc3Cooi66tW9C/tTNGa4xQ==
X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR04MB6270
X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00, DKIM_SIGNED,
DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, MSGID_FROM_MTA_HEADER, SPF_HELO_PASS,
SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on
server2.sourceware.org
X-BeenThere: cygwin AT cygwin DOT com
X-Mailman-Version: 2.1.29
List-Id: General Cygwin discussions and problem reports <cygwin.cygwin.com>
List-Unsubscribe: <http://cygwin.com/mailman/options/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=unsubscribe>
List-Archive: <https://cygwin.com/pipermail/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-request AT cygwin DOT com?subject=help>
List-Subscribe: <http://cygwin.com/mailman/listinfo/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=subscribe>
From: Ken Brown via Cygwin <cygwin AT cygwin DOT com>
Reply-To: Ken Brown <kbrown AT cornell DOT edu>
Errors-To: cygwin-bounces AT cygwin DOT com
Sender: "Cygwin" <cygwin-bounces AT cygwin DOT com>

On 6/7/2020 9:20 AM, Cary Lewis via Cygwin wrote:
> These constants are usually defined in  netinet/tcp.h but are not defined
> anywhere in cygwin.
 >
> As a result there does not seem to be a way to enable the socket level keep
> alives in cygwin.
> 
> One result of this is curl's --keepalive-time option does not work, but it
> would affect any attempt to enable socket keep alives.
> 
> Windows' sockets do support keep alives, and indeed the win32 version of
> curl works correctly.
> 
> Can someone explain why the TCP keep alive constants are not defined

I'm not an expert on sockets, but I'll just make a couple of comments until 
Corinna has a chance to give a definitive reply.

Cygwin's netinet/tcp.h was derived from the FreeBSD version of the file dated 
2000/01/09.  It has hardly been touched since it was imported into Cygwin in 
2002.  FreeBSD didn't add keepalive support until 2012.

> Is it possible to add this functionality?

If you're asking someone else to do it, the question is whether one of the 
Cygwin developers has the time and expertise to do it.  If you're volunteering 
to do it, patches are always welcome.

> Where in the cygwin source code does the actual posix socket to winsock
> translation take place?

Cygwin's socket support is in the fhandler_socket* files.

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

- Raw text -


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