fe79785559
Bug fixes for bsc#1175277, bsc#1175356, and bsc#1175357 OBS-URL: https://build.opensuse.org/request/show/834746 OBS-URL: https://build.opensuse.org/package/show/devel:openSUSE:Factory/libica?expand=0&rev=44
32 lines
757 B
Diff
32 lines
757 B
Diff
From 8acba8fc09a91831172658c9c0810aa45ab39245 Mon Sep 17 00:00:00 2001
|
|
From: Michal Suchanek <msuchanek@suse.de>
|
|
Date: Tue, 1 Sep 2020 10:03:38 +0200
|
|
Subject: [PATCH] FIPS: fix inconsistent error handling.
|
|
|
|
when the HMAC file is not present/readable it is also an error.
|
|
|
|
Signed-off-by: Michal Suchanek <msuchanek@suse.de>
|
|
---
|
|
src/fips.c | 4 +---
|
|
1 file changed, 1 insertion(+), 3 deletions(-)
|
|
|
|
diff --git a/src/fips.c b/src/fips.c
|
|
index c0055b719bff..71a417e8de40 100644
|
|
--- a/src/fips.c
|
|
+++ b/src/fips.c
|
|
@@ -295,10 +295,8 @@ static int FIPSCHECK_verify(const char *path)
|
|
return 0;
|
|
|
|
fp = fopen(hmacpath, "r");
|
|
- if (fp == NULL) {
|
|
- rc = 1;
|
|
+ if (fp == NULL)
|
|
goto end;
|
|
- }
|
|
|
|
if (getline(&known_hmac_str, &n, fp) <= 0)
|
|
goto end;
|
|
--
|
|
2.28.0
|
|
|