Move RSA key loading and decryption functions to wsutil
authorAhmad Fatoum <ahmad@a3f.at>
Wed, 26 Apr 2017 05:33:25 +0000 (07:33 +0200)
committerMichael Mann <mmann78@netscape.net>
Mon, 5 Jun 2017 23:43:03 +0000 (23:43 +0000)
commit502cc61711173273ffb8be2cf895f5e79c3b47bc
tree53db680580f3ca6a56461908330b9a30218a1449
parent1b228df643121ab2fabde34226701b9cd92401be
Move RSA key loading and decryption functions to wsutil

Loading PEM and PKCS#11 keys was being done in static functions
in packet-ssl-utils.c. These were moved to wsutil, with prototypes
in a new <wsutil/rsa.h> header. This adds gnutls as optional
dependency to wsutil.

The RSA decryption helper was also moved and is now provided in
<wsutil/wsgcrypt.h>.

This allows more dissectors to access this functionality.

Change-Id: I6cfbbf5203f2881c82bad721747834ccd76e2033
Reviewed-on: https://code.wireshark.org/review/21941
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Petri-Dish: Peter Wu <peter@lekensteyn.nl>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
debian/libwsutil0.symbols
epan/dissectors/packet-dtls.c
epan/dissectors/packet-ssl-utils.c
epan/dissectors/packet-ssl.c
wsutil/CMakeLists.txt
wsutil/Makefile.am
wsutil/rsa.c [new file with mode: 0644]
wsutil/rsa.h [new file with mode: 0644]
wsutil/wsgcrypt.c
wsutil/wsgcrypt.h