---
name: "krb5_padata_add"
section: "3"
platform: "linux"
package: "heimdal-dev"
version: "7.8.git20221117.28daf24+dfsg-9+deb13u1"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/krb5_padata_add"
---

# krb5\_padata\_add(3)

Kerberos 5 pre-authentication data handling functions

## NAME

**krb5\_find\_padata**, **krb5\_padata\_add** – Kerberos 5 pre-authentication data handling functions

## LIBRARY

Kerberos 5 Library (libkrb5, -lkrb5)

## SYNOPSIS

**#include \<krb5.h\>**

*PA\_DATA \**\

**krb5\_find\_padata**(*PA\_DATA \*val*, *unsigned len*, *int type*, *int \*index*);

*int*\

**krb5\_padata\_add**(*krb5\_context context*, *METHOD\_DATA \*md*, *int type*, *void \*buf*, *size\_t len*);

## DESCRIPTION

**krb5\_find\_padata**() tries to find the pre-authentication data entry of type *type* in the array *val* of length *len*. The search is started at entry pointed out by *\*index* (zero based indexing). If the type isn't found, NULL is returned.

**krb5\_padata\_add**() adds a pre-authentication data entry of type *type* pointed out by *buf* and *len* to *md*.

## SEE ALSO

[krb5(3)](/krb5/3.md), [kerberos(8)](/kerberos/8.md)
