KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > javax > net > ssl > X509ExtendedKeyManager


1 /*
2  * @(#)X509ExtendedKeyManager.java 1.2 04/02/16
3  *
4  * Copyright (c) 2004 Sun Microsystems, Inc. All Rights Reserved.
5  * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
6  */

7   
8 /*
9  * NOTE:
10  * Because of various external restrictions (i.e. US export
11  * regulations, etc.), the actual source code can not be provided
12  * at this time. This file represents the skeleton of the source
13  * file, so that javadocs of the API can be created.
14  */

15
16 package javax.net.ssl;
17
18 import java.security.Principal;
19
20 /**
21  * Abstract class that provides for extension of the X509KeyManager
22  * interface.
23  * <P>
24  * Methods in this class should be overriden to provide actual
25  * implementations.
26  *
27  * @since 1.5
28  * @version 1.1
29  * @author Brad R. Wetmore
30  */

31 public abstract class X509ExtendedKeyManager implements X509KeyManager
32 {
33
34     /**
35      * Constructor used by subclasses only.
36      */

37     protected X509ExtendedKeyManager() { }
38
39     /**
40      * Choose an alias to authenticate the client side of an
41      * <code>SSLEngine</code> connection given the public key type
42      * and the list of certificate issuer authorities recognized by
43      * the peer (if any).
44      * <P>
45      * The default implementation returns null.
46      *
47      * @param keyType the key algorithm type name(s), ordered
48      * with the most-preferred key type first.
49      * @param issuers the list of acceptable CA issuer subject names
50      * or null if it does not matter which issuers are used.
51      * @param engine the <code>SSLEngine</code> to be used for this
52      * connection. This parameter can be null, which indicates
53      * that implementations of this interface are free to
54      * select an alias applicable to any engine.
55      * @return the alias name for the desired key, or null if there
56      * are no matches.
57      */

58     public String chooseEngineClientAlias(String[] keyType, Principal[] issuers,
59         SSLEngine engine)
60     {
61         return null;
62     }
63
64     /**
65      * Choose an alias to authenticate the server side of an
66      * <code>SSLEngine</code> connection given the public key type
67      * and the list of certificate issuer authorities recognized by
68      * the peer (if any).
69      * <P>
70      * The default implementation returns null.
71      *
72      * @param keyType the key algorithm type name.
73      * @param issuers the list of acceptable CA issuer subject names
74      * or null if it does not matter which issuers are used.
75      * @param engine the <code>SSLEngine</code> to be used for this
76      * connection. This parameter can be null, which indicates
77      * that implementations of this interface are free to
78      * select an alias applicable to any engine.
79      * @return the alias name for the desired key, or null if there
80      * are no matches.
81      */

82     public String chooseEngineServerAlias(String keyType, Principal[] issuers,
83         SSLEngine engine)
84     {
85         return null;
86     }
87 }
88
Popular Tags