* Added Clixon Restconf library

* Builds and installs a new restconf library: libclixon_restconf.so and clixon_restconf.h
  * The restconf library can be included by a restconf plugin.
  * Example code in example/Makefile.in and example/restconf_lib.c
* Authorization
  * Example extended with authorization
  * Test added with http basic authorization (test/test_auth.sh)
  * Documentation in FAQ.md
* README.md extended with new yang, netconf, restconf, datastore, and auth sections.
This commit is contained in:
Olof hagsand 2018-03-25 15:47:27 +02:00
parent cce76faa79
commit bfce20c760
17 changed files with 773 additions and 157 deletions

View file

@ -327,6 +327,7 @@ test(FCGX_Request *r,
printparam(r, "HTTPS", dbg);
printparam(r, "HTTP_ACCEPT", dbg);
printparam(r, "HTTP_CONTENT_TYPE", dbg);
printparam(r, "HTTP_AUTHORIZATION", dbg);
#if 0 /* For debug */
clicon_debug(1, "All environment vars:");
{
@ -375,6 +376,7 @@ restconf_plugin_load(clicon_handle h)
plghndl_t *handle;
char filename[MAXPATHLEN];
clicon_debug(1, "%s", __FUNCTION__);
if ((dir = clicon_restconf_dir(h)) == NULL){
retval = 0;
goto quit;
@ -382,7 +384,6 @@ restconf_plugin_load(clicon_handle h)
/* Get plugin objects names from plugin directory */
if((ndp = clicon_file_dirent(dir, &dp, "(.so)$", S_IFREG))<0)
goto quit;
/* Load all plugins */
for (i = 0; i < ndp; i++) {
snprintf(filename, MAXPATHLEN-1, "%s/%s", dir, dp[i].d_name);