summaryrefslogtreecommitdiff
path: root/lib/fips.c
diff options
context:
space:
mode:
authorKurt Roeckx <kurt@roeckx.be>2014-04-19 19:46:18 +0200
committerNikos Mavrogiannopoulos <nmav@gnutls.org>2014-04-27 18:41:21 +0200
commitf31c5c6cf11b631425b43d8a7b94d40a6634fcca (patch)
tree4e4d78a82c1204b9e3a8ac1a5851ddf2dc19e904 /lib/fips.c
parent90a54379d1ae89fb8fc8424c76147d0170084506 (diff)
downloadgnutls-f31c5c6cf11b631425b43d8a7b94d40a6634fcca.tar.gz
Test for the existance of the /etc/system-fips file
We don't read it, the existance of the file is enough to say in what mode we are. Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
Diffstat (limited to 'lib/fips.c')
-rw-r--r--lib/fips.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/fips.c b/lib/fips.c
index 8cd4b94a2e..71f74926dc 100644
--- a/lib/fips.c
+++ b/lib/fips.c
@@ -59,7 +59,7 @@ static int fips_mode = -1;
else f1p = 0;
}
- f2p = !access(FIPS_SYSTEM_FILE, R_OK);
+ f2p = !access(FIPS_SYSTEM_FILE, F_OK);
if (f1p != 0 && f2p != 0) {
_gnutls_debug_log("FIPS140-2 mode enabled\n");