summaryrefslogtreecommitdiff
path: root/TAO/orbsvcs/orbsvcs/SL3TLS.idl
blob: c5701351e1101adbc83a59251036d6d581b049ed (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
//tabstop=4
//***********************************************************************
// ORBAsec SL3
// ----------------------------------------------------------------------
// Copyright (C) 2001 Adiron, LLC.
//                    All rights reserved.
// ----------------------------------------------------------------------
// $Id$
//***********************************************************************
#ifndef _SL3TLS_IDL_
#define _SL3TLS_IDL_
#include <orb.idl>
#include <SL3/SecurityLevel3.idl>
#include <SL3/TransportSecurity.idl>
#include <SL3/SL3AQArgs.idl>
#include <SL3/SL3TCPIP.idl>

#pragma prefix "adiron.com"

module SL3TLS {
    const TransportSecurity::MechanismId       MID_TLS  = "TLS";

    /**
     * This is the only acquisition mechanism for acquiring TLS
     * Transport Credentials.
     */
    const TransportSecurity::AcquisitionMethod AQM_TLSArgs = "TLSArgs";

    /**
     * Implementers may create their own local version of
     * this interface to verify chains of X509 Certificates.
     */
    local interface TLSX509IdentityVerifier {

        /**
         * This operation is called by the security service at the
         * TLS Transport Credentials creation phase to add certificates
         * as trusted entities directed by other TLS options.
         */
        void add_trusted_authority(
            in SecurityLevel3::X509IdentityStatement auth
        );

        /**
         * This operation is called by the security service to determine
         * if the peer is allowed to be anonymous. This means that the
         * peer has not delivered a certificate and did not authenticate
         * itself.
         */
        boolean is_anonymous_allowed();

        /**
         * This operation is called by the security service at the
         * transport authentication phase, when the peer certificate
         * needs to be verified. The X509IdentityStatement will contain
         * a sequence of encoded X509 Certificates, which may be empty.
         */
        boolean verify(
            in SecurityLevel3::X509IdentityStatement ident
        );
    };

    /**
     * The TLS KeyStore Acquisition Builder extends the TCPIP
     * Builder. This is because the same TCPIP Acquisition Arguments
     * apply to TLS, as TCPIP sits underneath TLS.
     */
    local interface TLSKeyStoreArgBuilder : SL3TCPIP::TCPIPArgBuilder {

        /**
         * This operation adds a X509 Certificate Chain Identity Verifier
         * argument to the acquisition arguments.
         *
         * @param verifier The locally defined interface that will verify
         *                 the certificate chain.
         */
        void addTLSX509IdentityVerifier(
            in TLSX509IdentityVerifier verifier
        );

        /**
         * This operation is used when there is a password on
         * the keystore.
         *
         * @param keystore  This argument contains the URL of the
         *                  keystore.
         * @param storetype This argument contains the type of the
         *                  keystore. Currently, one of "IAIKKeyStore"
         *                  or "jks".
         * @param storepass This is the password that protects the
         *                  key store.
         * @param keyalias  This argument contains the alias of a private
         *                  key in the keystore. If this argument is
         *                  an empty string, then the credentials will
         *                  be considered anonymous.
         * @param keypass   This argument contains the password that
         *                  unlocks the private key named by the keyalias.
         * @param trusted_cert_names
         *                  This argument contains the alias of certificates
         *                  in the key store that are considered trusted
         *                  to verify certificates of the peer during
         *                  authentication. A empty string sequence signifies
         *                  that the default chain verifier will accept
         *                  chains ending in any trusted certificate
         *                  entry found in the keystore.
         * <p>
         * Note: On the default TLSX509IdentityVerifier, anonymous
         * communication is always allowed.
         */
        void addTLSKeyStoreWithStorePass(
            in string           keystore,
            in string           storetype,
            in string           storepass,
            in string           keyalias,
            in string           keypass,
            in CORBA::StringSeq trusted_cert_names
        );

        /**
         * This operation is used when there is no password on
         * the keystore. This approach should only be used in
         * cases where the integrity of the keystore is not an issue.
         *
         * @param keystore  This argument contains the URL of the
         *                  keystore.
         * @param storetype This argument contains the type of the
         *                  keystore. Currently, one of "IAIKKeyStore"
         *                  or "jks".
         * @param keyalias  This argument contains the alias of a private
         *                  key in the keystore. If this argument is
         *                  an empty string, then the credentials will
         *                  be considered anonymous.
         * @param keypass   This argument contains the password that
         *                  unlocks the private key named by the keyalias.
         * @param trusted_cert_names
         *                  This argument contains the alias of certificates
         *                  in the key store that are considered trusted
         *                  to verify certificates of the peer during
         *                  authentication. A empty string sequence signifies
         *                  that the default chain verifier will accept
         *                  chains ending in any trusted certificate
         *                  entry found in the keystore.
         * <p>
         * Note: On the default TLSX509IdentityVerifier, anonymous
         * communication is always allowed.
         */
        void addTLSKeyStoreNoStorePass(
            in string           keystore,
            in string           storetype,
            in string           keyalias,
            in string           keypass,
            in CORBA::StringSeq trusted_cert_names
        );

        /**
         * This operation is used when there is a password on
         * the keystore.
         *
         * @param keystore  This argument contains the octet
         *                  sequence containing the keystore.
         * @param storetype This argument contains the type of the
         *                  keystore. Currently, one of "IAIKKeyStore"
         *                  or "jks".
         * @param storepass This is the password that protects the
         *                  key store.
         * @param keyalias  This argument contains the alias of a private
         *                  key in the keystore. If this argument is
         *                  an empty string, then the credentials will
         *                  be considered anonymous.
         * @param keypass   This argument contains the password that
         *                  unlocks the private key named by the keyalias.
         * @param trusted_cert_names
         *                  This argument contains the alias of certificates
         *                  in the key store that are considered trusted
         *                  to verify certificates of the peer during
         *                  authentication. A empty string sequence signifies
         *                  that the default chain verifier will accept
         *                  chains ending in any trusted certificate
         *                  entry found in the keystore.
         * <p>
         * Note: On the default TLSX509IdentityVerifier, anonymous
         * communication is always allowed.
         */
        void addTLSEncodedKeyStoreWithStorePass(
            in CORBA::OctetSeq  keystore,
            in string           storetype,
            in string           storepass,
            in string           keyalias,
            in string           keypass,
            in CORBA::StringSeq trusted_cert_names
        );

        /**
         * This operation is used when there is no password on
         * the keystore. This approach should only be used in
         * cases where the integrity of the keystore is not an issue.
         *
         * @param keystore  This argument contains the octet
         *                  sequence containing the keystore.
         * @param storetype This argument contains the type of the
         *                  keystore. Currently, one of "IAIKKeyStore"
         *                  or "jks".
         * @param keyalias  This argument contains the alias of a private
         *                  key in the keystore. If this argument is
         *                  an empty string, then the credentials will
         *                  be considered anonymous.
         * @param keypass   This argument contains the password that
         *                  unlocks the private key named by the keyalias.
         * @param trusted_cert_names
         *                  This argument contains the alias of certificates
         *                  in the key store that are considered trusted
         *                  to verify certificates of the peer during
         *                  authentication. A empty string sequence signifies
         *                  that the default chain verifier will accept
         *                  chains ending in any trusted certificate
         *                  entry found in the keystore.
         * <p>
         * Note: On the default TLSX509IdentityVerifier, anonymous
         * communication is always allowed.
         */
        void addTLSEncodedKeyStoreNoStorePass(
            in CORBA::OctetSeq  keystore,
            in string           storetype,
            in string           keyalias,
            in string           keypass,
            in CORBA::StringSeq trusted_cert_names
        );
    };

    /**
     * This acquisition mechanism specifies getting TLS credential
     * information from a Java KeyStore file. The Argument Factory
     * and Builder inherit the TCPIP.
     * The arguments used in TCPIP apply
     * in setting up TCPIP sockets, because TCPIP lies
     * below SSL/TLS.
     * <p>
     * If the TCPIPInitiatorOptions and/or TCPIPAcceptorOptions
     * arguments are present, then they are followed, otherwise
     * defaults for TCPIP are used.
     * <p>
     * The Arguments should have one of
     * TLSKeyStoreWithStorePass or TLSKeyStoreNoStorePass. If
     * neither of them is specified, the resulting Credentials will
     * run in TLS anonymously.
     *
     */
    const TransportSecurity::AcquisitionMethod
        AQM_TLSKeyStoreArgs = "TLSKeyStoreArgs";

    /**
     * This object allows to create the Builder for use with TLS
     * and a Java KeyStore.
     */
    local interface ArgumentFactory : SL3TCPIP::ArgumentFactory {

        /**
         * This operation creates a TLS KeyStore Arg Builder
         * object.
         */
        TLSKeyStoreArgBuilder createTLSKeyStoreArgBuilder(
            in TransportSecurity::CredentialsUsage usage
        );

        /**
         * This operation creates a Tagged Argument containing
         * a reference to a X509 Certificate Chain Verifier
         */
        SL3AQArgs::Argument createTLSX509IdentityVerifier(
            in TLSX509IdentityVerifier verifier
        );

        /**
         * This operation creates a Tagged Argument containing
         * the following information for acquiring credentials
         * from a Java KeyStore that is protected with a password.
         * <p>
         * For a description of the arguments, please see the
         * corresponding operation in the TLSKeyStoreArgBuilder.
         *
         * @see TLSKeyStoreArgBuilder
         */
        SL3AQArgs::Argument createTLSKeyStoreWithStorePass(
            in string           keystore,
            in string           storetype,
            in string           storepass,
            in string           keyalias,
            in string           keypass,
            in CORBA::StringSeq trusted_cert_names
        );

        /**
         * This operation creates a Tagged Argument containing
         * the following information for acquiring credentials
         * from a Java KeyStore that may be protected with a password.
         * <p>
         * For a description of the arguments, please see the
         * corresponding operation in the TLSKeyStoreArgBuilder.
         *
         * @see TLSKeyStoreArgBuilder
         */
        SL3AQArgs::Argument createTLSKeyStoreNoStorePass(
            in string           keystore,
            in string           storetype,
            in string           keyalias,
            in string           keypass,
            in CORBA::StringSeq trusted_cert_names
        );

        /**
         * This operation creates a Tagged Argument containing
         * the following information for acquiring credentials
         * from a Java KeyStore that is protected with a password.
         * <p>
         * For a description of the arguments, please see the
         * corresponding operation in the TLSKeyStoreArgBuilder.
         *
         * @see TLSKeyStoreArgBuilder
         */
        SL3AQArgs::Argument createTLSEncodedKeyStoreWithStorePass(
            in CORBA::OctetSeq  keystore,
            in string           storetype,
            in string           storepass,
            in string           keyalias,
            in string           keypass,
            in CORBA::StringSeq trusted_cert_names
        );

        /**
         * This operation creates a Tagged Argument containing
         * the following information for acquiring credentials
         * from a Java KeyStore that may be protected with a password.
         * <p>
         * For a description of the arguments, please see the
         * corresponding operation in the TLSKeyStoreArgBuilder.
         *
         * @see TLSKeyStoreArgBuilder
         */
        SL3AQArgs::Argument createTLSEncodedKeyStoreNoStorePass(
            in CORBA::OctetSeq  keystore,
            in string           storetype,
            in string           keyalias,
            in string           keypass,
            in CORBA::StringSeq trusted_cert_names
        );

    };

};
#endif