rpm: /home/mdomonko/code/rpm/rpm-4.20.x/include/rpm/rpmbase64.h File Reference

rpm 4.20.0 The RPM Package Manager

Loading...
Searching...
No Matches
Functions
rpmbase64.h File Reference
I/O » RPM IO API.
`#include <sys/types.h>`
Include dependency graph for rpmbase64.h:

Go to the source code of this file.

## Functions
char * | rpmBase64Encode (const void *data, size_t len, int linelen)
int | rpmBase64Decode (const char *in, void **out, size_t *outlen)
char * | rpmBase64CRC (const unsigned char *data, size_t len)

## Detailed Description

Base64 encoding and decoding API

## Function Documentation

## ◆ rpmBase64CRC()

char * rpmBase64CRC | ( | const unsigned char * | data,
|  | size_t | len )

counts CRC24 and base64 encodes it in a malloced string returns NULL on failures

## ◆ rpmBase64Decode()

int rpmBase64Decode | ( | const char * | in,
|  | void ** | out,
|  | size_t * | outlen )

decodes from zero terminated base64 encoded string to a newly malloced buffer ignores whitespace characters in the input string return values: 0 - OK 1 - input is NULL 2 - invalid length 3 - invalid characters on input 4 - malloc failed

## ◆ rpmBase64Encode()

char * rpmBase64Encode | ( | const void * | data,
|  | size_t | len,
|  | int | linelen )

returns malloced base64 encoded string lines are split with
characters to be nearest lower multiple of linelen if linelen/4 == 0 lines are not split if linelen < 0 default line length (64) is used the returned string is empty when len == 0 returns NULL on failures