Make trust-root constant in SpecialNames

This commit is contained in:
Paul Schaub 2022-07-04 18:48:49 +02:00
parent 96b22ff40a
commit bc20b95839
Signed by: vanitasvitae
GPG key ID: 62BEE9264BF17311

View file

@ -9,11 +9,14 @@ import java.util.Map;
public class SpecialNames {
public static final String TRUST_ROOT = "trust-root";
// Map to allow for potentially upper- and lowercase variants of the same special name
private static final Map<String, String> SPECIAL_NAMES = new HashMap<>();
static {
SPECIAL_NAMES.put("TRUST-ROOT", "trust-root"); // TODO: Remove
SPECIAL_NAMES.put("trust-root", "trust-root");
SPECIAL_NAMES.put("TRUST-ROOT", TRUST_ROOT); // TODO: Remove
SPECIAL_NAMES.put(TRUST_ROOT, TRUST_ROOT);
}
public static String lookupSpecialName(String specialName) {