*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->IRIX man pages -> cap_from_text (3c)              



NAME    [Toc]    [Back]

     cap_from_text, cap_to_text, cap_value_to_text - convert a POSIX
     capabilities string to internal form, convert capabilities	to a POSIX
     capabilities string, or return the	POSIX name for a capability value

SYNOPSIS    [Toc]    [Back]

     #include <sys/capability.h>

     cap_t cap_from_text(const char *argp);
     char * cap_to_text(cap_t cap, ssize_t *len_p);
     char * cap_value_to_text( cap_value_t capv);

DESCRIPTION    [Toc]    [Back]

     These routines convert strings defined by the POSIX P1003.1e
     specifications (see chcap(1) capabilities(4)) to/from cap_t, which	is the
     internal format for an capability set (see	capability(4)).

RETURN VALUES    [Toc]    [Back]

     cap_from_text returns a pointer to	a cap_t	allocated by the routine or a
     NULL pointer in the case of a failure.  The storage should	be freed when
     no	longer needed by calling cap_free(3c).

     cap_to_text returns a pointer to a	null terminated	character string
     allocated by the routine which is a long form representation of the
     capability, or a NULL pointer if an error occurred.  This string should
     be	freed when no longer needed by calling cap_free(3c).  If the len_p
     argument is not NULL, then	the length of the string is returned in
     ssize_t pointed to	by len_p.

     cap_value_to_text returns a pointer to the	POSIX capability name
     corresponding to the argument capv.

ERRORS    [Toc]    [Back]


     EINVAL	     input text	is invalid

     ENOMEM	     could not allocate	space for new capability


     EINVAL	     input cap is invalid

     ERANGE	     could not allocate	space for the return string


     EINVAL	     capv is not a valid capability value.

									Page 1


SEE ALSO    [Toc]    [Back]

     cap_get_proc(3C), cap_set_proc(3C), capability(4),	capabilities(4),
     dominance(5), chcap(1), attr(1),

									PPPPaaaaggggeeee 2222
[ Back ]
 Similar pages
Name OS Title
mac_from_text IRIX convert a POSIX MAC string from/to mac_t
acl_from_text IRIX convert a POSIX ACL string to a struct acl or a struct acl to a POSIX ACL string
cap_acquire IRIX make permitted set capabilities effective or remove effective capabilities
term HP-UX terminal capabilities
capget Linux set/get process capabilities
cap_get_proc IRIX get or set process capabilities
term_c HP-UX terminal capabilities
term.h HP-UX terminal capabilities
TERM HP-UX terminal capabilities
cap_get_file IRIX get or set the capabilities for a pathname
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service