mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 07:14:30 +02:00
8242151: Improve OID mapping and reuse among JDK security providers for aliases registration
Use sun.security.util.KnownOIDs enum instead of hardcoding oid strings everywhere Reviewed-by: weijun
This commit is contained in:
parent
a97932d8fc
commit
080b3b83eb
79 changed files with 2016 additions and 2080 deletions
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2016, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2016, 2020, 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
|
||||
|
@ -153,7 +153,7 @@ public class ConstraintsParameters {
|
|||
public static String[] getNamedCurveFromKey(Key key) {
|
||||
if (key instanceof ECKey) {
|
||||
NamedCurve nc = CurveDB.lookup(((ECKey)key).getParams());
|
||||
return (nc == null ? EMPTYLIST : CurveDB.getNamesByOID(nc.getObjectId()));
|
||||
return (nc == null ? EMPTYLIST : nc.getNameAndAliases());
|
||||
} else if (key instanceof XECKey) {
|
||||
String[] s = {
|
||||
((NamedParameterSpec)((XECKey)key).getParams()).getName()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue