summaryrefslogtreecommitdiffstats
path: root/lib/yang_wrappers.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* isisd: fix #10505 using base64 encodingwhichbug2022-02-221-0/+59
| | | | | | | Using base64 instead of the raw string to encode the binary data. Signed-off-by: whichbug <whichbug@github.com>
* lib: adapt to version 2 of libyangChristian Hopps2021-05-131-368/+178
| | | | | | | | | Compile with v2.0.0 tag of `libyang2` branch of: https://github.com/CESNET/libyang staticd init load time of 10k routes now 6s vs ly1 time of 150s Signed-off-by: Christian Hopps <chopps@labn.net>
* lib: add flowspec safi to identitiy ref parsingChirag Shah2020-10-271-0/+10
| | | | Signed-off-by: Chirag Shah <chirag@nvidia.com>
* lib: yang wrapper for getting empty typeChirag Shah2020-08-121-0/+23
| | | | Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
* lib: yang afi-safi identityref translationChirag Shah2020-08-051-0/+25
| | | | | | | Add more afi safis in conversion to-from string to indentityref. Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
* zebra: Moving afi-safi identity to libvdhingra2020-07-161-0/+35
| | | | | | afi-safi identity handling should be in the common place. Signed-off-by: VishalDhingra <vdhingra@vmware.com>
* lib: yang wrapper for date-and-timeChirag Shah2020-04-221-0/+27
| | | | Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
* lib: fix style nit in yang_wrappers.cQuentin Young2020-04-161-1/+1
| | | | Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
* lib: yang wrapper nexthop type to strChirag Shah2020-04-161-0/+28
| | | | Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
* lib: add yang wrapper for type emptyChirag Shah2020-04-161-0/+8
| | | | Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
* lib:api to convert mac to yang objectChirag Shah2020-04-161-0/+14
| | | | Signed-off-by: Chirag Shah <chirag@cumulusnetworks.com>
* *: fix format string warningsDavid Lamparter2020-03-291-2/+3
| | | | Signed-off-by: David Lamparter <equinox@diac24.net>
* lib: use `prefix` for yang get prefix wrapperRafael Zalamena2019-10-121-2/+8
| | | | | | | | | | | | This change fixes a static analyzer warning and should also make us safer when using this function. At the moment the code that triggered the warning is the only one that uses this function. Passing anything other than `struct prefix` to `str2prefix` function is dangerous, because the structure might be smaller than expected and we might have an buffer overflow. Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
* lib: add yang wrappers for IP prefixesRenato Westphal2019-09-181-0/+54
| | | | | | | We had wrappers for IPv4 and IPv6 prefixes, but not for IP (version agnostic) prefixes. This commit addresses this issue. Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
* yang: add user type for ip-addressQuentin Young2019-09-121-0/+53
| | | | | | Convert ietf-inet-types:ip-address to struct ipaddr. Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
* lib, yang: disable libyang custom user types temporarilyRenato Westphal2019-05-071-4/+4
| | | | | | | | | | | | | | | | | | libyang 1.0 introduced a few changes in the user types API, and these changes made FRR incompatible with libyang 1.x. In order to ease our migration from libyang 0.x to libyang 1.x, let's disable our libyang custom user types temporarily so that FRR can work with both libyang 0.x and libyang 1.x. This should be especially helpful to the CI systems during the transition. Once the migration to libyang 1.x is complete, this commit will be reverted. Disabling our libyang custom user types should have only minimal performance implications when processing configuration transactions. The user types infrastructure should be more important in the future to perform canonization of YANG data values when necessary. Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
* *: use proper bool initializers & fix comparisonsQuentin Young2019-02-261-1/+1
| | | | | | | - bools should be initialized with true/false - bools do not need to be compared Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
* lib: fix issue with yang_str2enumEmanuele Di Pascale2018-12-181-1/+7
| | | | | | | | The same issue with derived enum types that was already fixed for yang_data_new_enum was still present here, so I simply applied the same fix. Signed-off-by: Emanuele Di Pascale <emanuele@voltanet.io>
* lib: use prefixconstptr instead of const prefixptrRenato Westphal2018-11-261-2/+2
| | | | Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
* lib: fix fetching enum values for derived typesEmanuele Di Pascale2018-10-271-1/+7
| | | | Signed-off-by: Emanuele Di Pascale <emanuele@voltanet.io>
* lib: introduce new northbound APIRenato Westphal2018-10-271-0/+990
Signed-off-by: Renato Westphal <renato@opensourcerouting.org>