8332086: Remove the usage of ServiceLoader in j.u.r.RandomGeneratorFactory

8332476: j.u.r.RandomGeneratorFactor.create(long|byte[]) should throw rather than silently fallback to no-arg create()

Reviewed-by: jpai
This commit is contained in:
Raffaello Giulietti 2024-05-21 12:53:03 +00:00
parent 5cf8288b80
commit 42e3c842ae
19 changed files with 337 additions and 397 deletions

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 1996, 2023, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1996, 2024, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@ -25,7 +25,6 @@
package java.security;
import jdk.internal.util.random.RandomSupport.RandomGeneratorProperties;
import sun.security.jca.GetInstance;
import sun.security.jca.GetInstance.Instance;
import sun.security.jca.Providers;
@ -149,10 +148,6 @@ import java.util.regex.Pattern;
* @since 1.1
*/
@RandomGeneratorProperties(
name = "SecureRandom",
isStochastic = true
)
public class SecureRandom extends java.util.Random {
private static final Debug pdebug =