NAME | SYNOPSIS | DESCRIPTION | ATTRIBUTES | RETURN VALUES | FILES | SEE ALSO | NOTES
#include <tsol/label.h>char * bltocolor(const blevel_t * label);
The calling process must have
PRIV_SYS_TRANS_LABEL
in its set of effective privileges to get color names of labels that dominate the current processes' sensitivity label.
bltocolor() and bltocolor_r() get the character-coded color name associated with the binary label label .
See attributes(5) for descriptions of the following attributes:
ATTRIBUTE TYPE | ATTRIBUTE VALUE |
---|---|
Availability | SUNWtsu |
MT-Level | MT-Safe with exceptions described in NOTES |
bltocolor() returns a pointer to a statically allocated string that contains the character-coded color name specified for the label or returns (char *)0 if, for any reason, no character-coded color name is available for this binary label.
bltocolor_r() returns a pointer to the color_name string which contains the character-coded color name specified for the label or returns (char *)0 if, for any reason, no character-coded color name is available for this binary label. color_name must provide for a string of at least size characters.
The label encodings file contains the classification names, words, constraints, and values for the defined labels of this system.
bcltobanner(3) , bilconjoin(3) , blcompare(3) , blinset(3) , blmanifest(3) , blminmax(3) , blportion(3) , bltos(3) , bltype(3) , blvalid(3) , btohex(3) , hextob(3) , labelinfo(3) , labelvers(3) , sbltos(3) , stobl(3) , label_encodings(4)
Trusted Solaris Developer's Guide , Trusted Solaris User's Guide , and Trusted Solaris administrator's document set
The function bltocolor() returns a pointer to a statically allocated string. Subsequent calls to it will overwrite that string with a new character-coded color name. It is not MT-Safe.
For multithreaded applications the function bltocolor_r() should be used.
If label includes a specified word or words, the character-coded color name associated with the first word specified in the label encodings file is returned. Otherwise, if no character-coded color name is specified for label , the first character-coded color name specified in the label encodings file with the same classification as the binary label is returned.
These interfaces are uncommitted. Although they are not expected to change between minor releases of the Trusted Solaris environment, they may.
NAME | SYNOPSIS | DESCRIPTION | ATTRIBUTES | RETURN VALUES | FILES | SEE ALSO | NOTES