Skip to content

Commit 9ea3c2e

Browse files
committed
Add explicit NETCONF namespaces.
1 parent 08bdf57 commit 9ea3c2e

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

model-based-aaa/get-config-nacm.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -58,11 +58,11 @@
5858
device_params={'name':"csr"})
5959

6060
hostname_filter = '''
61-
<filter>
61+
<filter xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
6262
<nacm xmlns="urn:ietf:params:xml:ns:yang:ietf-netconf-acm"/>
6363
</filter>
6464
'''
6565

6666
# Pretty print the XML reply
6767
xmlDom = xml.dom.minidom.parseString( str( m.get_config('running', hostname_filter)))
68-
print(xmlDom.toprettyxml( indent = " " ))
68+
print(xmlDom.toprettyxml( indent = " " ))

netconf_entity/nc_entity.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@
5757

5858
with manager.connect_ssh(host=args.host, port=args.port, username=args.username, hostkey_verify=False, password=args.password) as m:
5959
entity_filter = '''
60-
<filter>
60+
<filter xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
6161
<ENTITY-MIB xmlns="urn:ietf:params:xml:ns:yang:smiv2:ENTITY-MIB"/>
6262
</filter>
6363
'''

0 commit comments

Comments
 (0)