History

My first initial commit with all of mine experimental changes.

Dmitry Kabak (userdima committed 13 years ago

Commit d37b88d1 parent 3f5b46618352 files · +2598093 −-8690Browse files

Showing the changes to java/pkg/com/sun/net/ssl/SSLPermission.java (1 of 18352 files). Show all

Unified · Split

java/pkg/com/sun/net/ssl/SSLPermission.java+137−0
@@ -0,0 +1,137 @@
1+/*
2+ * Copyright (c) 2000, 2004, Oracle and/or its affiliates. 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. Oracle designates this
8+ * particular file as subject to the "Classpath" exception as provided
9+ * by Oracle 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 Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
22+ * or visit www.oracle.com if you need additional information or have any
23+ * questions.
24+ */
25+
26+/*
27+ * NOTE: this file was copied from javax.net.ssl.SSLPermission
28+ */
29+
30+package com.sun.net.ssl;
31+
32+import java.security.*;
33+import java.util.Enumeration;
34+import java.util.Hashtable;
35+import java.util.StringTokenizer;
36+import java.security.Permissions;
37+import java.lang.SecurityManager;
38+
39+/**
40+ * This class is for various network permissions.
41+ * An SSLPermission contains a name (also referred to as a "target name") but
42+ * no actions list; you either have the named permission
43+ * or you don't.
44+ * <P>
45+ * The target name is the name of the network permission (see below). The naming
46+ * convention follows the hierarchical property naming convention.
47+ * Also, an asterisk
48+ * may appear at the end of the name, following a ".", or by itself, to
49+ * signify a wildcard match. For example: "foo.*" or "*" is valid,
50+ * "*foo" or "a*b" is not valid.
51+ * <P>
52+ * The following table lists all the possible SSLPermission target names,
53+ * and for each provides a description of what the permission allows
54+ * and a discussion of the risks of granting code the permission.
55+ * <P>
56+ *
57+ * <table border=1 cellpadding=5>
58+ * <tr>
59+ * <th>Permission Target Name</th>
60+ * <th>What the Permission Allows</th>
61+ * <th>Risks of Allowing this Permission</th>
62+ * </tr>
63+ *
64+ * <tr>
65+ * <td>setHostnameVerifier</td>
66+ * <td>The ability to set a callback which can decide whether to
67+ * allow a mismatch between the host being connected to by
68+ * an HttpsURLConnection and the common name field in
69+ * server certificate.
70+ * </td>
71+ * <td>Malicious
72+ * code can set a verifier that monitors host names visited by
73+ * HttpsURLConnection requests or that allows server certificates
74+ * with invalid common names.
75+ * </td>
76+ * </tr>
77+ *
78+ * <tr>
79+ * <td>getSSLSessionContext</td>
80+ * <td>The ability to get the SSLSessionContext of an SSLSession.
81+ * </td>
82+ * <td>Malicious code may monitor sessions which have been established
83+ * with SSL peers or might invalidate sessions to slow down performance.
84+ * </td>
85+ * </tr>
86+ *
87+ * </table>
88+ *
89+ * @see java.security.BasicPermission
90+ * @see java.security.Permission
91+ * @see java.security.Permissions
92+ * @see java.security.PermissionCollection
93+ * @see java.lang.SecurityManager
94+ *
95+ *
96+ * @author Marianne Mueller
97+ * @author Roland Schemers
98+ *
99+ * @deprecated As of JDK 1.4, this implementation-specific class was
100+ * replaced by {@link javax.net.ssl.SSLPermission}.
101+ */
102+@Deprecated
103+public final class SSLPermission extends BasicPermission {
104+
105+ private static final long serialVersionUID = -2583684302506167542L;
106+
107+ /**
108+ * Creates a new SSLPermission with the specified name.
109+ * The name is the symbolic name of the SSLPermission, such as
110+ * "setDefaultAuthenticator", etc. An asterisk
111+ * may appear at the end of the name, following a ".", or by itself, to
112+ * signify a wildcard match.
113+ *
114+ * @param name the name of the SSLPermission.
115+ */
116+
117+ public SSLPermission(String name)
118+ {
119+ super(name);
120+ }
121+
122+ /**
123+ * Creates a new SSLPermission object with the specified name.
124+ * The name is the symbolic name of the SSLPermission, and the
125+ * actions String is currently unused and should be null. This
126+ * constructor exists for use by the <code>Policy</code> object
127+ * to instantiate new Permission objects.
128+ *
129+ * @param name the name of the SSLPermission.
130+ * @param actions should be null.
131+ */
132+
133+ public SSLPermission(String name, String actions)
134+ {
135+ super(name, actions);
136+ }
137+}

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t