Re: [dnssd] SRP: how to remove all published services?

Esko Dijk <esko.dijk@iotconsultancy.nl> Fri, 15 September 2023 16:30 UTC

Return-Path: <esko.dijk@iotconsultancy.nl>
X-Original-To: dnssd@ietfa.amsl.com
Delivered-To: dnssd@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 33C99C14CE45 for <dnssd@ietfa.amsl.com>; Fri, 15 Sep 2023 09:30:02 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -7.108
X-Spam-Level:
X-Spam-Status: No, score=-7.108 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H2=-0.001, RCVD_IN_ZEN_BLOCKED_OPENDNS=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01, URIBL_DBL_BLOCKED_OPENDNS=0.001, URIBL_ZEN_BLOCKED_OPENDNS=0.001] autolearn=unavailable autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1024-bit key) header.d=iotconsultancy.nl
Received: from mail.ietf.org ([50.223.129.194]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tQzZ5Qq_YdCQ for <dnssd@ietfa.amsl.com>; Fri, 15 Sep 2023 09:29:56 -0700 (PDT)
Received: from EUR01-VE1-obe.outbound.protection.outlook.com (mail-ve1eur01on2093.outbound.protection.outlook.com [40.107.14.93]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 78F8EC151060 for <dnssd@ietf.org>; Fri, 15 Sep 2023 09:29:55 -0700 (PDT)
ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Of7Uf4AWPIUDs4lruhMi0Ukxues0e6/RV/rPqR4GyMl7vPI08GYsoesyF7oO1EplcpMqUY6wjq1kNzWL+Bgr7M7LgwzU6OHlkJKxuUPXa/sirpGiVRyyWq1Qn5WB9+HHg5RKrFfHTuna7vSv08DocygB8Xq8GIPG51KgUH1EcuKFWkJzUIaMGMUcCQ5Zr8KP271oxUYDQ3S1/JAhRWQMJcn8woK2W/f7l+QxRQP67Laa8GPXXwRbiLDEQSqTV1gdPKJzYR+PbRs4m4TObKrMRnLXSMrzHWOqfYlJTAcshrB1WE5Drvr1/EqdFmZsmrkpjgjA+FLEGw3WqFpHNmVTgA==
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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=XFqhOeB/dPGkX0sni2zyQAj7upPO+x1XoXQjnc22TZc=; b=NJgPntHPrkscu8kD9ajX6z0r988NOLdE6fVRQJbhf3nofot36IouXxpyQIjj4GyCTBLjiVfaXqHuKNGrbvx1eckb6bj/R00UJ7U6s+0M8sgvTy9K6OZFyFHelvHIYWGlMjk50PgdzFnAgncrQEz0GaasKeatDdtY7eTl3rlgv6vDWbOYERYW+WBUaI8w/ttCIk/btUfRpAqb2CN3Iahz4VxBU7Ra1EczL/EPoCYZY4eiR2PCvzH/Qmhzdg0JCiqLa/jV3T+H/bGmeA0C5YOKL1ttUSUCMhHbE9JcCvBDYYtnC2sigFJ2c/EI9eCx+uVkoJ/63WslptTEkqMqFRqS4w==
ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=iotconsultancy.nl; dmarc=pass action=none header.from=iotconsultancy.nl; dkim=pass header.d=iotconsultancy.nl; arc=none
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=iotconsultancy.nl; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=XFqhOeB/dPGkX0sni2zyQAj7upPO+x1XoXQjnc22TZc=; b=S7FUvFWgHVCD/JsDKPUOpN+0Oiyuar9yBL7J3nYZUywL0UthyaDTBbahg/sUNoGZkyl5dGqCf0cbGEWoiyTwIhJEnbuA77vvi0tXWhgCCFGGCIyBCUDxVXtv9O2WlN0SbXLDLEbst0JgZWnznxHpcg4fSNxIrL1yB/T85ph33vc=
Received: from DU0P190MB1978.EURP190.PROD.OUTLOOK.COM (2603:10a6:10:3b9::20) by DB9P190MB1194.EURP190.PROD.OUTLOOK.COM (2603:10a6:10:1fd::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6792.21; Fri, 15 Sep 2023 16:29:51 +0000
Received: from DU0P190MB1978.EURP190.PROD.OUTLOOK.COM ([fe80::6cab:dca2:fbc5:20d9]) by DU0P190MB1978.EURP190.PROD.OUTLOOK.COM ([fe80::6cab:dca2:fbc5:20d9%3]) with mapi id 15.20.6792.021; Fri, 15 Sep 2023 16:29:51 +0000
From: Esko Dijk <esko.dijk@iotconsultancy.nl>
To: Ted Lemon <mellon@fugue.com>, Jonathan Hui <jonhui=40google.com@dmarc.ietf.org>
CC: "dnssd@ietf.org" <dnssd@ietf.org>
Thread-Topic: [dnssd] SRP: how to remove all published services?
Thread-Index: AdnnEtPVCiGM8RvvQuuerShW3Rm3zgAzmYeAAABSGwAAAAVdAAADPF4w
Date: Fri, 15 Sep 2023 16:29:51 +0000
Message-ID: <DU0P190MB1978C0CFEB3339C308FBF30DFDF6A@DU0P190MB1978.EURP190.PROD.OUTLOOK.COM>
References: <DU0P190MB1978B5A8AA3745770E94EEA5FDF6A@DU0P190MB1978.EURP190.PROD.OUTLOOK.COM> <CAGwZUDtz86KtOvtxeACGSDP9dSCJdoKGWHQ_5imVwZYQDom4yQ@mail.gmail.com> <CAPt1N1kjMmnVMkkE7hsbnzf-T79GKSrcL3_oC8X_Pm47_xvkbw@mail.gmail.com> <CAPt1N1kMPCtvT6KdMzF3mKWJQH7R2mJhUxYsBcU7ADtp2=9Abg@mail.gmail.com>
In-Reply-To: <CAPt1N1kMPCtvT6KdMzF3mKWJQH7R2mJhUxYsBcU7ADtp2=9Abg@mail.gmail.com>
Accept-Language: en-US
Content-Language: en-US
X-MS-Has-Attach:
X-MS-TNEF-Correlator:
authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=iotconsultancy.nl;
x-ms-publictraffictype: Email
x-ms-traffictypediagnostic: DU0P190MB1978:EE_|DB9P190MB1194:EE_
x-ms-office365-filtering-correlation-id: 3d9300c9-6ac0-4639-ffd0-08dbb608fc7c
x-ms-exchange-senderadcheck: 1
x-ms-exchange-antispam-relay: 0
x-microsoft-antispam: BCL:0;
x-microsoft-antispam-message-info: TkRlGp4jwyjKcMSEn9B0DZABaksWDn1SCIw2mZxuTaaebGs1ico1eyP+JCD6dNfWw8SLILL3ke5xVACXGWPMs6yH0E2oZP3bG2HW6F0E9sJu2dsF0YezhW0nBTJ+6bLxIm65TTvrSXWbV83ay4T3IOsMkBW9jffhnY8St1Bp+Ey4f8a372pPHL4MakuEZ5jjKbkNDzzKK2XRH+/aYs/YfuuRV2iBntOCuh1aaSLJsheTdXGmsGJMWcg5ZriimBhrK0UldzABVT/tdkDy0m9/aW4AUFg+AcQPDjteTcq44D5g4dowXLJk9w0bvqgMi6RYmZAM3SCFwUh0FAvWFlfoF5rm89+m8kRJiMXB0tY+by5k6OwAxhpE1cw9mLpFDoXzdkZ88iibQdvhH9AovpYo/Y0xA6O5Xf2qWDV+9z8abeJ1xSF/RDFgHVRZ/p9MFBMcE1hizxbMR43aAgpZTfekUfI6jrbqjaGpFrK7be9nMfXi6MwrNY1ZtDd1qOPAEDTs3ma/74DanP47wa6nn4E4aamH2zuM65x/EMl6o0SKfJex9xsS+ZoT917U+zNLtdgC4vukBhhT93s/FBs1fjjIpE+JAPnY0Bi6ZQ0/XUO7KQo=
x-forefront-antispam-report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:DU0P190MB1978.EURP190.PROD.OUTLOOK.COM; PTR:; CAT:NONE; SFS:(13230031)(396003)(39830400003)(136003)(376002)(346002)(366004)(186009)(1800799009)(451199024)(52536014)(5660300002)(8936002)(8676002)(4326008)(2906002)(83380400001)(166002)(86362001)(122000001)(38070700005)(38100700002)(33656002)(55016003)(44832011)(6506007)(7696005)(71200400001)(76116006)(110136005)(64756008)(66946007)(66476007)(66556008)(53546011)(66446008)(478600001)(966005)(41300700001)(9686003)(316002); DIR:OUT; SFP:1102;
x-ms-exchange-antispam-messagedata-chunkcount: 1
x-ms-exchange-antispam-messagedata-0: HK+tWKqN/Q6uCuHmD2UlWOSLkCb9IQEbEgPxR7NsivttrdpLrKWrfl5EsgkJYQ23MKxYwwCTXapxS1nb8DQD/KC4YCH+lf/zPDORXKXQPL7qYt2qIjQaDrcvv4sKwsnlvynTY48CLKlYwewk1yytbeiP7QrZOQI6URCZ/USPXmN7Qtb1X02O01WyknryZ7EhxYibJjYhGb9mHMg43E13UDeZk6Es0itAAQkw77GbgK1pOi9+C63s98ssvzDB/mrht+y2XAJAVIhpDfVGp7nT13cA5QZRlQq+gAY/FA+lPYe4WFHAgy5hO+aLQ1+vlIZGaZvZcFdRyHNwoRI7p4gFLi3yootwDcL99oeLcWGhlbtVckBRYHn5Tdj5TDsfcM+jsaIG7C7F7Y+PAjK6jng6gHGcLyRFb8pBvYQ9CmwGheK6IsWo+E8YUGBg0ppxFNX5ZJ8BHWYXnhrZ4WN6pQP6fHRCj69G+fmj+QcKTJcQIwZdImydVWtIwkHdmoC6Q9TMVz+PKuVEr4myuq6BeulucvCc7EHmL5A+XS/q9AIEFajOvhN/MGcaVJQrbqL84tv1lMvGuvaCKqXG9o3AHi+0bTVcyqXl8LL1Lovv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alternative; boundary="_000_DU0P190MB1978C0CFEB3339C308FBF30DFDF6ADU0P190MB1978EURP_"
MIME-Version: 1.0
X-OriginatorOrg: iotconsultancy.nl
X-MS-Exchange-CrossTenant-AuthAs: Internal
X-MS-Exchange-CrossTenant-AuthSource: DU0P190MB1978.EURP190.PROD.OUTLOOK.COM
X-MS-Exchange-CrossTenant-Network-Message-Id: 3d9300c9-6ac0-4639-ffd0-08dbb608fc7c
X-MS-Exchange-CrossTenant-originalarrivaltime: 15 Sep 2023 16:29:51.4705 (UTC)
X-MS-Exchange-CrossTenant-fromentityheader: Hosted
X-MS-Exchange-CrossTenant-id: 58bbf628-15d2-46bc-820b-863b6774d44b
X-MS-Exchange-CrossTenant-mailboxtype: HOSTED
X-MS-Exchange-CrossTenant-userprincipalname: Fd70gxIzvxen4J04x369O+Lm+r7RL5I/9S4fh5S30m1qJb8feo7eqBTzndlOz88zrIct/cdBMwoye3FWBAMekWAFOQ1gx4m6YCgtbDrM0Kg=
X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB9P190MB1194
Archived-At: <https://mailarchive.ietf.org/arch/msg/dnssd/1bVSd0egpGG9vlGhPy9QBWXTCv4>
Subject: Re: [dnssd] SRP: how to remove all published services?
X-BeenThere: dnssd@ietf.org
X-Mailman-Version: 2.1.39
Precedence: list
List-Id: "Discussion of extensions to DNS-based service discovery for routed networks." <dnssd.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/dnssd>, <mailto:dnssd-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/dnssd/>
List-Post: <mailto:dnssd@ietf.org>
List-Help: <mailto:dnssd-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/dnssd>, <mailto:dnssd-request@ietf.org?subject=subscribe>
X-List-Received-Date: Fri, 15 Sep 2023 16:30:02 -0000

Thanks, I didn’t yet consider this paragraph because it said “when a host is removed” and my use case in mind was removing all the services but not the host.
But, I see now that the Host Description Instruction is mandatory in the SRP Update, so that sending any valid SRP Update with a LEASE time of 0 will always delete all services!
That’s because the host gets deleted by this update and there’s no way to not include it.

So there is no strict requirement to “retransmit its most recent update” at all, then. The requestor could just send a single Host instruction with lease time 0.
Or include any one or more of its registered services; the effect should be the same.   It could even include a non-existing service in its SRP Update: even that should work.

Why not make the SRP Update message as short as possible by not including any services – only the host instruction with lease time 0? On 6lowpan mesh networks that definitely is helpful.
I tried the OpenThread implementation and it includes all registered services in the “delete all” SRP Update which shouldn’t be needed.
Hope I’m not misunderstanding this here – still puzzled by the “most recent update” requirement :)

Esko

From: Ted Lemon <mellon@fugue.com>
Sent: Friday, September 15, 2023 16:41
To: Jonathan Hui <jonhui=40google.com@dmarc.ietf.org>
Cc: Esko Dijk <esko.dijk@iotconsultancy.nl>; dnssd@ietf.org
Subject: Re: [dnssd] SRP: how to remove all published services?

Oh, except the text you quoted says precisely that, so I think we're okay. Thanks, Jonathan. :)

On Fri, Sep 15, 2023 at 10:40 AM Ted Lemon <mellon@fugue.com<mailto:mellon@fugue.com>> wrote:
Was the question more "what if the requestor sends a partial remove (host plus not all services) with lease time zero?" I think the answer is that it removes all the services, because the other services are pointing to the host, and the host has to be removed; this means that any remaining services pointing to that host are simply invalid. We could certainly add a note clarifying this point, although it's a bit late in the process for that.

On Fri, Sep 15, 2023 at 10:31 AM Jonathan Hui <jonhui=40google.com@dmarc.ietf.org<mailto:40google.com@dmarc.ietf.org>> wrote:
Hi Esko,

I believe this is addressed by the immediately following paragraphs in the same section? Specifically:

   To support this, when removing services based on the lease time being
   zero, an SRP registrar MUST remove all service instances pointing to
   a host when a host is removed, even if the SRP requestor doesn't list
   them explicitly.  If the key lease time is nonzero, the SRP registrar
   MUST NOT delete the KEY records for these SRP requestors.

So there is no need to list all the services that were previously registered.

--
Jonathan Hui



On Fri, Sep 15, 2023 at 7:17 AM Esko Dijk <esko.dijk@iotconsultancy.nl<mailto:esko.dijk@iotconsultancy.nl>> wrote:
A question - in 3.2.5.5.1., Removing all published services, we have:

   To remove all the services registered to a particular host, the SRP requestor retransmits its most recent update with an Update Lease option that has a LEASE value of zero.

I wonder how this exactly works in the following case. If I’ve registered service A, and 10 minutes later registered service B in addition (without mentioning A in the second SRP Update), then both services A and B are actively registered.  Now I send the “most recent SRP Update” which has only service B to the SRP registrar, with a LEASE value of zero.
Wouldn’t it be that only service B is removed (lease set to 0) while service A stays active?

If so, we may need to clarify this text I think. Because it’s not always the “most recent SRP Update” then.
(If not so, I’m having trouble understanding how the LEASE value in the SRP Update does apply to all currently registered services….)

Esko
_______________________________________________
dnssd mailing list
dnssd@ietf.org<mailto:dnssd@ietf.org>
https://www.ietf.org/mailman/listinfo/dnssd
_______________________________________________
dnssd mailing list
dnssd@ietf.org<mailto:dnssd@ietf.org>
https://www.ietf.org/mailman/listinfo/dnssd