1=pod
2
3=begin comment
4{- join("\n", @autowarntext) -}
5
6=end comment
7
8=head1 NAME
9
10openssl-pkcs7 - PKCS#7 command
11
12=head1 SYNOPSIS
13
14B<openssl> B<pkcs7>
15[B<-help>]
16[B<-inform> B<DER>|B<PEM>]
17[B<-outform> B<DER>|B<PEM>]
18[B<-in> I<filename>]
19[B<-out> I<filename>]
20[B<-print>]
21[B<-print_certs>]
22[B<-text>]
23[B<-noout>]
24{- $OpenSSL::safe::opt_engine_synopsis -}{- $OpenSSL::safe::opt_provider_synopsis -}
25
26=head1 DESCRIPTION
27
28This command processes PKCS#7 files.  Note that it only understands PKCS#7
29v 1.5 as specified in IETF RFC 2315.  It cannot currently parse CMS as
30described in IETF RFC 2630.
31
32=head1 OPTIONS
33
34=over 4
35
36=item B<-help>
37
38Print out a usage message.
39
40=item B<-inform> B<DER>|B<PEM>, B<-outform> B<DER>|B<PEM>
41
42The input and formats; the default is B<PEM>.
43See L<openssl-format-options(1)> for details.
44
45The data is a PKCS#7 Version 1.5 structure.
46
47=item B<-in> I<filename>
48
49This specifies the input filename to read from or standard input if this
50option is not specified.
51
52=item B<-out> I<filename>
53
54Specifies the output filename to write to or standard output by
55default.
56
57=item B<-print>
58
59Print out the full PKCS7 object.
60
61=item B<-print_certs>
62
63Prints out any certificates or CRLs contained in the file. They are
64preceded by their subject and issuer names in one line format.
65
66=item B<-text>
67
68Prints out certificate details in full rather than just subject and
69issuer names.
70
71=item B<-noout>
72
73Don't output the encoded version of the PKCS#7 structure (or certificates
74if B<-print_certs> is set).
75
76{- $OpenSSL::safe::opt_engine_item -}
77
78{- $OpenSSL::safe::opt_provider_item -}
79
80=back
81
82=head1 EXAMPLES
83
84Convert a PKCS#7 file from PEM to DER:
85
86 openssl pkcs7 -in file.pem -outform DER -out file.der
87
88Output all certificates in a file:
89
90 openssl pkcs7 -in file.pem -print_certs -out certs.pem
91
92=head1 SEE ALSO
93
94L<openssl(1)>,
95L<openssl-crl2pkcs7(1)>
96
97=head1 HISTORY
98
99The B<-engine> option was deprecated in OpenSSL 3.0.
100
101=head1 COPYRIGHT
102
103Copyright 2000-2021 The OpenSSL Project Authors. All Rights Reserved.
104
105Licensed under the Apache License 2.0 (the "License").  You may not use
106this file except in compliance with the License.  You can obtain a copy
107in the file LICENSE in the source distribution or at
108L<https://www.openssl.org/source/license.html>.
109
110=cut
111