Commit graph

13 commits

Author SHA1 Message Date
Olof hagsand
c038c9a27f * Implementation of "chunked framing" according to RFC6242 for Netconf 1.1.
* First hello is 1.0 EOM framing, then successing rpc is chunked framing
  * See
    * [Netconf framing](https://github.com/clicon/clixon/issues/50), and
    * [Clixon does not switch to chunked framing after NETCONF 1.1 is negotiated](https://github.com/clicon/clixon/issues/314)
* C:
  * Moved netconf framing code from netconf application to clixon lib
* Test:
  * New expecteof_netconf and adjusted other expect scripts to handle NETCONF 1.1 framing
2022-03-28 12:36:44 +02:00
Olof hagsand
dd2ac56af8 Module state upgrade: RFC7895 to RFC 8525
Changes to clixon-config:
  * Added option: 'CLICON_YANG_LIBRARY`
  * Changed default value: `CLICON_MODULE_LIBRARY_RFC7895` to false
Datastore modstate is backward compatible
Tests upgraded to RFC8525
2022-03-07 10:56:54 +01:00
Olof hagsand
4102ca8a46 * configure --with-wwwdir=<dir> is removed
* test:
  * new test_helloworld.sh smoketest added for testing basic functions
  * stripped restconf fcgi default config
  * added yang variable
2022-02-07 13:31:39 +01:00
Olof hagsand
dec05e2cae Test modifications
- Remove dependency of IETF YANGs on most tests
- Remove dependnency of example/main in most tests, instead make local copy of example yang
2022-01-03 09:57:17 +01:00
Olof hagsand
bc1f80b28e Added support for the XPATH function bit-is-set() 2021-11-27 15:40:44 +01:00
Olof hagsand
babdc6f496 * Fixed: [OpenConfig BGP afi-safi and when condition issues #249](https://github.com/clicon/clixon/issues/249)
* YANG when was not properly implemented for default values
* Improved error message on leafref validation errors
2021-08-02 15:48:38 +02:00
Olof hagsand
9edf380f6a - Link utils statically if LINKAGE=static
- Fix event exit bug (set to new counter, dont increment)
- Changed default CI to be restconf=native instead of fcgi1~
- Tests:
  - Change to same wait backend and restconf commands
  - Change default restconf protocol from http to https
2021-06-18 22:50:30 +02:00
Olof hagsand
376f2a8143 * Fixed problems with XPATH composite operations and functions in netconf get/get-config operations.
* See [XPATH issues #219](https://github.com/clicon/clixon/issues/219)
2021-05-17 10:07:09 +02:00
Olof hagsand
783b0a4857 * YANG when statement in conjunction with grouping/uses/augment
* Several cases were not implemented fully according to RFC 7950
    * Do not extend default values if when statements evaluate to false
    * Do not allow edit-config of nodes if when statements evaluate to false (Sec 8.3.2)
    * If a key leaf is defined in a grouping that is used in a list, the "uses" statement MUST NOT have a "when" statement. (See 7.21.5)
  * See [yang uses's substatement when has no effect #218](https://github.com/clicon/clixon/issues/2$
2021-05-13 14:26:02 +02:00
Olof hagsand
5692072d36 * Fixed: [CLIXON is not waiting for the hello message #184](https://github.com/clicon/clixon/issues/184)
* Hello message semantics has been made stricter according to RFC 6241 Sec 8.1, for example:
  * A client MUST send a <hello> element.
  * Each peer MUST send at least the base NETCONF capability, "urn:ietf:params:netconf:base:1.1" (or 1.0 for RFC 4741)
  * The netconf client will terminate (close the socket) if the client does not comply
  * You can set `CLICON_NETCONF_HELLO_OPTIONAL` to true to use the old behavior of essentially ignoring hellos.
* New clixon-config@2020-03-08.yang revision
  * Added: `CLICON_NETCONF_HELLO_OPTIONAL`
* The base capability has been changed to "urn:ietf:params:netconf:base:1.1" following RFC6241.
2021-03-10 14:18:16 +01:00
Olof hagsand
b7991d9b39 * Made a separate Clixon datastore XML/JSON top-level symbol
* Replaces the hardcoded "config" keyword.
  * Implemented by a compile-time option called `DATASTORE_TOP_SYMBOL` option in clixon_custom.h
* Tests: added endtest to all tests. Removed all premature exits if BE=0
2021-03-05 14:15:15 +01:00
Olof hagsand
8ae647c32b * More explanatory validation error messages for when and augments error messages.
* Example: error-message: `Mandatory variable` -> `Mandatory variable of edit-config in module ietf-netconf`.
2020-10-07 20:57:49 +02:00
Olof hagsand
c616aa1569 Added support for XPATH functions:
* `contains`,
  * `derived-from` and `derived-from-or-self`
    * in particular in augment/when statements as shown in eg RFC 7950.
2020-09-22 22:40:42 +02:00