[gnutls-devel] [PATCH 1/3] Add _gnutls_fips_mode_enabled() return values.

Kurt Roeckx kurt at roeckx.be
Sat Apr 19 19:46:17 CEST 2014


---
 lib/fips.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/lib/fips.c b/lib/fips.c
index 1812610..8cd4b94 100644
--- a/lib/fips.c
+++ b/lib/fips.c
@@ -36,6 +36,11 @@ unsigned int _gnutls_lib_mode = LIB_STATE_POWERON;
 #define FIPS_KERNEL_FILE "/proc/sys/crypto/fips_enabled"
 #define FIPS_SYSTEM_FILE "/etc/system-fips"
 
+/* Returns:
+ * 0 - FIPS mode disabled
+ * 1 - FIPS mode enabled and enforced
+ * 2 - FIPS in testing mode
+ */
 unsigned _gnutls_fips_mode_enabled(void)
 {
 unsigned f1p = 0, f2p;
-- 
1.9.1




More information about the Gnutls-devel mailing list