From: tb Date: Mon, 1 May 2023 07:28:11 +0000 (+0000) Subject: First pass of removing low-level ASN.1 streaming docs X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=3f41d2fa12cdc33836ac204042f0fb5ab71c835e;p=openbsd First pass of removing low-level ASN.1 streaming docs --- diff --git a/lib/libcrypto/man/BIO_ctrl.3 b/lib/libcrypto/man/BIO_ctrl.3 index 1efcacfb803..b77c69b5bdd 100644 --- a/lib/libcrypto/man/BIO_ctrl.3 +++ b/lib/libcrypto/man/BIO_ctrl.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: BIO_ctrl.3,v 1.22 2023/04/28 16:22:45 schwarze Exp $ +.\" $OpenBSD: BIO_ctrl.3,v 1.23 2023/05/01 07:28:11 tb Exp $ .\" full merge up to: OpenSSL 24a535eaf Tue Sep 22 13:14:20 2020 +0100 .\" selective merge up to: OpenSSL 0c5bc96f Tue Mar 15 13:57:22 2022 +0000 .\" @@ -66,7 +66,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED .\" OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd $Mdocdate: April 28 2023 $ +.Dd $Mdocdate: May 1 2023 $ .Dt BIO_CTRL 3 .Os .Sh NAME @@ -433,7 +433,7 @@ They are documented in the following manual pages: .It Dv BIO_C_GET_EX_ARG Ta Xr BIO_f_asn1 3 .It Dv BIO_C_GET_PREFIX Ta Xr BIO_asn1_get_prefix 3 .It Dv BIO_C_GET_SUFFIX Ta Xr BIO_asn1_get_suffix 3 -.It Dv BIO_C_SET_EX_ARG Ta Xr BIO_f_asn1 3 , Xr BIO_new_NDEF 3 +.It Dv BIO_C_SET_EX_ARG Ta Xr BIO_f_asn1 3 .It Dv BIO_C_SET_PREFIX Ta Xr BIO_asn1_set_prefix 3 .It Dv BIO_C_SET_SUFFIX Ta Xr BIO_asn1_set_suffix 3 .It Dv BIO_CTRL_DGRAM_GET_FALLBACK_MTU Ta Xr BIO_dgram_set_peer 3 diff --git a/lib/libcrypto/man/BIO_f_asn1.3 b/lib/libcrypto/man/BIO_f_asn1.3 index 3bf5a512049..19aa1f1ba78 100644 --- a/lib/libcrypto/man/BIO_f_asn1.3 +++ b/lib/libcrypto/man/BIO_f_asn1.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: BIO_f_asn1.3,v 1.2 2021/12/12 17:31:18 schwarze Exp $ +.\" $OpenBSD: BIO_f_asn1.3,v 1.3 2023/05/01 07:28:11 tb Exp $ .\" .\" Copyright (c) 2021 Ingo Schwarze .\" @@ -14,7 +14,7 @@ .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. .\" -.Dd $Mdocdate: December 12 2021 $ +.Dd $Mdocdate: May 1 2023 $ .Dt BIO_F_ASN1 3 .Os .Sh NAME @@ -219,7 +219,6 @@ that is not properly initialized. .Xr ASN1_put_object 3 , .Xr BIO_ctrl 3 , .Xr BIO_new 3 , -.Xr BIO_new_NDEF 3 , .Xr BIO_next 3 , .Xr BIO_write 3 , .Xr i2d_ASN1_OCTET_STRING 3 diff --git a/lib/libcrypto/man/BIO_new_CMS.3 b/lib/libcrypto/man/BIO_new_CMS.3 index c1c47e3ad32..ab93e1c00c7 100644 --- a/lib/libcrypto/man/BIO_new_CMS.3 +++ b/lib/libcrypto/man/BIO_new_CMS.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: BIO_new_CMS.3,v 1.8 2021/12/12 17:31:18 schwarze Exp $ +.\" $OpenBSD: BIO_new_CMS.3,v 1.9 2023/05/01 07:28:11 tb Exp $ .\" full merge up to: OpenSSL df75c2bfc Dec 9 01:02:36 2018 +0100 .\" .\" This file was written by Dr. Stephen Henson . @@ -48,7 +48,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED .\" OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd $Mdocdate: December 12 2021 $ +.Dd $Mdocdate: May 1 2023 $ .Dt BIO_NEW_CMS 3 .Os .Sh NAME @@ -128,7 +128,6 @@ The error can be obtained from .Xr ERR_get_error 3 . .Sh SEE ALSO .Xr BIO_new 3 , -.Xr BIO_new_NDEF 3 , .Xr CMS_ContentInfo_new 3 , .Xr CMS_encrypt 3 , .Xr CMS_sign 3 diff --git a/lib/libcrypto/man/BIO_new_NDEF.3 b/lib/libcrypto/man/BIO_new_NDEF.3 deleted file mode 100644 index 9a16924773a..00000000000 --- a/lib/libcrypto/man/BIO_new_NDEF.3 +++ /dev/null @@ -1,120 +0,0 @@ -.\" $OpenBSD: BIO_new_NDEF.3,v 1.3 2021/12/13 13:46:09 schwarze Exp $ -.\" -.\" Copyright (c) 2021 Ingo Schwarze -.\" -.\" Permission to use, copy, modify, and distribute this software for any -.\" purpose with or without fee is hereby granted, provided that the above -.\" copyright notice and this permission notice appear in all copies. -.\" -.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF -.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -.\" -.Dd $Mdocdate: December 13 2021 $ -.Dt BIO_NEW_NDEF 3 -.Os -.Sh NAME -.Nm BIO_new_NDEF -.Nd generic constructor for streaming BIO chains -.Sh SYNOPSIS -.In openssl/asn1.h -.Ft BIO * -.Fo BIO_new_NDEF -.Fa "BIO *out_bio" -.Fa "ASN1_VALUE *val_in" -.Fa "const ASN1_ITEM *it" -.Fc -.Sh DESCRIPTION -.Fn BIO_new_NDEF -is a wrapper around -.Xr BIO_new 3 -with a BIO -.Fa type -of -.Xr BIO_f_asn1 3 -that supports streaming by providing the following additional functionality. -.Pp -The data type -.Fa it -needs to support streaming. -Of the data types built into the library, currently only -.Vt CMS_ContentInfo -and -.Vt PKCS7 -support that. -The argument -.Fa val_in -needs to be of that type. -.Pp -A structure containing the following data is saved using -.Xr BIO_ctrl 3 -with an argument of -.Dv BIO_C_SET_EX_ARG -as described in -.Xr BIO_f_asn1 3 : -.Pp -.Bl -bullet -compact -offset indent -.It -the data type -.Fa it -.It -the input value -.Fa val_in -.It -a pointer to the -.Vt unsigned char * -content buffer of -.Fa val_in , -extracted using a type-specific callback function -.It -a pointer to the new asn1 BIO -.It -a pointer to the beginning of the BIO chain; -this may be the asn1 BIO itself, or one or more filter BIOs -may be prepended to it in a type-specific manner, -for example digest or encoding BIOs -.El -.Pp -In order to handle the output from the new asn1 BIO, the -.Fa out_bio -is appended to it using -.Xr BIO_push 3 . -The -.Fa out_bio -can be a single sink BIO or a BIO chain ending in a sink BIO. -.Pp -A built-in -.Fa prefix -function is installed with -.Xr BIO_asn1_set_prefix 3 -that encodes -.Fa val_in -using -.Xr ASN1_item_ndef_i2d 3 , -and a built-in -.Fa suffix -function is installed that finalizes the written structures -in a type-specific way. -.Sh RETURN VALUES -.Fn BIO_new_NDEF -returns a pointer to the beginning of the constructed BIO chain or -.Dv NULL -if -.Fa it -does not support streaming or if memory allocation fails. -.Sh SEE ALSO -.Xr ASN1_item_ndef_i2d 3 , -.Xr BIO_ctrl 3 , -.Xr BIO_f_asn1 3 , -.Xr BIO_new 3 , -.Xr BIO_new_CMS 3 , -.Xr BIO_push 3 , -.Xr i2d_ASN1_bio_stream 3 -.Sh HISTORY -.Fn BIO_new_NDEF -first appeared in OpenSSL 1.0.0 and has been available since -.Ox 4.9 . diff --git a/lib/libcrypto/man/Makefile b/lib/libcrypto/man/Makefile index 42b4c2fbe10..abefb79c1f2 100644 --- a/lib/libcrypto/man/Makefile +++ b/lib/libcrypto/man/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.250 2023/04/30 19:40:23 tb Exp $ +# $OpenBSD: Makefile,v 1.251 2023/05/01 07:28:11 tb Exp $ .include @@ -51,7 +51,6 @@ MAN= \ BIO_meth_new.3 \ BIO_new.3 \ BIO_new_CMS.3 \ - BIO_new_NDEF.3 \ BIO_printf.3 \ BIO_push.3 \ BIO_read.3 \ @@ -239,7 +238,6 @@ MAN= \ PEM_bytes_read_bio.3 \ PEM_read.3 \ PEM_read_bio_PrivateKey.3 \ - PEM_write_bio_ASN1_stream.3 \ PEM_write_bio_CMS_stream.3 \ PEM_write_bio_PKCS7_stream.3 \ PKCS12_SAFEBAG_new.3 \ @@ -421,7 +419,6 @@ MAN= \ evp.3 \ get_rfc3526_prime_8192.3 \ i2a_ASN1_STRING.3 \ - i2d_ASN1_bio_stream.3 \ i2d_CMS_bio_stream.3 \ i2d_PKCS7_bio_stream.3 \ lh_new.3 \ diff --git a/lib/libcrypto/man/PEM_write_bio_ASN1_stream.3 b/lib/libcrypto/man/PEM_write_bio_ASN1_stream.3 deleted file mode 100644 index 7b965e7b764..00000000000 --- a/lib/libcrypto/man/PEM_write_bio_ASN1_stream.3 +++ /dev/null @@ -1,90 +0,0 @@ -.\" $OpenBSD: PEM_write_bio_ASN1_stream.3,v 1.1 2021/12/13 18:55:22 schwarze Exp $ -.\" -.\" Copyright (c) 2021 Ingo Schwarze -.\" -.\" Permission to use, copy, modify, and distribute this software for any -.\" purpose with or without fee is hereby granted, provided that the above -.\" copyright notice and this permission notice appear in all copies. -.\" -.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF -.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -.\" -.Dd $Mdocdate: December 13 2021 $ -.Dt PEM_WRITE_BIO_ASN1_STREAM 3 -.Os -.Sh NAME -.Nm PEM_write_bio_ASN1_stream -.Nd generic PEM encoder -.Sh SYNOPSIS -.In openssl/asn1.h -.Ft int -.Fo PEM_write_bio_ASN1_stream -.Fa "BIO *out_bio" -.Fa "ASN1_VALUE *val_in" -.Fa "BIO *in_bio" -.Fa "int flags" -.Fa "const char *hdr" -.Fa "const ASN1_ITEM *it" -.Fc -.Sh DESCRIPTION -.Fn PEM_write_bio_ASN1_stream -writes the -.Fa val_in -argument of type -.Fa it -to -.Fa out_bio -in PEM format, that is, BER- and base64-encoded and surrounded by -.Qq -----BEGIN ...----- -and -.Qq -----END ...----- -lines with the -.Fa hdr -argument in place of the ellipses. -.Pp -The -.Fa flags -are passed through to -.Xr i2d_ASN1_bio_stream 3 . -In particular, if the bit -.Dv SMIME_STREAM -is set, streaming is performed, reading the content from -.Fa in_bio . -Streaming is only supported if -.Fa val_in -is of the type -.Vt CMS_ContentInfo -or -.Vt PKCS7 . -.Pp -If the bit -.Dv SMIME_STREAM -is not set, the arguments -.Fa in_bio -and -.Fa flags -are ignored and distinguished encoding rules (DER) are used. -.Sh RETURN VALUES -.Fn PEM_write_bio_ASN1_stream -is intended to return 1 on success or 0 on failure. -.Sh SEE ALSO -.Xr ASN1_item_i2d_bio 3 , -.Xr BIO_f_base64 3 , -.Xr BIO_new 3 , -.Xr i2d_ASN1_bio_stream 3 , -.Xr PEM_write_bio 3 , -.Xr PEM_write_bio_CMS_stream 3 , -.Xr PEM_write_bio_PKCS7_stream 3 -.Sh HISTORY -.Fn PEM_write_bio_ASN1_stream -first appeared in OpenSSL 1.0.0 and has been available since -.Ox 4.9 . -.Sh BUGS -Many kinds of errors are silently ignored. -This function may return 1 even if it only produced partial output -or no output at all. diff --git a/lib/libcrypto/man/PEM_write_bio_CMS_stream.3 b/lib/libcrypto/man/PEM_write_bio_CMS_stream.3 index bd17e410bbc..88adbba74fc 100644 --- a/lib/libcrypto/man/PEM_write_bio_CMS_stream.3 +++ b/lib/libcrypto/man/PEM_write_bio_CMS_stream.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: PEM_write_bio_CMS_stream.3,v 1.5 2021/12/13 18:55:22 schwarze Exp $ +.\" $OpenBSD: PEM_write_bio_CMS_stream.3,v 1.6 2023/05/01 07:28:11 tb Exp $ .\" full merge up to: OpenSSL df75c2bf Dec 9 01:02:36 2018 +0100 .\" .\" This file was written by Dr. Stephen Henson . @@ -48,7 +48,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED .\" OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd $Mdocdate: December 13 2021 $ +.Dd $Mdocdate: May 1 2023 $ .Dt PEM_WRITE_BIO_CMS_STREAM 3 .Os .Sh NAME @@ -87,7 +87,6 @@ returns 1 for success or 0 for failure. .Xr ERR_get_error 3 , .Xr i2d_CMS_bio_stream 3 , .Xr PEM_write 3 , -.Xr PEM_write_bio_ASN1_stream 3 , .Xr SMIME_write_CMS 3 .Sh HISTORY .Fn PEM_write_bio_CMS_stream diff --git a/lib/libcrypto/man/PEM_write_bio_PKCS7_stream.3 b/lib/libcrypto/man/PEM_write_bio_PKCS7_stream.3 index 5b4175e4f35..9050b8562fd 100644 --- a/lib/libcrypto/man/PEM_write_bio_PKCS7_stream.3 +++ b/lib/libcrypto/man/PEM_write_bio_PKCS7_stream.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: PEM_write_bio_PKCS7_stream.3,v 1.11 2021/12/13 18:55:22 schwarze Exp $ +.\" $OpenBSD: PEM_write_bio_PKCS7_stream.3,v 1.12 2023/05/01 07:28:11 tb Exp $ .\" full merge up to: OpenSSL df75c2bf Dec 9 01:02:36 2018 +0100 .\" .\" This file was written by Dr. Stephen Henson . @@ -48,7 +48,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED .\" OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd $Mdocdate: December 13 2021 $ +.Dd $Mdocdate: May 1 2023 $ .Dt PEM_WRITE_BIO_PKCS7_STREAM 3 .Os .Sh NAME @@ -80,7 +80,6 @@ otherwise 0 is returned and an error code can be retrieved with .Sh SEE ALSO .Xr BIO_new 3 , .Xr i2d_PKCS7_bio_stream 3 , -.Xr PEM_write_bio_ASN1_stream 3 , .Xr PEM_write_PKCS7 3 , .Xr PKCS7_final 3 , .Xr PKCS7_new 3 , diff --git a/lib/libcrypto/man/RSA_check_key.3 b/lib/libcrypto/man/RSA_check_key.3 index 96b1468433f..c1e6379ac50 100644 --- a/lib/libcrypto/man/RSA_check_key.3 +++ b/lib/libcrypto/man/RSA_check_key.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: RSA_check_key.3,v 1.8 2021/03/12 05:18:00 jsg Exp $ +.\" $OpenBSD: RSA_check_key.3,v 1.9 2023/05/01 07:28:11 tb Exp $ .\" OpenSSL 6859cf74 Sep 25 13:33:28 2002 +0000 .\" .\" This file was written by Ulf Moeller and @@ -49,7 +49,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED .\" OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd $Mdocdate: March 12 2021 $ +.Dd $Mdocdate: May 1 2023 $ .Dt RSA_CHECK_KEY 3 .Os .Sh NAME @@ -142,7 +142,9 @@ structure elements directly, bypassing the .Vt RSA_METHOD table altogether (and completely violating encapsulation and object-orientation in the process). -The best fix will probably be to introduce a check_key() handler +The best fix will probably be to introduce a +.Fn check_key +handler to the .Vt RSA_METHOD function table so that alternative implementations can also provide diff --git a/lib/libcrypto/man/SMIME_crlf_copy.3 b/lib/libcrypto/man/SMIME_crlf_copy.3 index 3062634f386..3b461384737 100644 --- a/lib/libcrypto/man/SMIME_crlf_copy.3 +++ b/lib/libcrypto/man/SMIME_crlf_copy.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: SMIME_crlf_copy.3,v 1.2 2021/12/14 15:22:49 schwarze Exp $ +.\" $OpenBSD: SMIME_crlf_copy.3,v 1.3 2023/05/01 07:28:11 tb Exp $ .\" .\" Copyright (c) 2021 Ingo Schwarze .\" @@ -14,7 +14,7 @@ .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. .\" -.Dd $Mdocdate: December 14 2021 $ +.Dd $Mdocdate: May 1 2023 $ .Dt SMIME_CRLF_COPY 3 .Os .Sh NAME @@ -78,7 +78,6 @@ is intended to return 1 on success or 0 on failure. .Xr BIO_new 3 , .Xr BIO_push 3 , .Xr BIO_read 3 , -.Xr i2d_ASN1_bio_stream 3 , .Xr SMIME_text 3 , .Xr SMIME_write_ASN1 3 .Sh HISTORY diff --git a/lib/libcrypto/man/SMIME_write_ASN1.3 b/lib/libcrypto/man/SMIME_write_ASN1.3 index 971cd226dd6..a02fa58570b 100644 --- a/lib/libcrypto/man/SMIME_write_ASN1.3 +++ b/lib/libcrypto/man/SMIME_write_ASN1.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: SMIME_write_ASN1.3,v 1.1 2021/12/13 17:24:39 schwarze Exp $ +.\" $OpenBSD: SMIME_write_ASN1.3,v 1.2 2023/05/01 07:28:11 tb Exp $ .\" .\" Copyright (c) 2021 Ingo Schwarze .\" @@ -14,7 +14,7 @@ .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. .\" -.Dd $Mdocdate: December 13 2021 $ +.Dd $Mdocdate: May 1 2023 $ .Dt SMIME_WRITE_ASN1 3 .Os .Sh NAME @@ -126,9 +126,7 @@ or .Qq application/pkcs7-signature are used instead. .It Dv SMIME_STREAM -Perform streaming by passing this flag through to -.Xr i2d_ASN1_bio_stream 3 -and reading the content from +Perform streaming by reading the content from .Fa in_bio . This only works if .Dv SMIME_DETACHED @@ -151,7 +149,6 @@ is intended to return 1 on success or 0 on failure. .Xr ASN1_item_i2d_bio 3 , .Xr BIO_f_base64 3 , .Xr BIO_new 3 , -.Xr i2d_ASN1_bio_stream 3 , .Xr SMIME_crlf_copy 3 , .Xr SMIME_write_CMS 3 , .Xr SMIME_write_PKCS7 3 , diff --git a/lib/libcrypto/man/i2d_ASN1_bio_stream.3 b/lib/libcrypto/man/i2d_ASN1_bio_stream.3 deleted file mode 100644 index 17ac95778c7..00000000000 --- a/lib/libcrypto/man/i2d_ASN1_bio_stream.3 +++ /dev/null @@ -1,96 +0,0 @@ -.\" $OpenBSD: i2d_ASN1_bio_stream.3,v 1.3 2021/12/13 18:55:22 schwarze Exp $ -.\" -.\" Copyright (c) 2021 Ingo Schwarze -.\" -.\" Permission to use, copy, modify, and distribute this software for any -.\" purpose with or without fee is hereby granted, provided that the above -.\" copyright notice and this permission notice appear in all copies. -.\" -.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF -.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -.\" -.Dd $Mdocdate: December 13 2021 $ -.Dt I2D_ASN1_BIO_STREAM 3 -.Os -.Sh NAME -.Nm i2d_ASN1_bio_stream -.Nd generic BER streamer -.Sh SYNOPSIS -.In openssl/asn1.h -.Ft int -.Fo i2d_ASN1_bio_stream -.Fa "BIO *out_bio" -.Fa "ASN1_VALUE *val_in" -.Fa "BIO *in_bio" -.Fa "int flags" -.Fa "const ASN1_ITEM *it" -.Fc -.Sh DESCRIPTION -If the bit -.Dv SMIME_STREAM -is not set in the -.Fa flags -argument, -.Fn i2d_ASN1_bio_stream -does the same as -.Xr ASN1_item_i2d_bio 3 , -ignoring the -.Fa in_bio -and -.Fa flags -arguments. -.Pp -If the bit -.Dv SMIME_STREAM -is set, it creates a streaming BIO with -.Xr BIO_new_NDEF 3 , -copies the data from -.Fa in_bio -to it using -.Xr SMIME_crlf_copy 3 , -finalizes the output with -.Xr BIO_flush 3 , -and frees the newly created BIOs up to but not including -.Fa out_bio . -.Pp -If -.Fa it -is -.Va PKCS7_it , -this function behaves exactly as -.Xr i2d_PKCS7_bio_stream 3 ; -for -.Va CMS_ContentInfo_it , -it behaves exactly as -.Xr i2d_CMS_bio_stream 3 . -For other values of -.Fa it , -the function fails. -.Sh RETURN VALUES -.Fn i2d_ASN1_bio_stream -is intended to return 1 on success or 0 on failure. -.Sh SEE ALSO -.Xr ASN1_item_i2d_bio 3 , -.Xr ASN1_item_ndef_i2d 3 , -.Xr BIO_flush 3 , -.Xr BIO_new 3 , -.Xr BIO_new_NDEF 3 , -.Xr BIO_push 3 , -.Xr i2d_CMS_bio_stream 3 , -.Xr i2d_PKCS7_bio_stream 3 , -.Xr PEM_write_bio_ASN1_stream 3 , -.Xr SMIME_crlf_copy 3 , -.Xr SMIME_write_ASN1 3 -.Sh HISTORY -.Fn i2d_ASN1_bio_stream -first appeared in OpenSSL 1.0.0 and has been available since -.Ox 4.9 . -.Sh BUGS -Many kinds of errors are silently ignored. -This function may return 1 even if it only produced partial output -or no output at all. diff --git a/lib/libcrypto/man/i2d_CMS_bio_stream.3 b/lib/libcrypto/man/i2d_CMS_bio_stream.3 index b3c29af3a25..b60468464cf 100644 --- a/lib/libcrypto/man/i2d_CMS_bio_stream.3 +++ b/lib/libcrypto/man/i2d_CMS_bio_stream.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: i2d_CMS_bio_stream.3,v 1.5 2021/12/13 13:46:09 schwarze Exp $ +.\" $OpenBSD: i2d_CMS_bio_stream.3,v 1.6 2023/05/01 07:28:11 tb Exp $ .\" full merge up to: OpenSSL df75c2bf Dec 9 01:02:36 2018 +0100 .\" .\" This file was written by Dr. Stephen Henson . @@ -48,7 +48,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED .\" OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd $Mdocdate: December 13 2021 $ +.Dd $Mdocdate: May 1 2023 $ .Dt I2D_CMS_BIO_STREAM 3 .Os .Sh NAME @@ -83,7 +83,6 @@ returns 1 for success or 0 for failure. .Xr CMS_encrypt 3 , .Xr CMS_sign 3 , .Xr ERR_get_error 3 , -.Xr i2d_ASN1_bio_stream 3 , .Xr PEM_write_bio_CMS_stream 3 , .Xr SMIME_write_CMS 3 .Sh HISTORY diff --git a/lib/libcrypto/man/i2d_PKCS7_bio_stream.3 b/lib/libcrypto/man/i2d_PKCS7_bio_stream.3 index b3416f5d488..7a47ba30262 100644 --- a/lib/libcrypto/man/i2d_PKCS7_bio_stream.3 +++ b/lib/libcrypto/man/i2d_PKCS7_bio_stream.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: i2d_PKCS7_bio_stream.3,v 1.10 2021/12/13 13:46:09 schwarze Exp $ +.\" $OpenBSD: i2d_PKCS7_bio_stream.3,v 1.11 2023/05/01 07:28:11 tb Exp $ .\" OpenSSL df75c2bf Dec 9 01:02:36 2018 +0100 .\" .\" This file was written by Dr. Stephen Henson . @@ -49,7 +49,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED .\" OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.Dd $Mdocdate: December 13 2021 $ +.Dd $Mdocdate: May 1 2023 $ .Dt I2D_PKCS7_BIO_STREAM 3 .Os .Sh NAME @@ -80,7 +80,6 @@ returns 1 for success or 0 for failure. .Sh SEE ALSO .Xr BIO_new 3 , .Xr ERR_get_error 3 , -.Xr i2d_ASN1_bio_stream 3 , .Xr PEM_write_bio_PKCS7_stream 3 , .Xr PEM_write_PKCS7 3 , .Xr PKCS7_final 3 ,