diff options
author | Christian Beier <dontmind@freeshell.org> | 2018-06-29 12:30:17 +0200 |
---|---|---|
committer | Christian Beier <dontmind@freeshell.org> | 2018-06-29 12:30:17 +0200 |
commit | 85fb69515cf1739bea53ce62b832a17e08ab3647 (patch) | |
tree | 0b4bb1faf2f1ae9d0ed67d36cf119a1b50f7475e /libvncserver/rfbcrypto_polarssl.c | |
parent | 161e7cab026dd89dacd85208b74834cc4c509f72 (diff) | |
download | libtdevnc-85fb69515cf1739bea53ce62b832a17e08ab3647.tar.gz libtdevnc-85fb69515cf1739bea53ce62b832a17e08ab3647.zip |
crypto: move to common
As of now, only LibVNCServer makes uses of these digest functions _and_
they depend on sys/uio.h, but in the future LibVNCClient will need those
as well.
Diffstat (limited to 'libvncserver/rfbcrypto_polarssl.c')
-rw-r--r-- | libvncserver/rfbcrypto_polarssl.c | 26 |
1 files changed, 0 insertions, 26 deletions
diff --git a/libvncserver/rfbcrypto_polarssl.c b/libvncserver/rfbcrypto_polarssl.c deleted file mode 100644 index 55e3a7b..0000000 --- a/libvncserver/rfbcrypto_polarssl.c +++ /dev/null @@ -1,26 +0,0 @@ -#include <string.h> -#include <polarssl/md5.h> -#include <polarssl/sha1.h> -#include "rfbcrypto.h" - -void digestmd5(const struct iovec *iov, int iovcnt, void *dest) -{ - md5_context c; - int i; - - md5_starts(&c); - for (i = 0; i < iovcnt; i++) - md5_update(&c, iov[i].iov_base, iov[i].iov_len); - md5_finish(&c, dest); -} - -void digestsha1(const struct iovec *iov, int iovcnt, void *dest) -{ - sha1_context c; - int i; - - sha1_starts(&c); - for (i = 0; i < iovcnt; i++) - sha1_update(&c, iov[i].iov_base, iov[i].iov_len); - sha1_finish(&c, dest); -} |