public static void register(boolean newKeyAllowed) throws GeneralSecurityException {
    if (!TinkFipsUtil.AlgorithmFipsCompatibility.ALGORITHM_NOT_FIPS.isCompatible()) {
      throw new GeneralSecurityException(
          "Registering AES CTR HMAC Streaming AEAD is not supported in FIPS mode");
    }
    AesCtrHmacStreamingProtoSerialization.register();
    MutableParametersRegistry.globalInstance().putAll(namedParameters());
    MutableKeyCreationRegistry.globalInstance()
        .add(KEY_CREATOR, AesCtrHmacStreamingParameters.class);
    MutablePrimitiveRegistry.globalInstance()
        .registerPrimitiveConstructor(AES_CTR_HMAC_STREAMING_AEAD_PRIMITIVE_CONSTRUCTOR);
    KeyManagerRegistry.globalInstance().registerKeyManager(legacyKeyManager, newKeyAllowed);
  }
This key manager generates new {@code AesCtrHmacStreamingKey} keys and produces new instances of
{@code AesCtrHmacStreaming}.
java_src/src/main/java/com/google/crypto/tink/streamingaead/AesCtrHmacStreamingKeyManager.java