[RFC] FIPS compliance and other crypt(3) improvements

Roland McGrath roland@hack.frob.com
Tue May 15 17:19:00 GMT 2012


ENOSYS is the error code for a function that is entirely unimplemented.
For this case, ENOTSUP is a better fit.

-  if(s[0] == __data->current_salt[0] && s[1] == __data->current_salt[1])
-    return;
+  if(s0 != __data->current_salt[0] && s1 == __data->current_salt[1])
+    return 0;

Looks like the first test got inverted.

Is there any standard or precedent for _SC_CRYPTO_FIPS_ENABLED?
We should not take lightly adding this to the public API/ABI.

If the only need for it is an internal one, then the check can be done
using internal functions only.


Thanks,
Roland



More information about the Libc-alpha mailing list