* Experimental NACM RFC8341 Network Configuration Access Control Model.
* CLICON_NACM_MODE config option, default is disabled. * Added username attribute to all rpc:s from frontend to backend * Added NACM backend module in example
This commit is contained in:
parent
04a3f4db1b
commit
7650803475
32 changed files with 908 additions and 274 deletions
|
|
@ -120,7 +120,8 @@ expand_dbvar(void *h,
|
|||
yang_stmt *ypath;
|
||||
cxobj *xcur;
|
||||
char *xpathcur;
|
||||
|
||||
char *reason = NULL;
|
||||
|
||||
if (argv == NULL || cvec_len(argv) != 2){
|
||||
clicon_err(OE_PLUGIN, 0, "%s: requires arguments: <db> <xmlkeyfmt>",
|
||||
__FUNCTION__);
|
||||
|
|
@ -190,8 +191,12 @@ expand_dbvar(void *h,
|
|||
goto done;
|
||||
}
|
||||
xpathcur = ypath->ys_argument;
|
||||
if (xml_merge(xt, xtop, yspec) < 0) /* Merge xtop into xt */
|
||||
if (xml_merge(xt, xtop, yspec, &reason) < 0) /* Merge xtop into xt */
|
||||
goto done;
|
||||
if (reason){
|
||||
cli_output(stderr, "%s\n", reason);
|
||||
goto done;
|
||||
}
|
||||
if ((xcur = xpath_first(xt, xpath)) == NULL){
|
||||
clicon_err(OE_DB, 0, "xpath %s should return merged content", xpath);
|
||||
goto done;
|
||||
|
|
@ -241,6 +246,8 @@ expand_dbvar(void *h,
|
|||
ok:
|
||||
retval = 0;
|
||||
done:
|
||||
if (reason)
|
||||
free(reason);
|
||||
if (api_path)
|
||||
free(api_path);
|
||||
if (xvec)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue