MyWebUniversity.com Home Page
 



OpenSolaris man pages main menu


Trusted Extensions Library Functions                btohex(3TSOL)



NAME
     btohex, bsltoh, bcleartoh, bsltohr,  bcleartohr,  halloc,
     hfree - convert binary label to hexadecimal

SYNOPSIS
     cc [flag...] file... -ltsol [library...]


     #include 

     char *bsltoh(const mlabelt *label);


     char *bcleartoh(const mlabelt *clearance);


     char *bsltohr(const mlabelt *label, char *hex);


     char *bcleartohr(const mlabelt *clearance, char *hex);


     char *halloc(const unsigned char type);


     void hfree(char *hex);


DESCRIPTION
     These  functions  convert  binary  labels  into  hexadecimal
     strings that represent the internal value.


     The bsltoh() and bsltohr() functions convert a binary  sen-
     sitivity label into a string of the form:

       [0xsensitivitylabelhexadecimalvalue]




     The bcleartoh() and bcleartohr() functions convert a binary
     clearance into a string of the form:

       0xclearancehexadecimalvalue




     The halloc() function allocates memory for the  hexadecimal
     value type for use by bsltohr() and bcleartohr().




SunOS 5.11          Last change: 20 Jul 2007                    1






Trusted Extensions Library Functions                btohex(3TSOL)



     Valid values for type are:

     SUNSLID     label is a binary sensitivity label.


     SUNCLRID    label is a binary clearance.



     The hfree() function frees memory allocated by halloc().

RETURN VALUES
     These functions return a pointer to a string  that  contains
     the result of the translation, or (char *)0 if the parameter
     is not of the required type.

ATRIBUTES
     See attributes(5) for descriptions of the  following  attri-
     butes:



     
           ATRIBUTE TYPE               ATRIBUTE VALUE       
    
     Interface Stability          Obsolete                    
    
     MT-Level                     MT-Safe with exceptions     
    



     The  bsltoh(),   bcleartoh(),   bsltohr(),   bcleartohr(),
     halloc(),  and  hfree()  functions  are  Obsolete. Use the
     labeltostr(3TSOL) function instead.


     The bsltoh() and bcleartoh() functions share the same stati-
     cally allocated string storage. They are not MT-Safe. Subse-
     quent calls to any of these functions  will  overwrite  that
     string  with the newly translated string. The bsltohr() and
     bcleartohr() functions should  be  used  in   multithreaded
     applications.

SEE ALSO
     atohexlabel(1M),        hextoalabel(1M),labeltostr(3TSOL),
     libtsol(3LIB), attributes(5), labels(5)

NOTES
     The functionality described on this manual page is available
     only if the system is configured with Trusted Extensions.




SunOS 5.11          Last change: 20 Jul 2007                    2



OpenSolaris man pages main menu

Contact us      |       About us      |       Term of use      |       Copyright © 2000-2010 MyWebUniversity.com ™