[netconf] subtree filter any namespace

Christian Hopps <chopps@chopps.org> Mon, 10 February 2020 20:36 UTC

Return-Path: <chopps@chopps.org>
X-Original-To: netconf@ietfa.amsl.com
Delivered-To: netconf@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 26E70120847 for <netconf@ietfa.amsl.com>; Mon, 10 Feb 2020 12:36:12 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.898
X-Spam-Level:
X-Spam-Status: No, score=-1.898 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_NONE=0.001] autolearn=ham autolearn_force=no
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id uPjJq1LyPS08 for <netconf@ietfa.amsl.com>; Mon, 10 Feb 2020 12:36:10 -0800 (PST)
Received: from smtp.chopps.org (smtp.chopps.org [54.88.81.56]) by ietfa.amsl.com (Postfix) with ESMTP id B2438120018 for <netconf@ietf.org>; Mon, 10 Feb 2020 12:36:10 -0800 (PST)
Received: from [192.168.1.206] (66-227-211-29.dhcp.trcy.mi.charter.com [66.227.211.29]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by smtp.chopps.org (Postfix) with ESMTPSA id 337A560B8A; Mon, 10 Feb 2020 20:36:10 +0000 (UTC)
From: Christian Hopps <chopps@chopps.org>
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
Mime-Version: 1.0 (Mac OS X Mail 13.0 \(3608.40.2.2.4\))
Message-Id: <6131477C-9EE3-499E-966A-A9ADB6FF8CD9@chopps.org>
Date: Mon, 10 Feb 2020 15:36:09 -0500
To: netconf@ietf.org
X-Mailer: Apple Mail (2.3608.40.2.2.4)
Archived-At: <https://mailarchive.ietf.org/arch/msg/netconf/a_Umc-WULhKutjb5q29r56mChrM>
Subject: [netconf] subtree filter any namespace
X-BeenThere: netconf@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: NETCONF WG list <netconf.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/netconf>, <mailto:netconf-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/netconf/>
List-Post: <mailto:netconf@ietf.org>
List-Help: <mailto:netconf-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/netconf>, <mailto:netconf-request@ietf.org?subject=subscribe>
X-List-Received-Date: Mon, 10 Feb 2020 20:36:12 -0000

I've been adding subtree to xpath conversion to my netconf python client/server code (with some help from others), and in trying to get the "any" namespace stuff working I ran into an issue.

The client code was setting the default namespace to 'xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"' on the top XML rpc message element. This had an unwanted side-effect of placing everything in a sub-tree filter then into the netconf namespace (if none were given). As a work-around I created the filter element with a blank default namespace; however, I'm not sure this is correct, i.e.,

<get>
 <filter xmlns=''>
 ... users specified filter ...
 </filter>
</get>

The correct thing is probably to not set the default namespace in the client code; however, I'm not sure I can do this now for backward compatible reasons. I could do it perhaps if the user specified a filter, but I'm curious if it's valid to just set it to blank. Googling produced conflicting answers for me.

Thanks,
Chris.