The FreeRADIUS server  $Id: 15bac2a4c627c01d1aa2047687b3418955ac7f00 $
Functions
common.h File Reference

Common code used by multiple SIM algorithms. More...

+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

static uint64_t uint48_from_buff (uint8_t const in[6])
 Convert a 48bit big endian value into a unsigned 64bit integer. More...
 
static uint8_tuint48_to_buff (uint8_t out[static 6], uint64_t i)
 Copy a 48bit value from a 64bit integer into a uint8_t buff in big endian byte order. More...
 

Detailed Description

Common code used by multiple SIM algorithms.

Id
ea94dada9a1ce28ff5486c6f1f11a5a7fa7fb241

Definition in file common.h.

Function Documentation

◆ uint48_from_buff()

static uint64_t uint48_from_buff ( uint8_t const  in[6])
inlinestatic

Convert a 48bit big endian value into a unsigned 64bit integer.

Definition at line 52 of file common.h.

+ Here is the caller graph for this function:

◆ uint48_to_buff()

static uint8_t* uint48_to_buff ( uint8_t  out[static 6],
uint64_t  i 
)
inlinestatic

Copy a 48bit value from a 64bit integer into a uint8_t buff in big endian byte order.

There may be fast ways of doing this, but this is the correct way, and does not make assumptions about how integers are laid out in memory.

Parameters
[out]out6 byte butter to store value.
[in]iinteger value.
Returns
pointer to out.

Definition at line 37 of file common.h.

+ Here is the caller graph for this function: