1*b077aed3SPierre Pronchery=pod 2*b077aed3SPierre Pronchery 3*b077aed3SPierre Pronchery=head1 NAME 4*b077aed3SPierre Pronchery 5*b077aed3SPierre Proncheryossl_DER_w_begin_sequence, ossl_DER_w_end_sequence 6*b077aed3SPierre Pronchery- internal DER writers for DER constructed elements 7*b077aed3SPierre Pronchery 8*b077aed3SPierre Pronchery=head1 SYNOPSIS 9*b077aed3SPierre Pronchery 10*b077aed3SPierre Pronchery #include "internal/der.h" 11*b077aed3SPierre Pronchery 12*b077aed3SPierre Pronchery int ossl_DER_w_begin_sequence(WPACKET *pkt, int tag); 13*b077aed3SPierre Pronchery int ossl_DER_w_end_sequence(WPACKET *pkt, int tag); 14*b077aed3SPierre Pronchery 15*b077aed3SPierre Pronchery=head1 DESCRIPTION 16*b077aed3SPierre Pronchery 17*b077aed3SPierre ProncheryAll functions described here are wrappers for constructed structures, 18*b077aed3SPierre Proncheryi.e. the ASN.1 SEQUENCE, SET and CHOICE specifications. They all come 19*b077aed3SPierre Proncheryin pairs, as noted by the function names containing the words C<begin> 20*b077aed3SPierre Proncheryand B<end>. 21*b077aed3SPierre Pronchery 22*b077aed3SPierre ProncheryWhen using these, special care must be taken to ensure that the ASN.1 tag 23*b077aed3SPierre Proncheryvalue I<tag> is the same in the matching C<begin> and C<end> function calls. 24*b077aed3SPierre Pronchery 25*b077aed3SPierre Proncheryossl_DER_w_begin_sequence() and ossl_DER_w_end_sequence() begins and ends a 26*b077aed3SPierre ProncherySEQUENCE. 27*b077aed3SPierre Pronchery 28*b077aed3SPierre Pronchery=head1 RETURN VALUES 29*b077aed3SPierre Pronchery 30*b077aed3SPierre ProncheryAll the functions return 1 on success and 0 on failure. Failure may 31*b077aed3SPierre Proncherymean that the buffer held by the I<pkt> is too small, but may also 32*b077aed3SPierre Proncherymean that the values given to the functions are invalid, such as the provided 33*b077aed3SPierre ProncheryI<tag> value being too large for the implementation. 34*b077aed3SPierre Pronchery 35*b077aed3SPierre Pronchery=head1 SEE ALSO 36*b077aed3SPierre Pronchery 37*b077aed3SPierre ProncheryL<DERlib(7)> 38*b077aed3SPierre Pronchery 39*b077aed3SPierre Pronchery=head1 COPYRIGHT 40*b077aed3SPierre Pronchery 41*b077aed3SPierre ProncheryCopyright 2020 The OpenSSL Project Authors. All Rights Reserved. 42*b077aed3SPierre Pronchery 43*b077aed3SPierre ProncheryLicensed under the Apache License 2.0 (the "License"). You may not use 44*b077aed3SPierre Proncherythis file except in compliance with the License. You can obtain a copy 45*b077aed3SPierre Proncheryin the file LICENSE in the source distribution or at 46*b077aed3SPierre ProncheryL<https://www.openssl.org/source/license.html>. 47*b077aed3SPierre Pronchery 48*b077aed3SPierre Pronchery=cut 49