radcli_avp_add_uint64(3)

πŸ“¦ version 2.0.1, in arch rolling

πŸ’– radcli_avp_add_uint64(3) πŸ’–

okay bestie, welcome to the radcli manual, section 3, and honestly? this little function is lowkey iconic. it appends attributes, it's giving "small but does the most" energy, and by the end of this page you're gonna be obsessed. let's go 🫢


✨ NAME ✨

radcli_avp_add_uint64 β€” append a 64-bit integer-typed attribute, or an ifid-typed one. both. it's versatile like that πŸ’…


🌸 SYNOPSIS 🌸

#include <radcli/>

int radcli_avp_add_uint64(
    radcli_avp_list        *list,
    const radcli_attr_def  *def,
    uint64_t                value
);

πŸ¦‹ DESCRIPTION πŸ¦‹

so the DESCRIPTION section itself is literally just vibes β€” there's no extra prose here, no filler, nothing. the entire personality of this function lives down in PARAMETERS and RETURN VALUE, so scroll a tiny bit and get the tea πŸ“


πŸ’œ PARAMETERS πŸ’œ

  • list β€” the destination list, aka where your little attribute is gonna live. it's the main character's home 🏠
  • def β€” the attribute itself, and here's the catch: it must be RADCLI_TYPE_INTEGER64 or RADCLI_TYPE_IFID. that's it, those are the only two accepted types, no cap.

and like, a little context on the ifid situation because it's genuinely fascinating: RADCLI_TYPE_IFID is RFC 8044 SS3.7's "ifid" data type β€” an opaque 8-octet value. but on the wire it's identical in shape to RADCLI_TYPE_INTEGER64, so instead of getting its own whole setter function, it just shares this one. efficiency! we love to see it ✨

  • value β€” the value, obviously πŸ’… and for RADCLI_TYPE_IFID specifically, this is the raw 8 octets read as a big-endian uint64_t. big-endian, bestie. remember it.

πŸ”₯ RETURN VALUE πŸ”₯

  • 0 on success β€” slay πŸŽ‰
  • -1 on failure β€” and that happens when def has neither of the accepted types, or for the same reasons as radcli_avp_add_bytes() would fail. yeah. that one. 😭

πŸ‘‘ SEE ALSO πŸ‘‘

the whole extended fam, every single one, no skips:


ok that's the whole page, you ate that ngl πŸ’… go forth and append those 64-bit integers (and ifids, big-endian, raw 8 octets, you know the drill) 🧚

mwah πŸ’‹ this page came from the radcli fam and is dated 2026-10-10 β€” catch you on the next one, bestie! 🌈⭐

πŸ“¦ where this page comes from