Reserve control code for FIPS extensions.
authorWerner Koch <wk@gnupg.org>
Wed, 29 Jan 2014 09:44:36 +0000 (10:44 +0100)
committerWerner Koch <wk@gnupg.org>
Wed, 29 Jan 2014 09:47:20 +0000 (10:47 +0100)
* src/gcrypt.h.in (GCRYCTL_INACTIVATE_FIPS_FLAG): New.
(GCRYCTL_REACTIVATE_FIPS_FLAG): New.
* src/global.c (_gcry_vcontrol): Add them but return not_implemented.

src/gcrypt.h.in
src/global.c

index b06f259..c84a3f7 100644 (file)
@@ -327,7 +327,9 @@ enum gcry_ctl_cmds
     GCRYCTL_DISABLE_LOCKED_SECMEM = 67,
     GCRYCTL_DISABLE_PRIV_DROP = 68,
     GCRYCTL_SET_CCM_LENGTHS = 69,
-    GCRYCTL_CLOSE_RANDOM_DEVICE = 70
+    GCRYCTL_CLOSE_RANDOM_DEVICE = 70,
+    GCRYCTL_INACTIVATE_FIPS_FLAG = 71,
+    GCRYCTL_REACTIVATE_FIPS_FLAG = 72
   };
 
 /* Perform various operations defined by CMD. */
index ec0cc3f..4e8df86 100644 (file)
@@ -666,6 +666,11 @@ _gcry_vcontrol (enum gcry_ctl_cmds cmd, va_list arg_ptr)
                               | GCRY_SECMEM_FLAG_NO_PRIV_DROP));
       break;
 
+    case GCRYCTL_INACTIVATE_FIPS_FLAG:
+    case GCRYCTL_REACTIVATE_FIPS_FLAG:
+      rc = GPG_ERR_NOT_IMPLEMENTED;
+      break;
+
     default:
       _gcry_set_preferred_rng_type (0);
       rc = GPG_ERR_INV_OP;