Received: by 2002:a89:2c3:0:b0:1ed:23cc:44d1 with SMTP id d3csp1046777lqs; Wed, 6 Mar 2024 05:02:48 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCUj6AMnIghGVw+hWg4Wh2FTibQciF01tz6FxDpqEjYFJV4ftp4SDrkRjv4jY5aaYoQG5gSxCVc76twTVJZp+fL7MuC85dlt1ok1q4M8mA== X-Google-Smtp-Source: AGHT+IEI6xxXWSZFnR6j27VMLpYufALYx9RypREsi9YX06ps7+2ehmI/Ach0BaK+hF6Zbv47jqpy X-Received: by 2002:a25:ae89:0:b0:dcd:65fa:ea06 with SMTP id b9-20020a25ae89000000b00dcd65faea06mr11660516ybj.24.1709730167896; Wed, 06 Mar 2024 05:02:47 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709730167; cv=pass; d=google.com; s=arc-20160816; b=aA6GEAJ+q7qwTbSccCvJ346REO+fJxluln1f7Nfs2PekVew+D3I0zU4A/a43C1NhyY 43sXrEIo0F1zGMculqmrXGn9RmUmyYVrIT6J5NVgn+l5XcYIYITjFsu5Cw9JsrO5SmGE 9ULedOJQc9jxMkCAW99weVg3bzxiqdlkTIV7LU1MFrzKMxwZ1A2k0vYglu0iQcQ1w5MO RV/E7y0ruWyC4cIJ3ERCd1A3p9sGTkKQ0yFE5phlvKp+LEklqAU05wTeJ+BFqQs7URN9 41jpqnEj/ZN3r/UwnewlXe05h2C3GYQoDFSAQde2rLPmjPoZUGUAjY5rPADYAnPIwYBJ L3nQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:dkim-signature; bh=2scCxrSMIVw48B77Is9FzJLaywsQG2nWxV6RCAhtBdc=; fh=QhsPS20TapWd/xj9pEdmR9p4WZjUEo1KSNaZkCqwReo=; b=Xi5qn3j7zyhsziqdHNHQxV1N+jx0qx7aj25j8UiaAEXEBdt0uuc+vONP0+T57D82xI 3zPqvF3MqaRReAc/J/lJEKMXGRJ4Q43Be2EXgrk5rjbgER4p9G2bDhnGD4RaCsQIAtH6 Z0wtBmYceIiPwPaf5RFWGQF4uDzqKWhc/ueF47vq1/aGchE3/o7JTknB4m9wQZf+6mKZ BCItuX6Mr5p/d1K9DrL0odarnfn0egm4QphQPagYzyoXxcT5SSMoCwGkW9oDuDHmRkJL pb3ecb13HerBIviWwarJmlwD8HVGVKhhy1eKKPJh3LFTvJ6/gy0nG9yW3gG1f9d6LlF9 zKnA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=UbmVyClh; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-93938-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-93938-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id s4-20020a056902120400b00dcc0ac4ca8asi6609146ybu.67.2024.03.06.05.02.47 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 06 Mar 2024 05:02:47 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-93938-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=UbmVyClh; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-93938-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-93938-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 29D441C240B0 for ; Wed, 6 Mar 2024 13:02:34 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 4DA1B130AC7; Wed, 6 Mar 2024 13:02:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="UbmVyClh" Received: from mail-lf1-f42.google.com (mail-lf1-f42.google.com [209.85.167.42]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D1B8112D1FC; Wed, 6 Mar 2024 13:02:24 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.42 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709730146; cv=none; b=FS9RJzjJRFuXV7PjWjdDs5pM3XaSoosXSqz1pdslMxpUqyZOJlg7Axb3nGFVtefU010ASAkJkb7tMTdYBkffhpXziiRIqEzt9XUKaG0xiSKY2/Ek1X8BJURlVK2emUku5LwPnjap6ItC6mwQWAugHmUVbij0ctLCUwwzMDOVNro= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709730146; c=relaxed/simple; bh=4AFROTHMuHkNbiIJu1IN5g677k3qgMNbGiZ+lMx65Aw=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=qp+eHxOEBLspQif9dXkkLPl0vUlcedh8bvgNPYvZasgA02Yw1LWVEK4AW9cnbDEPHl2/aXa6ULt/EwND/7Ihe/mY8JXy5B3wFGTtzwmXCwuiv17yawbVZ1BQg+oiFVQGkeurV2esWswKkjNk3Gt+3SdtCl5wr7G0BkhE17/WlRU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=UbmVyClh; arc=none smtp.client-ip=209.85.167.42 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-lf1-f42.google.com with SMTP id 2adb3069b0e04-51326436876so1144819e87.1; Wed, 06 Mar 2024 05:02:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1709730143; x=1710334943; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=2scCxrSMIVw48B77Is9FzJLaywsQG2nWxV6RCAhtBdc=; b=UbmVyClhCT6RMXB6cGI7/sQ0jDAx/ak9gm3e5tkD9WPf368LVxUB1fxShiPMlwHwff vZaryrIJ+dAs3UKvpPTdLc5lc0ZZ2bCJh1qrcUB8vlavVp4OiNvh650RpTjkaTcwaSkK WJgvqPOq31zOYugkZBDCHqMFRllulZ67BZ7UUTSI6bak3BFgS0pgQ4HItufZi8lmQNoB LDA0V26/2V9H46sTs8Tm6nY8PndulUF0eqkxrwlD5jKYmvXUtlTZUDAc852nLrIY3cQg zOCmU60KhWVqiofm4Vi/Ajh8MB2jdrwJE+57V5v4rCmpDvMXeDN0t8qdZKZLI7n6PmMK cwxw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709730143; x=1710334943; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=2scCxrSMIVw48B77Is9FzJLaywsQG2nWxV6RCAhtBdc=; b=J6orjpd3TH3jeNrg+WzDUbd+HA1vppy0LTrfm/JMYavgGexL0sda9Rin+iNWYqVZrr 68rGAYvyV9X/l/Bp8vGm7gswA0+XunET4q+TNpQyoxYh7KnKTjUP4hpiuZk47H5O76Xd 4ctpVNwp89RB4wIBTh1R4pwsMcmgtpSzekOHJ/AQY178EsJjckSmK8g4HJrhNO9khS4C ldKEj/1Ctm+IrjDHiKMGh1ncMevL8VrMYwZwdwq6vEmET0UJJtOCCJgQNNF+iQNIg5LG u7QkUqoqhuHI4eyjod7TOncdfSNudXKaQiccqPsCKHB0dugfuI1wsRHJ5CeAbEyGHDUU X16w== X-Forwarded-Encrypted: i=1; AJvYcCWJvlWzYL/DOWyvpbpG/51BSKFPPHYB9au+/HZOHh9448RFy1mMaN5xeUztCHS1/UX/gMnSWrY6oPZo7FpEcjuSv+5I5RIfr6P8 X-Gm-Message-State: AOJu0YzYrpcs2dpoyCuLpH1hpUJiJMpmLCVVTdU0EjobeMhaj88/jwlc qEJzPAXb5owB0CMm4SE3sqpJTZYx2/zim4uhosiEvsp2nZj9AB0oQnfOF9HH1t4IsFSCgIqPeXC X6VVQv8g2BZYsYu2SjrfwDi+ZRya0Hiua X-Received: by 2002:a05:6512:6d3:b0:512:d6b6:dc44 with SMTP id u19-20020a05651206d300b00512d6b6dc44mr4301391lff.66.1709730142561; Wed, 06 Mar 2024 05:02:22 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <7ubz52rfdl2i76sotvd3s4thv6jvbfao6zct3sywqus2owlvkx@wpbeqqdvipo4> In-Reply-To: From: Oliver Crumrine Date: Wed, 6 Mar 2024 08:02:10 -0500 Message-ID: Subject: Re: [PATCH] ip.7: Add not supported by SOCK_STREAM to socket options To: Alejandro Colomar Cc: linux-kernel@vger.kernel.org, linux-man@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Wed, Mar 6, 2024 at 5:58=E2=80=AFAM Alejandro Colomar w= rote: > > Hi Oliver, > > On Tue, Mar 05, 2024 at 02:31:48PM -0500, Oliver Crumrine wrote: > > Hi Alex, > > I have attached two programs in the form of C source code below. No > > special compilation options required. To change between the three > > different socket options outlined in my patch, there are two options on > > line 16 and 18 with a comment above them explaining how to use the > > fields. > > > > Here's how to use the programs: > > 0. Make sure you have netcat installed. > > 1. Compile the dgram one. > > 2. Run it. > > 3. Run nc localhost 8888 -u (in a seperate terminal window or tab) > > 4. Type whatever into netcat and press enter > > 5. Observe that there is a control message recieved, and there is a byt= e > > printed, which is the first byte of the data in the control message. > > Can't reproduce this. The terminal running nc(1) isn't printing > anything. > > alx@debian:~$ which nc > /usr/bin/nc > alx@debian:~$ which nc | xargs realpath > /usr/bin/nc.openbsd > alx@debian:~$ dpkg -S /bin/nc.openbsd > netcat-openbsd: /bin/nc.openbsd > > > 6. You may repeat this for the three different socket options. > > 7. Repeat for the stream one, but use nc localhost 8888 (without the -u= ) > > for #5. > > 8. Observe that there are no control messages recieved with the stream = one, > > and byte is 00, which is the initial value of the variable, before it h= as > > a value assigned when the control messages (of which there are none) ar= e read. > > > > Thanks, > > Oliver > > Have a lovely day! > Alex > Hi Alex, Type into netcat, not the program I sent. My program is the server and prints out whatever it recieves, along with some other stuff that lets you know which options are supported. Thanks, Oliver