1/*
2 * Copyright (c) 2000, 2013, 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
26package sun.security.util;
27
28/**
29 * This class represents the <code>ResourceBundle</code>
30 * for javax.security.auth and sun.security.
31 *
32 */
33public class Resources extends java.util.ListResourceBundle {
34
35    private static final Object[][] contents = {
36
37        // javax.security.auth.PrivateCredentialPermission
38        {"invalid.null.input.s.", "invalid null input(s)"},
39        {"actions.can.only.be.read.", "actions can only be 'read'"},
40        {"permission.name.name.syntax.invalid.",
41                "permission name [{0}] syntax invalid: "},
42        {"Credential.Class.not.followed.by.a.Principal.Class.and.Name",
43                "Credential Class not followed by a Principal Class and Name"},
44        {"Principal.Class.not.followed.by.a.Principal.Name",
45                "Principal Class not followed by a Principal Name"},
46        {"Principal.Name.must.be.surrounded.by.quotes",
47                "Principal Name must be surrounded by quotes"},
48        {"Principal.Name.missing.end.quote",
49                "Principal Name missing end quote"},
50        {"PrivateCredentialPermission.Principal.Class.can.not.be.a.wildcard.value.if.Principal.Name.is.not.a.wildcard.value",
51                "PrivateCredentialPermission Principal Class can not be a wildcard (*) value if Principal Name is not a wildcard (*) value"},
52        {"CredOwner.Principal.Class.class.Principal.Name.name",
53                "CredOwner:\n\tPrincipal Class = {0}\n\tPrincipal Name = {1}"},
54
55        // javax.security.auth.x500
56        {"provided.null.name", "provided null name"},
57        {"provided.null.keyword.map", "provided null keyword map"},
58        {"provided.null.OID.map", "provided null OID map"},
59
60        // javax.security.auth.Subject
61        {"NEWLINE", "\n"},
62        {"invalid.null.AccessControlContext.provided",
63                "invalid null AccessControlContext provided"},
64        {"invalid.null.action.provided", "invalid null action provided"},
65        {"invalid.null.Class.provided", "invalid null Class provided"},
66        {"Subject.", "Subject:\n"},
67        {".Principal.", "\tPrincipal: "},
68        {".Public.Credential.", "\tPublic Credential: "},
69        {".Private.Credentials.inaccessible.",
70                "\tPrivate Credentials inaccessible\n"},
71        {".Private.Credential.", "\tPrivate Credential: "},
72        {".Private.Credential.inaccessible.",
73                "\tPrivate Credential inaccessible\n"},
74        {"Subject.is.read.only", "Subject is read-only"},
75        {"attempting.to.add.an.object.which.is.not.an.instance.of.java.security.Principal.to.a.Subject.s.Principal.Set",
76                "attempting to add an object which is not an instance of java.security.Principal to a Subject's Principal Set"},
77        {"attempting.to.add.an.object.which.is.not.an.instance.of.class",
78                "attempting to add an object which is not an instance of {0}"},
79
80        // javax.security.auth.login.AppConfigurationEntry
81        {"LoginModuleControlFlag.", "LoginModuleControlFlag: "},
82
83        // javax.security.auth.login.LoginContext
84        {"Invalid.null.input.name", "Invalid null input: name"},
85        {"No.LoginModules.configured.for.name",
86         "No LoginModules configured for {0}"},
87        {"invalid.null.Subject.provided", "invalid null Subject provided"},
88        {"invalid.null.CallbackHandler.provided",
89                "invalid null CallbackHandler provided"},
90        {"null.subject.logout.called.before.login",
91                "null subject - logout called before login"},
92        {"unable.to.instantiate.LoginModule.module.because.it.does.not.provide.a.no.argument.constructor",
93                "unable to instantiate LoginModule, {0}, because it does not provide a no-argument constructor"},
94        {"unable.to.instantiate.LoginModule",
95                "unable to instantiate LoginModule"},
96        {"unable.to.instantiate.LoginModule.",
97                "unable to instantiate LoginModule: "},
98        {"unable.to.find.LoginModule.class.",
99                "unable to find LoginModule class: "},
100        {"unable.to.access.LoginModule.",
101                "unable to access LoginModule: "},
102        {"Login.Failure.all.modules.ignored",
103                "Login Failure: all modules ignored"},
104
105        // sun.security.provider.PolicyFile
106
107        {"java.security.policy.error.parsing.policy.message",
108                "java.security.policy: error parsing {0}:\n\t{1}"},
109        {"java.security.policy.error.adding.Permission.perm.message",
110                "java.security.policy: error adding Permission, {0}:\n\t{1}"},
111        {"java.security.policy.error.adding.Entry.message",
112                "java.security.policy: error adding Entry:\n\t{0}"},
113        {"alias.name.not.provided.pe.name.", "alias name not provided ({0})"},
114        {"unable.to.perform.substitution.on.alias.suffix",
115                "unable to perform substitution on alias, {0}"},
116        {"substitution.value.prefix.unsupported",
117                "substitution value, {0}, unsupported"},
118        {"LPARAM", "("},
119        {"RPARAM", ")"},
120        {"type.can.t.be.null","type can't be null"},
121
122        // sun.security.provider.PolicyParser
123        {"keystorePasswordURL.can.not.be.specified.without.also.specifying.keystore",
124                "keystorePasswordURL can not be specified without also specifying keystore"},
125        {"expected.keystore.type", "expected keystore type"},
126        {"expected.keystore.provider", "expected keystore provider"},
127        {"multiple.Codebase.expressions",
128                "multiple Codebase expressions"},
129        {"multiple.SignedBy.expressions","multiple SignedBy expressions"},
130        {"duplicate.keystore.domain.name","duplicate keystore domain name: {0}"},
131        {"duplicate.keystore.name","duplicate keystore name: {0}"},
132        {"SignedBy.has.empty.alias","SignedBy has empty alias"},
133        {"can.not.specify.Principal.with.a.wildcard.class.without.a.wildcard.name",
134                "can not specify Principal with a wildcard class without a wildcard name"},
135        {"expected.codeBase.or.SignedBy.or.Principal",
136                "expected codeBase or SignedBy or Principal"},
137        {"expected.permission.entry", "expected permission entry"},
138        {"number.", "number "},
139        {"expected.expect.read.end.of.file.",
140                "expected [{0}], read [end of file]"},
141        {"expected.read.end.of.file.",
142                "expected [;], read [end of file]"},
143        {"line.number.msg", "line {0}: {1}"},
144        {"line.number.expected.expect.found.actual.",
145                "line {0}: expected [{1}], found [{2}]"},
146        {"null.principalClass.or.principalName",
147                "null principalClass or principalName"},
148
149        // sun.security.pkcs11.SunPKCS11
150        {"PKCS11.Token.providerName.Password.",
151                "PKCS11 Token [{0}] Password: "},
152
153        /* --- DEPRECATED --- */
154        // javax.security.auth.Policy
155        {"unable.to.instantiate.Subject.based.policy",
156                "unable to instantiate Subject-based policy"}
157    };
158
159
160    /**
161     * Returns the contents of this <code>ResourceBundle</code>.
162     *
163     * @return the contents of this <code>ResourceBundle</code>.
164     */
165    @Override
166    public Object[][] getContents() {
167        return contents;
168    }
169}
170
171