@Override
    public void afterRegistration(final AfterRegistrationAccess access) {
        try {
            log("Registering BouncyCastle security provider");
            RuntimeClassInitialization.initializeAtBuildTime("org.bouncycastle");
        } catch (final Throwable e) {
            log("Unable to register BouncyCastle security provider: " + e.getMessage());
        } finally {
            Security.addProvider(new BouncyCastleProvider());
        }
    }
This is {@link DefaultNativeImageFeature}.

@author Misagh Moayyed
@since 7.0.0
support/cas-server-support-native/src/main/java/org/apereo/cas/nativex/features/DefaultNativeImageFeature.java