Page MenuHomeVyOS Platform

Error when using some constraints
Closed, ResolvedPublicBUG

Description

One example found that leads to inconsistent configuration is constraint alpha-numeric-hyphen-underscore-dot.xml.i, which is used in several parts:

interface-definitions/include/accel-ppp/client-ip-pool.xml.i:      #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/include/accel-ppp/client-ip-pool.xml.i:          #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/include/accel-ppp/client-ipv6-pool.xml.i:      #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/include/accel-ppp/default-ipv6-pool.xml.i:      #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/include/accel-ppp/default-pool.xml.i:      #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/include/bgp/afi-route-map-export-import.xml.i:      #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/include/bgp/afi-route-map-export-import.xml.i:      #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/include/bgp/neighbor-afi-ipv4-ipv6-common.xml.i:          #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/include/bgp/neighbor-afi-ipv4-ipv6-common.xml.i:          #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/include/bgp/neighbor-afi-ipv4-ipv6-common.xml.i:          #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/include/bgp/neighbor-afi-ipv4-ipv6-common.xml.i:      #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i:<!-- include start from constraint/alpha-numeric-hyphen-underscore-dot.xml.i -->
interface-definitions/include/dhcp/option-v6.xml.i:          #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/include/dhcp/option-v6.xml.i:          #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/include/route-map.xml.i:      #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/pki.xml.in:            #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/pki.xml.in:            #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/pki.xml.in:            #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/policy.xml.in:            #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/service_dhcp-server.xml.in:                    #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/service_dhcp-server.xml.in:                #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/service_dhcp-server.xml.in:                        #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/service_dhcpv6-server.xml.in:                #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>
interface-definitions/service_dhcpv6-server.xml.in:                        #include <include/constraint/alpha-numeric-hyphen-underscore-dot.xml.i>

This contraint allow an input starting with dot character. And that's when we get undesired behavior. For example:

vyos@vyos# set pki ca .DOT description TEST
[edit]
vyos@vyos# set policy route-map .SecondDOT description ANOTHER-ONE
[edit]
vyos@vyos# commit
[edit]
vyos@vyos# run show config comm | grep "pki\|policy"
set pki
set policy
[edit]
vyos@vyos#

Details

Difficulty level
Unknown (require assessment)
Version
vyos-1.4.0-epa2, 1.5-rolling-202404090019
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Unspecified (possibly destroys the router)
Issue type
Bug (incorrect behavior)

Event Timeline

n.fort renamed this task from Error when using some contraints to Error when using some constraints.Tue, Apr 9, 9:44 AM
n.fort changed the task status from Open to In progress.
n.fort claimed this task.
n.fort triaged this task as High priority.
n.fort created this task.
n.fort moved this task from Need Triage to Finished on the VyOS 1.5 Circinus board.