Bug #4045

Updated by pespin 5 months ago

See issue described in

For example, the following command definition:
auth-policy (accept-all|closed|acl-only|remote) (accept-all|closed|acl-only|remote)"

actually permits the following variations:
auth-policy accept-all
auth-policy accept
auth-policy acl
auth-policy re
auth-policy c

So it seems in those cases, the matched VTY command (the DEFUN function ) will be passed with the incomplete sting instead of the full accepted string (eg: "re" instead of "remote).

That must be avoided and once "re" is matched to be "remote", "remote" should be passed inside argv[] instead of "re". Otherwise complexity of VTY commands parsing grows incredibly and makes no sense to have that logic duplicated in every cmd.


Add picture from clipboard (Maximum size: 48.8 MB)