Olof hagsand
bf00fdf2c1
* Fixed: [restconf GET json response does not encode top level node with namespace as per rfc #303 ]( https://github.com/clicon/clixon/issues/303 )
2022-02-17 18:42:37 +01:00
Olof hagsand
12695c5d87
* Unit test ifdef for restconf http1 parser
...
* test: fix cli-union test
2022-02-17 09:16:01 +01:00
Olof hagsand
61661e6940
Restconf and http/1 modifications for http/1-only
2022-02-15 15:48:37 +01:00
Olof hagsand
c006c6189d
- Fixed restconf http/1 only compile errors
2022-02-15 09:31:32 +01:00
Olof hagsand
82e0d907b3
restconf typo, left minimal debug recv buffer in place
2022-02-15 08:52:57 +01:00
Olof hagsand
12dddfd794
* RESTCONF,
...
* Refactored http1 code
* fixed some http1/http2 only compile issues
2022-02-14 21:03:23 +01:00
Olof hagsand
10886a31a2
* Fixed inefficient RESTCONF HTTP/1 read body by appending bufs instead of re-parsing
...
* Fixed: http1 by mistake included in fcgi build
* Test: restconf perf test uses restconf for initial setup instead of netconf
2022-02-12 21:54:22 +01:00
Olof hagsand
6ae749c9dd
* New clixon-config@2022-02-11.yang revision
...
* Added option: `CLICON_LOG_STRING_LIMIT`
2022-02-12 21:45:50 +01:00
Olof hagsand
abaf122bfc
RESTCONF HTTP/1 Incomplete header handling
2022-02-09 12:39:28 +01:00
Olof hagsand
51fd973642
Fuzzing of native http1 parser
2022-02-08 21:26:53 +01:00
Olof hagsand
4aa74fa1d8
* Restconf native http/1, first working version
...
* Renamed files clixon_http -> restconf_http
* Split main file into restconf_native.c
* Remove all evhtp code and libevhtp/libevent dependency
2022-02-08 18:59:47 +01:00
Olof hagsand
dadf4a778a
* HTTP/1 native parser as part of the RESTCONF client
...
* Fixed memory error in opendir/readdir in clicon_file_dirent
* Remove MAXPATH in parsers
* New string-del function
2022-02-08 16:59:08 +01:00
Olof hagsand
77b4468eb3
Updated copyright statements to 2022
2022-01-18 16:36:00 +01:00
Olof hagsand
b164f02277
* Removed ifdef __GNUC__ around printf-like prototypes since both clang and gcc have format/printf macros defined
2022-01-18 16:05:50 +01:00
Olof hagsand
50ac510803
* Fixed: Configure option CLICON_RESTCONF_PATH was marked as obsolete but was still used.
...
* `CLICON_RESTCONF_PATH` is now obsolete for sure
* Instead if you use fgci/nginx:
* Use `restconf/fcgi-socket`
* Ensure `<CLICON_FEATURE>clixon-restconf:fcgi</CLICON_FEATURE>` is set
* Added default values to restconf-config and save fcgi-socket-path in memory
2022-01-01 11:52:18 +01:00
Olof hagsand
1808015cf6
Fixed: SEGV when starting FCGI restconf program
...
- Reverted removal of CLICON_RESTCONF_PATH since it was used there
Misc fixes: initialized variables, docs, removed obsolete --enable-optyang
2021-12-30 16:35:54 +01:00
Olof hagsand
3117332ddd
Changes in clixon-config.yang:
...
* Removed obsolete options:
* `CLICON_YANG_LIST_CHECK`
* `CLICON_RESTCONF_PATH` (moved to restconf/fcgi-path)
* Fixed: Configure option `CLICON_RESTCONF_PRETTY` was marked as obsolete but was still used.
* `CLICON_RESTCONF_PRETTY` is now obsolete for sure
* Instead restconf/pretty is used with API function restconf_pretty_get()
2021-12-28 11:44:19 +01:00
Olof hagsand
f8f34e3571
* Replaced separate autocli trees with a single @basemodel tree by using filter labels
...
* Added lastkey argument to yang_key_match()
* Fixed segv in process-sigchld
* Added ietf-yang-library to CLICON_CLI_AUTOCLI_EXCLUDE default value
* Added yang_spec_print() function
2021-12-16 20:23:09 +01:00
Olof hagsand
b91ce762d5
* Performance improvement
...
* Added ancestor config cache indicating wether the node or an ancestor is config false or true
* Improved yang cardinality lookup
* Added yang_init(), called from all apps using yang
2021-11-18 08:37:54 +01:00
Olof hagsand
0626de9431
* RPC replies now verified with YANG
...
* Stricter checking of outgoing RPC replies from server
* See [RPC output not verified by yang](https://github.com/clicon/clixon/issues/283 )
* This lead to some corrections of RPC replies in system code
2021-11-16 22:12:14 +01:00
Olof hagsand
2dcc14a0db
Added error handling in yang_path_arg triggered by no filter in get paginated
...
Fixed cornercase of restconf error return when no body
Fixed cornercase when exactly / given as xpath
Better error message when YANG not found: added which YANG file imports it
2021-11-10 18:35:24 +01:00
Olof hagsand
a4b4dc97ce
Pagination updated
...
* Pagination is updated to new drafts:
* [https://datatracker.ietf.org/doc/html/draft-wwlh-netconf-list-pagination-00 >]
* [https://datatracker.ietf.org/doc/html/draft-wwlh-netconf-list-pagination-nc-02 ]
* [https://datatracker.ietf.org/doc/html/draft-wwlh-netconf-list-pagination-rc-02 ]
* See also updated [https://clixon-docs.readthedocs.io/en/latest/pagination.html ]
* Added IETF RFC:s (included by pagination):
* ietf-netconf-nmda@2019-01-07.yang
* ietf-origin@2018-02-14.yang
* ietf-netconf-with-defaults@2011-06-01.yang
* Dropped pcvec parameter to many restconf api functions
2021-11-10 18:35:24 +01:00
Olof hagsand
448aa4c994
include signal.h
2021-10-21 16:29:43 +02:00
Olof hagsand
26d37352f4
NETCONF hello error handling, changed YANG PATCH enabling, refactored static linking
...
NETCONF hello errors, such as wrong session-id, prefix, namespace terminates session
* Instead of returning an rpc-error reply
Changed YANG PATCH enabling:
* Now: `./configure --enable-yang-patch`
* Before: set YANG_PATCH constant in `include/clixon_custom.h`
Refactored Makefile for static linking
2021-10-05 12:04:53 +02:00
Olof hagsand
d175720b7e
Cleaned up Makefiles, especially LINKAGE=static vs dynamic
...
Added LIBSTATIC_SUFFIX instead of hardcoded .a
Changed building of build.c not to be triggered by install
2021-09-30 21:40:46 +02:00
Olof hagsand
51278d5901
Fixed static linking for coverage and fuzzing
...
Preparations for Clixon 5.3 release
2021-09-27 12:26:53 +02:00
Olof hagsand
5a875e3152
Fix some LINKAGE=static compile issues:
...
- Makefile circularity by fixing .so suffix
- simplify example/main Makefile
2021-09-26 11:22:48 +02:00
Olof hagsand
b70e22096e
- Pagination: enabled LIST_PAGINATION and remobved constant
...
- Changed logic on how to find clixon_restconf in pseudo plugin
- Removed ==== in constants to avoid conflict with git merge
- Remove assert
- Added fuzzing for netconf
2021-09-23 13:33:26 +02:00
Olof hagsand
47141089c2
- Added netconf to fuzz
...
- Restconf internal start more robust
- Restconf fcgi fix
2021-09-22 18:55:32 +02:00
Olof hagsand
55377786c1
Fix tests for http/1 and http/2 only respectively
2021-09-21 21:23:33 +02:00
Olof hagsand
a046306270
- New netconf-specific uint32 parse functions
...
- Added failure handling to xpath traverse_canonical
- Started pagination cli code
2021-09-21 11:24:53 +02:00
Olof hagsand
390b0886ed
- pageing offset working
2021-09-21 11:24:53 +02:00
Olof hagsand
fb0b9409f3
- Moved restrconf code from pageing rpc to get
2021-09-21 11:24:53 +02:00
Olof hagsand
76e59873c2
- Changed media name: yang.collection+xml/yang to application-collection+xml/json
...
- Modified ietf-netconf-list-pagination.yang:
- changed get-pagable -> get-pageable
- renamed count -> limit
- renamed skip -> offset
- added import ietf-yang-metadata
- added md:annotation remaining
2021-09-21 11:22:41 +02:00
Olof hagsand
0c7f2043f3
* Pagination according to new draft
...
* count/skip -> limit/offset
* ietf-yang-metadata RFC 7952 support, placeholder parsing and extension
2021-09-21 11:22:41 +02:00
Olof hagsand
77bacc93bb
- Updated code to clixon 5.2 status
...
- Added LIST_PAGINATION clixon_custom constant
- Fix: leafs added as augments on rpc input/output lacked cv:s
2021-09-21 11:22:40 +02:00
Olof hagsand
2485bec483
fixes for compilation
2021-09-21 11:22:40 +02:00
Olof hagsand
2b5dceb82c
cli pagination
2021-09-21 11:22:40 +02:00
Olof hagsand
acc6a0fec7
First working prototype
2021-09-21 11:22:40 +02:00
Olof hagsand
2e857bb417
First working prototype
2021-09-21 11:22:40 +02:00
Olof hagsand
392e6679c5
* JSON errors are now labelled with JSON and not XML
...
* Fixed: [Performance issue when parsing large JSON param](https://github.com/clicon/clixon/issues/266 )
* Moved strlen() from for end condition
* Fixed debugging of xpath parser
2021-09-20 21:35:01 +02:00
Olof hagsand
d1ed4ecd7d
- Refactor yang patch code according to Clixon coding style
...
- Fixed all memory leaks
2021-09-08 10:38:49 +02:00
Olof hagsand
aed7dbfd8b
- Restconf error: added special case for translating from netconf invalid-value to 400 vs 404
...
- Added media to restconf sanity checks, such as bad client cert error
2021-08-27 15:12:50 +02:00
Olof hagsand
cdacca125c
Native restconf: SSL client certs failures are returned as http 405 errors, not fail during SSL negotiation
2021-08-27 09:33:59 +02:00
Olof hagsand
ef4d082f4b
* Restconf native HTTP/2:
...
* Added option `CLICON_RESTCONF_HTTP2_PLAIN`
* if disabled non-tls HTTP/2 is disabled: both direct and upgrade
2021-08-26 16:58:52 +02:00
Olof hagsand
6e0e45aab7
* Fixed: Some native restconf error messages did not end with \r\n.
...
* Specifically the error when sending http request on https.
2021-08-20 15:45:13 +02:00
Olof hagsand
8db716ca07
- Moved yang patch code to new files restconf_methods_patch.[ch]
...
- Started modifying patch code to style guidelines
- Made patch test independent of example
- Added developers style guidelines
2021-08-15 20:43:52 +02:00
Olof hagsand
bd8cbbc393
Merge branch 'alanyanigersiklu-yang-patch-alanfork'
2021-08-10 19:50:27 +02:00
Alan Yaniger
f2e81be66e
fix merge conflicts
2021-08-06 12:08:13 +03:00
Alan Yaniger
94b8f7fec5
fixed another rebase error
2021-08-05 15:39:27 +03:00