jdk/src/share/classes/sun/security/x509/X509Key.java
changeset 10336 0bb1999251f8
parent 7668 d4a77089c587
child 19375 cdfdb9c0590e
equal deleted inserted replaced
10335:3c7eda3ab2f5 10336:0bb1999251f8
     1 /*
     1 /*
     2  * Copyright (c) 1996, 2010, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 1996, 2011, Oracle and/or its affiliates. All rights reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.  Oracle designates this
     7  * published by the Free Software Foundation.  Oracle designates this
    29 import java.util.Arrays;
    29 import java.util.Arrays;
    30 import java.util.Properties;
    30 import java.util.Properties;
    31 import java.security.Key;
    31 import java.security.Key;
    32 import java.security.PublicKey;
    32 import java.security.PublicKey;
    33 import java.security.KeyFactory;
    33 import java.security.KeyFactory;
    34 import java.security.KeyRep;
       
    35 import java.security.Security;
    34 import java.security.Security;
    36 import java.security.Provider;
    35 import java.security.Provider;
    37 import java.security.InvalidKeyException;
    36 import java.security.InvalidKeyException;
    38 import java.security.NoSuchAlgorithmException;
    37 import java.security.NoSuchAlgorithmException;
    39 import java.security.spec.InvalidKeySpecException;
    38 import java.security.spec.InvalidKeySpecException;
   243               algid.getName());
   242               algid.getName());
   244             if (classname == null) {
   243             if (classname == null) {
   245                 throw new InstantiationException();
   244                 throw new InstantiationException();
   246             }
   245             }
   247 
   246 
   248             Class keyClass = null;
   247             Class<?> keyClass = null;
   249             try {
   248             try {
   250                 keyClass = Class.forName(classname);
   249                 keyClass = Class.forName(classname);
   251             } catch (ClassNotFoundException e) {
   250             } catch (ClassNotFoundException e) {
   252                 ClassLoader cl = ClassLoader.getSystemClassLoader();
   251                 ClassLoader cl = ClassLoader.getSystemClassLoader();
   253                 if (cl != null) {
   252                 if (cl != null) {