summaryrefslogtreecommitdiffstats
path: root/apps/pkeyutl.c
AgeCommit message (Collapse)Author
2016-03-03Add KDF support to pkeyutl. Update documentation.Dr. Stephen Henson
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-03-01Fix -pkeyopt and fix error check.Dr. Stephen Henson
Reviewed-by: Rich Salz <rsalz@openssl.org>
2016-02-22Remove unused parameters from internal functionsRich Salz
Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-02-20argv was set but unusedKurt Roeckx
Also gives an error message when you gave it a parameter it didn't expect. Reviewed-by: Rich Salz <rsalz@openssl.org> MR: #2009
2016-02-07more doc fixesRich Salz
dgst: using digest instead of specific digest commands the digest list specified in man dgst may be inaccurate, hence using digest and referring to the list in digest-commands 'sha' as a digest name is no longer supported dgst,pkeyutl cmds help cleanup - In dgst, pkeyutl cmds, some options help was missing. - fixed a minor typo in openssl.pod, that fixes make install. - digest-commands was showing ‘sha’, which is not a supported digest anymore. Signed-off-by: Rich Salz <rsalz@openssl.org> Reviewed-by: Tim Hudson <tjh@openssl.org>
2016-02-04Fix pkeyutl inability to directly access keys on hardware tokensMouse
Reviewed-by: Rich Salz <rsalz@openssl.org> Reviewed-by: Richard Levitte <levitte@openssl.org>
2016-02-02Fix pkeyutl/rsautl empty encrypt-input/decrypt-output handlingViktor Dukhovni
Also fix option processing in pkeyutl to allow use of (formerly) "out-of-order" switches that were needless implementation limitations. Handle documented "ENGINE" form with -keyform and -peerform. Better handling of OPENSSL_NO_ENGINE and OPENSSL_NO_RSA. RT2018 Reviewed-by: Rich Salz <rsalz@openssl.org>
2015-11-09Continue standardisation of malloc handling in appsMatt Caswell
continue on from previous commits but in the apps directory Reviewed-by: Kurt Roeckx <kurt@openssl.org>
2015-10-12Centralise loading default apps config fileMatt Caswell
Loading the config file after processing command line options can cause problems, e.g. where an engine provides new ciphers/digests these are not then recoginised on the command line. Move the default config file loading to before the command line option processing. Whilst we're doing this we might as well centralise this instead of doing it individually for each application. Finally if we do it before the OpenSSL_add_ssl_algorithms() call then ciphersuites provided by an engine (e.g. GOST) can be available to the apps. RT#4085 RT#4086 Reviewed-by: Richard Levitte <levitte@openssl.org>
2015-09-06Change the way apps open their input and output filesRichard Levitte
The different apps had the liberty to decide whether they would open their input and output files in binary mode or not, which could be confusing if two different apps were handling the same type of file in different ways. The solution is to centralise the decision of low level file organisation, and that the apps would use a selection of formats to state the intent of the file. Reviewed-by: Tim Hudson <tjh@openssl.org>
2015-07-31RT3961: Fix switch/case errors in flag parsingAdam Eijdenberg
Reviewed-by: Matt Caswell <matt@openssl.org>
2015-05-29Restore module loadingRichard Levitte
The module loading feature got broken a while ago, so restore it, but have it a bit more explicit this time around. Reviewed-by: Stephen Henson <steve@openssl.org>
2015-05-01free null cleanup finaleRich Salz
Don't check for NULL before calling OPENSSL_free Reviewed-by: Richard Levitte <levitte@openssl.org>
2015-04-30In apps, malloc or dieRich Salz
No point in proceeding if you're out of memory. So change *all* OPENSSL_malloc calls in apps to use the new routine which prints a message and exits. Reviewed-by: Richard Levitte <levitte@openssl.org>
2015-04-25fewer NO_ENGINE #ifdef'sRich Salz
Make setup_engine be a dummy if NO_ENGINE is enabled. The option is not enabled if NO_ENGINE is enabled, so the one "wasted" variable just sits there. Removes some variables and code. Reviewed-by: Richard Levitte <levitte@openssl.org>
2015-04-24Big apps cleanup (option-parsing, etc)Rich Salz
This is merges the old "rsalz-monolith" branch over to master. The biggest change is that option parsing switch from cascasding 'else if strcmp("-foo")' to a utility routine and somethin akin to getopt. Also, an error in the command line no longer prints the full summary; use -help (or --help :) for that. There have been many other changes and code-cleanup, see bullet list below. Special thanks to Matt for the long and detailed code review. TEMPORARY: For now, comment out CRYPTO_mem_leaks() at end of main Tickets closed: RT3515: Use 3DES in pkcs12 if built with no-rc2 RT1766: s_client -reconnect and -starttls broke RT2932: Catch write errors RT2604: port should be 'unsigned short' RT2983: total_bytes undeclared #ifdef RENEG RT1523: Add -nocert to fix output in x509 app RT3508: Remove unused variable introduced by b09eb24 RT3511: doc fix; req default serial is random RT1325,2973: Add more extensions to c_rehash RT2119,3407: Updated to dgst.pod RT2379: Additional typo fix RT2693: Extra include of string.h RT2880: HFS is case-insensitive filenames RT3246: req command prints version number wrong Other changes; incompatibilities marked with *: Add SCSV support Add -misalign to speed command Make dhparam, dsaparam, ecparam, x509 output C in proper style Make some internal ocsp.c functions void Only display cert usages with -help in verify Use global bio_err, remove "BIO*err" parameter from functions For filenames, - always means stdin (or stdout as appropriate) Add aliases for -des/aes "wrap" ciphers. *Remove support for IISSGC (server gated crypto) *The undocumented OCSP -header flag is now "-header name=value" *Documented the OCSP -header flag Reviewed-by: Matt Caswell <matt@openssl.org>
2015-03-28free NULL cleanupRich Salz
EVP_.*free; this gets: EVP_CIPHER_CTX_free EVP_PKEY_CTX_free EVP_PKEY_asn1_free EVP_PKEY_asn1_set_free EVP_PKEY_free EVP_PKEY_free_it EVP_PKEY_meth_free; and also EVP_CIPHER_CTX_cleanup Reviewed-by: Kurt Roeckx <kurt@openssl.org>
2015-01-22Run util/openssl-format-source -v -c .Matt Caswell
Reviewed-by: Tim Hudson <tjh@openssl.org>
2010-11-11PR: 2366Dr. Stephen Henson
Submitted by: Damien Miller <djm@mindrot.org> Reviewed by: steve Stop pkeyutl crashing if some arguments are missing. Also make str2fmt tolerate NULL parameter.
2009-04-15Updates from 1.0.0-stable.Dr. Stephen Henson
2008-11-05Update obsolete email address...Dr. Stephen Henson
2006-08-20Correct warnings about signedness.Richard Levitte
2006-07-21Avoid WIN32 warning.Dr. Stephen Henson
2006-07-21Avoid warnings.Dr. Stephen Henson
2006-05-26Fix warnings.Dr. Stephen Henson
2006-05-26Update pkeyutl to use size_t for pkey functions.Dr. Stephen Henson
2006-05-25Signed vs. unsigned conflictRichard Levitte
2006-04-26Fix usage message for pkeyutl.Dr. Stephen Henson
2006-04-15Use more flexible method of determining output length, by setting &outlenDr. Stephen Henson
value of the passed output buffer is NULL. The old method of using EVP_PKEY_size(pkey) isn't flexible enough to cover all cases where the output length may depend on the operation or the parameters associated with it.
2006-04-13Complete key derivation support.Dr. Stephen Henson
2006-04-13Change the option setting command line switch to "-pkeyopt" to avoid confusionDr. Stephen Henson
with algorithm parameters.
2006-04-11Initial keygen support.Dr. Stephen Henson
2006-04-09Add RSA ctrl for padding mode, add ctrl support in pkeyutl.Dr. Stephen Henson
2006-04-09Fix typo. Add EVP_PKEY_CTX control function for later use by command lineDr. Stephen Henson
utilities.
2006-04-08Reformat pkeyutl.c, add support for verify operation but nothing actuallyDr. Stephen Henson
supports it (yet).
2006-04-08Implement encrypt/decrypt using RSA.Dr. Stephen Henson
2006-04-07New utility 'pkeyutl' a general purpose version of 'rsautl'.Dr. Stephen Henson