Bugzilla – Attachment 2428 Details for
Bug 2231
Use EVP_Digest for oneshot digest calculation
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
suggested patch
file_2231.txt (text/plain), 707 bytes, created by
Timo Teräs
on 2014-04-18 17:43:07 AEST
(
hide
)
Description:
suggested patch
Filename:
MIME Type:
Creator:
Timo Teräs
Created:
2014-04-18 17:43:07 AEST
Size:
707 bytes
patch
obsolete
> >diff -ru openssh-6.6p1.orig/digest-openssl.c openssh-6.6p1/digest-openssl.c >--- openssh-6.6p1.orig/digest-openssl.c 2014-02-04 02:25:45.000000000 +0200 >+++ openssh-6.6p1/digest-openssl.c 2014-04-04 17:00:29.548457919 +0300 >@@ -148,14 +148,11 @@ > int > ssh_digest_memory(int alg, const void *m, size_t mlen, u_char *d, size_t dlen) > { >- struct ssh_digest_ctx *ctx = ssh_digest_start(alg); >+ const struct ssh_digest *digest = ssh_digest_by_alg(alg); > >- if (ctx == NULL) >+ if (!EVP_Digest(m, mlen, d, dlen, digest->mdfunc(), NULL)) > return -1; >- if (ssh_digest_update(ctx, m, mlen) != 0 || >- ssh_digest_final(ctx, d, dlen) != 0) >- return -1; >- ssh_digest_free(ctx); >+ > return 0; > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 2231
: 2428