diff options
Diffstat (limited to 'lib/libcrypto/man/ASN1_STRING_print_ex.3')
-rw-r--r-- | lib/libcrypto/man/ASN1_STRING_print_ex.3 | 41 |
1 files changed, 20 insertions, 21 deletions
diff --git a/lib/libcrypto/man/ASN1_STRING_print_ex.3 b/lib/libcrypto/man/ASN1_STRING_print_ex.3 index 75a07a0b6e3..19ff081f792 100644 --- a/lib/libcrypto/man/ASN1_STRING_print_ex.3 +++ b/lib/libcrypto/man/ASN1_STRING_print_ex.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: ASN1_STRING_print_ex.3,v 1.3 2016/11/06 15:52:50 jmc Exp $ +.\" $OpenBSD: ASN1_STRING_print_ex.3,v 1.4 2016/11/06 16:56:46 jmc Exp $ .\" .Dd $Mdocdate: November 6 2016 $ .Dt ASN1_STRING_PRINT_EX 3 @@ -33,14 +33,14 @@ These functions output an structure. .Vt ASN1_STRING is used to -represent all the ASN1 string types. +represent all the ASN.1 string types. .Pp .Fn ASN1_STRING_print_ex outputs .Fa str to .Fa out , -the format is determined by the options +the format being determined by the options .Fa flags . .Fn ASN1_STRING_print_ex_fp is identical except it outputs to @@ -56,15 +56,16 @@ but using a different format to .Fn ASN1_STRING_print_ex . It replaces unprintable characters (other than CR, LF) with .Sq \&. . -.Sh NOTES +.Pp .Fn ASN1_STRING_print is a legacy function which should be avoided in new applications. .Pp -Although there are a large number of options frequently +Although there are a large number of options, +.Dv ASN1_STRFLGS_RFC2253 +is often suitable, or on UTF-8 terminals .Dv ASN1_STRFLGS_RFC2253 -is suitable, or on UTF8 terminals -.Dv ASN1_STRFLGS_RFC2253 No & +and .Pf ~ Dv ASN1_STRFLGS_ESC_MSB . .Pp The complete set of supported options for @@ -74,7 +75,7 @@ is listed below. Various characters can be escaped. If .Dv ASN1_STRFLGS_ESC_2253 -is set, the characters determined by RFC2253 are escaped. +is set, the characters determined by RFC 2253 are escaped. If .Dv ASN1_STRFLGS_ESC_CTRL is set, control characters are escaped. @@ -82,15 +83,14 @@ If .Dv ASN1_STRFLGS_ESC_MSB is set, characters with the MSB set are escaped: this option should .Em not -be used if the terminal correctly interprets UTF8 sequences. +be used if the terminal correctly interprets UTF-8 sequences. .Pp Escaping takes several forms. -.Pp -If the character being escaped is a 16 bit character then the form "\eUXXXX" +If the character being escaped is a 16-bit character then the form "\eUXXXX" is used using exactly four characters for the hex representation. If it is 32 bits then "\eWXXXXXXXX" is used using eight characters of its hex representation. -These forms will only be used if UTF8 conversion is not set (see below). +These forms will only be used if UTF-8 conversion is not set (see below). .Pp Printable characters are normally escaped using the backslash .Pq Sq \e @@ -104,24 +104,24 @@ representation. .Pp If .Dv ASN1_STRFLGS_UTF8_CONVERT -is set, then characters are converted to UTF8 format first. -If the terminal supports the display of UTF8 sequences then this -option will correctly display multi byte characters. +is set, then characters are converted to UTF-8 format first. +If the terminal supports the display of UTF-8 sequences then this +option will correctly display multi-byte characters. .Pp If .Dv ASN1_STRFLGS_IGNORE_TYPE is set, then the string type is not interpreted at all: everything is assumed to be one byte per character. This is primarily for debugging purposes and can result -in confusing output in multi character strings. +in confusing output in multi-character strings. .Pp If .Dv ASN1_STRFLGS_SHOW_TYPE -is set, then the string type itself is printed out before its value -(for example "BMPSTRING"), this actually uses +is set, then the string type itself is printed before its value +(for example "BMPSTRING"), using .Fn ASN1_tag2str . .Pp -The content of a string instead of being interpreted can be "dumped": +Instead of being interpreted the contents of a string can be "dumped": this just outputs the value of the string using the form #XXXX using hex format for each octet. .Pp @@ -129,7 +129,7 @@ If .Dv ASN1_STRFLGS_DUMP_ALL is set, then any type is dumped. .Pp -Normally non character string types (such as OCTET STRING) +Normally non-character string types (such as OCTET STRING) are assumed to be one byte per character; if .Dv ASN1_STRFLGS_DUMP_UNKNOWN is set, then they will be dumped instead. @@ -149,5 +149,4 @@ It is equivalent to .Dv ASN1_STRFLGS_DUMP_UNKNOWN | .Dv ASN1_STRFLGS_DUMP_DER . .Sh SEE ALSO -.Xr ASN1_tag2str 3 , .Xr X509_NAME_print_ex 3 |