OpenCoverage

hash.c

Absolute File Name:/home/opencoverage/opencoverage/guest-scripts/openssh/src/hash.c
Source codeSwitch to Preprocessed file
LineSourceCount
1/* $OpenBSD: hash.c,v 1.4 2017/12/14 21:07:39 naddy Exp $ */-
2-
3/* $OpenBSD: hash.c,v 1.5 2018/01/13 00:24:09 naddy Exp $ */-
4/*-
5 * Public domain. Author: Christian Weisgerber <naddy@openbsd.org>-
6 * API compatible reimplementation of function from nacl-
7 */-
8-
9#include "crypto_api.h"-
10-
11#include <stdarg.h>-
12-
13#include "digest.h"-
14#include "log.h"-
15#include "ssherr.h"-
16-
17int-
18crypto_hash_sha512(unsigned char *out, const unsigned char *in,-
19 unsigned long long inlen)-
20{-
21 int r;-
22-
23 if ((r = ssh_digest_memory(SSH_DIGEST_SHA512, in, inlen, out,
(r = ssh_diges...ut, 64U)) != 0Description
TRUEnever evaluated
FALSEevaluated 14262 times by 3 tests
Evaluated by:
  • ssh-keygen
  • test_kex
  • test_sshkey
0-14262
24 crypto_hash_sha512_BYTES)) != 0)
(r = ssh_diges...ut, 64U)) != 0Description
TRUEnever evaluated
FALSEevaluated 14262 times by 3 tests
Evaluated by:
  • ssh-keygen
  • test_kex
  • test_sshkey
0-14262
25 fatal("%s: %s", __func__, ssh_err(r));
never executed: fatal("%s: %s", __func__, ssh_err(r));
0
26 return 0;
executed 14262 times by 3 tests: return 0;
Executed by:
  • ssh-keygen
  • test_kex
  • test_sshkey
14262
27}-
Source codeSwitch to Preprocessed file

Generated by Squish Coco 4.2.2