I am having difficulty understanding the differences between bc-prov and bc-fips jar. I understand bc-fips contains the subset of bc-prov packages as well. But I want to understand more about the below questions,

  1. Will there be any performance impact upgrading to bc-fips jar provided I still use the same algorithm, key length, iv length, block modes, etc.?? This is a key factor in upgrading to the bc-fips jar.
  2. Is running bc-fips in non-approved mode equivalent to using bc-prov jar? I mean, in terms of the functionals APIs coverage, performance, backward compatibility, etc.?
  3. Why can bc-prov and bc-fips not co-exist together? Because of this, it will be hard for legacy apps to migrate to bc-fips for FIPS compliance easily.
  4. Is there any upgrade guide for migrating to bc-fips from bc-prov for legacy applications?

1 Answer 1

  1. You haven't provided any details of what your program does and how encryption-intensive it is. I'd be surprised if moving to FIPS didn't impact your application, but you won't know until you test.

  2. At a high-level view, probably. You won't know what is affected until you test it. It's not clear why it matters. Using bc-fips in non-approved mode is not FIPS compliant.

  3. According to this post, Fips and non-fips bc jars co-existence, it is possible to use both libraries in what's called the org.spongycastle approach. You are not FIPS compliant if you use the crypto classes from bp-prov. The gist of spongycastle is:

Recompile the API as org.spongycastle and give the provider the name "SC" rather than "BC".

  1. I didn't find much on this from a cursory search. This Keycloak page has tips for moving Keycloak from a non-fips to a fips environment. Migration from non-fips environment

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .