blob: 8550ac9c2a284c987bc8b689c2af9126a504586a [file] [log] [blame]
J. Duke319a3b92007-12-01 00:00:00 +00001/*
2 * Copyright 2000-2004 Sun Microsystems, Inc. All Rights Reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
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
7 * published by the Free Software Foundation. Sun designates this
8 * particular file as subject to the "Classpath" exception as provided
9 * by Sun in the LICENSE file that accompanied this code.
10 *
11 * This code is distributed in the hope that it will be useful, but WITHOUT
12 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14 * version 2 for more details (a copy is included in the LICENSE file that
15 * accompanied this code).
16 *
17 * You should have received a copy of the GNU General Public License version
18 * 2 along with this work; if not, write to the Free Software Foundation,
19 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
20 *
21 * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
22 * CA 95054 USA or visit www.sun.com if you need additional information or
23 * have any questions.
24 */
25
26/*
27 * NOTE: this file was copied from javax.net.ssl.SSLContextSpi
28 */
29
30package com.sun.net.ssl;
31
32import java.util.*;
33import java.security.*;
34import javax.net.ssl.*;
35
36/**
37 * This class defines the <i>Service Provider Interface</i> (<b>SPI</b>)
38 * for the <code>SSLContext</code> class.
39 *
40 * <p> All the abstract methods in this class must be implemented by each
41 * cryptographic service provider who wishes to supply the implementation
42 * of a particular SSL context.
43 *
44 * @deprecated As of JDK 1.4, this implementation-specific class was
45 * replaced by {@link javax.net.ssl.SSLContextSpi}.
46 */
47@Deprecated
48public abstract class SSLContextSpi {
49 /**
50 * Initializes this context.
51 *
52 * @param km the sources of authentication keys
53 * @param tm the sources of peer authentication trust decisions
54 * @param random the source of randomness for this generator
55 */
56 protected abstract void engineInit(KeyManager[] ah, TrustManager[] th,
57 SecureRandom sr) throws KeyManagementException;
58
59 /**
60 * Returns a <code>SocketFactory</code> object for this
61 * context.
62 *
63 * @return the factory
64 */
65 protected abstract SSLSocketFactory engineGetSocketFactory();
66
67 /**
68 * Returns a <code>ServerSocketFactory</code> object for
69 * this context.
70 *
71 * @return the factory
72 */
73 protected abstract SSLServerSocketFactory engineGetServerSocketFactory();
74}