listxattr

Lists a file’s extended attribute names.

Syntax

 ssize_t listxattr (
    const char  *path,
    char        *list,
    size_t       size
 );
 

Parameters

path
Points to the name of the file to read extended attributes from.
list
Points to the list of extended attributes.
size
Specifies the length of the attribute list.

Remarks

Extended attributes are name value pairs that are associated with files, directories, symbolic links, etc. They are extensions to the normal attributes that are associated with all files in the system.

listxattr retrieves a list of NULL-terminated extended attribute names that are associated with the given path in the filesystem.

listxattr also returns netware.metadata for every file. Utilities can call listxattr to retrieve the metadata necessary for backing up files. However, this is an optional feature which is turned off by default. To turn on this feature, use nss/ListXattrNWmetadata in nsscon or make it persistent by putting in nssstart.conf.