search for: ssh_digest_start

Displaying 2 results from an estimated 2 matches for "ssh_digest_start".

2015 Aug 05
2
[PATCH 1/1] uid for expansion in ControlPath
...,6 +1123,7 @@ main(int ac, char **av) strlcpy(shorthost, thishost, sizeof(shorthost)); shorthost[strcspn(thishost, ".")] = '\0'; snprintf(portstr, sizeof(portstr), "%d", options.port); + snprintf(uidstr, sizeof(uidstr), "%d", pw->pw_uid); if ((md = ssh_digest_start(SSH_DIGEST_SHA1)) == NULL || ssh_digest_update(md, thishost, strlen(thishost)) < 0 || @@ -1164,6 +1166,7 @@ main(int ac, char **av) "p", portstr, "r", options.user, "u", pw->pw_name, + "i", uidstr, (char *)NULL);...
2014 Apr 05
0
[PATCH] Use EVP_Digest
...t-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); + ret...