-.\" $OpenBSD: openssl.1,v 1.143 2023/04/25 16:11:02 tb Exp $
+.\" $OpenBSD: openssl.1,v 1.144 2023/05/05 18:01:27 tb Exp $
.\" ====================================================================
.\" Copyright (c) 1998-2002 The OpenSSL Project. All rights reserved.
.\"
.\" copied and put under another distribution licence
.\" [including the GNU Public Licence.]
.\"
-.Dd $Mdocdate: April 25 2023 $
+.Dd $Mdocdate: May 5 2023 $
.Dt OPENSSL 1
.Os
.Sh NAME
for no padding;
.Cm oaep
for OAEP mode;
+.Cm x931
+for X9.31 mode;
and
.Cm pss
for PSS.
structure is used and its length
must correspond to the digest type.
For oeap mode only encryption and decryption is supported.
+For x931 if the digest type is set it is used to format the block data;
+otherwise the first byte is used to specify the X9.31 digest ID.
Sign, verify, and verifyrecover can be performed in this mode.
For pss mode only sign and verify are supported and the digest type must be
specified.
.Op Fl in Ar file
.Op Fl inkey Ar file
.Op Fl keyform Cm der | pem
-.Op Fl oaep | pkcs | raw
+.Op Fl oaep | pkcs | raw | x931
.Op Fl out Ar file
.Op Fl passin Ar arg
.Op Fl pubin
The private key format.
The default is
.Cm pem .
-.It Fl oaep | pkcs | raw
+.It Fl oaep | pkcs | raw | x931
The padding to use:
-PKCS#1 OAEP, PKCS#1 v1.5 (the default), no padding,
+PKCS#1 OAEP, PKCS#1 v1.5 (the default), no padding, or ANSI X9.31,
respectively.
For signatures, only
.Fl pkcs
-/* $OpenBSD: rsautl.c,v 1.22 2023/04/09 18:33:26 tb Exp $ */
+/* $OpenBSD: rsautl.c,v 1.23 2023/05/05 18:01:27 tb Exp $ */
/* Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL
* project 2000.
*/
.value = RSA_VERIFY,
.opt.value = &cfg.rsa_mode,
},
+ {
+ .name = "x931",
+ .desc = "Use ANSI X9.31 padding",
+ .type = OPTION_VALUE,
+ .value = RSA_X931_PADDING,
+ .opt.value = &cfg.pad,
+ },
{NULL},
};
"usage: rsautl [-asn1parse] [-certin] [-decrypt] [-encrypt] "
"[-hexdump]\n"
" [-in file] [-inkey file] [-keyform der | pem]\n"
- " [-oaep | -pkcs | -raw] [-out file] [-passin arg]\n"
+ " [-oaep | -pkcs | -raw | -x931] [-out file] [-passin arg]\n"
" [-pubin] [-rev] [-sign] [-verify]\n\n");
options_usage(rsautl_options);