docs: public static void initializeFips() throws Exception {
          if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
              Tr.entry(tc, "initializeFips");
  
          if (!fipsInitialized) {
              int ibmjcefips_position = 0;
              Provider[] provider_list = null;
              Provider ibmjcefips = null;
              Provider sun = null;
  
              try {
                  System.setProperty("com.ibm.jsse2.JSSEFIPS", "true");
                  provider_list = Security.getProviders();
  
                  for (int i = 0; i < provider_list.length; i++) {
                      if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
                          Tr.debug(tc, "Provider[" + i + "]: " + provider_list[i].getName());
                      if (provider_list[i].getName().equals("IBMJCEFIPS")) {
                          ibmjcefips_position = i;
                          ibmjcefips = provider_list[i];
                      } else if (provider_list[i].getName().equals("SUN")) {
                          sun = provider_list[i];
                      }
                  }
  
                  if (ibmjcefips == null) {
                      provider_list = Security.getProviders();
  
                      try {
                          ibmjcefips = (Provider) Class.forName(Constants.IBMJCEFIPS).newInstance();
  
                          if (sun != null) {
                              insertProviderAt(sun, 1);
                              insertProviderAt(ibmjcefips, 2);
                          } else {
                              insertProviderAt(ibmjcefips, 1);
                          }
                      } catch (Exception e) {
                          if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
                              Tr.debug(tc, "Exception loading provider: " + Constants.IBMJCEFIPS + "; " + e);
                      }
                  } else if (ibmjcefips_position != 0) {
                      // it's there but not the first, let's reorder it.
                      provider_list = Security.getProviders();
  
                      if (sun != null) {
                          insertProviderAt(sun, 1);
                          insertProviderAt(ibmjcefips, 2);
                      } else {
                          insertProviderAt(ibmjcefips, 1);
                      }
                  }
  
                  provider_list = Security.getProviders();
  
                  if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
                      for (int i = 0; i < provider_list.length; i++) {
                          Tr.debug(tc, "Provider[" + i + "]: " + provider_list[i].getName() + ", info: " + provider_list[i].getInfo());
                      }
                  }
  
                  fipsInitialized = true;
              } catch (Exception e) {
                  Tr.error(tc, "security.addprovider.error", new Object[] { e });
                  if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
                      Tr.debug(tc, "Exception caught adding IBMJCEFIPS provider.", new Object[] { e });
                  throw e;
              }
          }
  
          if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
              Tr.exit(tc, "initializeFips");
      }