summaryrefslogtreecommitdiff
path: root/lib/base64.c
AgeCommit message (Collapse)Author
2024-02-19lib: fix base64 encodingIgor Ryzhov
Remove adding of line feeds when encondig. We're using these functions only for encoding binary data for storing in YANG data tree. According to RFC 7950, section 9.8.2: ``` 9.8.2. Lexical Representation Binary values are encoded with the base64 encoding scheme (see Section 4 in [RFC4648]). ``` According to mentioned RFC 4648, section 3.1: ``` Implementations MUST NOT add line feeds to base-encoded data unless the specification referring to this document explicitly directs base encoders to add line feeds after a specific number of characters. ``` Therefore, line feeds must not be added to the encoded data. Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
2023-10-12build: add -Wimplicit-fallthroughIgor Ryzhov
Also: - replace all /* fallthrough */ comments with portable fallthrough; pseudo keyword to accomodate both gcc and clang - add missing break; statements as required by older versions of gcc - cleanup some code to remove unnecessary fallthrough Signed-off-by: Igor Ryzhov <iryzhov@nfware.com>
2023-02-09*: manual SPDX License ID conversionsDavid Lamparter
The files converted in this commit either had some random misspelling or formatting weirdness that made them escape automated replacement, or have a particularly "weird" licensing setup (e.g. dual-licensed.) This also marks a bunch of "public domain" files as SPDX License "NONE". Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2022-04-04build: first header *must* be zebra.h or config.hDavid Lamparter
This has already been a requirement for Solaris, it is still a requirement for some of the autoconf feature checks to work correctly, and it will be a requirement for `-fms-extensions`. Signed-off-by: David Lamparter <equinox@opensourcerouting.org>
2022-02-22isisd: fix #10505 using base64 encodingwhichbug
Using base64 instead of the raw string to encode the binary data. Signed-off-by: whichbug <whichbug@github.com>