/
githubmirror
/
audit-userspace
Обзор
Документация
Войти
/
githubmirror
/
audit-userspace
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
docs/audit_encode_value.3
57 строк
1 KB
Steve Grubb
Clarify audit value encoding documentation
14 май 2026, 06:15
14 май 2026, 06:15
0d2bca5
Код
Авторство
О чём код?
.TH "AUDIT_ENCODE_VALUE" "3" "May 2026" "Red Hat" "Linux Audit API" .SH NAME audit_encode_value \- encode bytes as an ASCII hexadecimal string .SH "SYNOPSIS" .nf .B #include <libaudit.h> .PP .BI "char *audit_encode_value(char *" final ", const char *" buf ", unsigned int " size "); .fi .SH "DESCRIPTION" .BR audit_encode_value () encodes .I size bytes from .I buf as an uppercase ASCII hexadecimal string. Each input byte is written as two hexadecimal digits. The input does not have to be NUL-terminated and may contain embedded NUL bytes. .PP .I final is the caller-provided output buffer. It must be at least .I 2 * size + 1 bytes long to hold the encoded value and its terminating NUL byte. .I size is the number of bytes to encode from .IR buf , not necessarily the result of .BR strlen (3). .PP If .I buf is NULL, .BR audit_encode_value () writes an empty string to .IR final . e.g.: "foo bar" is encoded as "666F6F20626172". "\\1\\2\\3\\4" is encoded as "01020304". .SH "RETURN VALUE" Returns .I final on success. If .I final is NULL, NULL is returned. .SH "SEE ALSO" .BR audit_encode_nv_string (3), .BR audit_value_needs_encoding (3). .SH AUTHOR Steve Grubb