author | hgs |
Mon, 24 May 2010 20:32:47 +0300 | |
changeset 26 | 9abfd4f00d37 |
parent 2 | 1c7bc153c08e |
child 46 | c74b3d9f6b9e |
permissions | -rw-r--r-- |
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
1 |
/* |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
2 |
* Copyright (c) 2001-2006 Nokia Corporation and/or its subsidiary(-ies). |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
3 |
* All rights reserved. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
4 |
* This component and the accompanying materials are made available |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
5 |
* under the terms of the License "Eclipse Public License v1.0" |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
6 |
* which accompanies this distribution, and is available |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
7 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html". |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
8 |
* |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
9 |
* Initial Contributors: |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
10 |
* Nokia Corporation - initial contribution. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
11 |
* |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
12 |
* Contributors: |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
13 |
* |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
14 |
* Description: EAP and WLAN authentication protocols. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
15 |
* |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
16 |
*/ |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
17 |
|
2
1c7bc153c08e
Revision: 201001
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
0
diff
changeset
|
18 |
/* |
26 | 19 |
* %version: 11.1.29 % |
2
1c7bc153c08e
Revision: 201001
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
0
diff
changeset
|
20 |
*/ |
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
21 |
|
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
22 |
// Refer the document S60_3_1_EAP_Symbian_Adaptation_Design_C.doc for more |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
23 |
// details of using EAPSettings. Refer section 9.2 for code samples. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
24 |
|
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
25 |
#ifndef EAP_SETTINGS_H |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
26 |
#define EAP_SETTINGS_H |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
27 |
|
26 | 28 |
#include <unifiedcertstore.h> |
29 |
#include <cctcertinfo.h> |
|
30 |
#include "EapExpandedType.h" |
|
31 |
||
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
32 |
const TUint KGeneralStringMaxLength = 255; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
33 |
const TUint KKeyIdentifierLength = 255; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
34 |
const TUint KThumbprintMaxLength = 64; |
26 | 35 |
/* This is the maximum length of a certificate primary/secondary name we are interested in. */ |
36 |
const TUint32 KMaxCertNameLength = 64; |
|
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
37 |
|
26 | 38 |
|
39 |
//------------------------------------------------------------------------------- |
|
40 |
||
41 |
class EapCertificateEntry |
|
42 |
: public CBase |
|
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
43 |
{ |
26 | 44 |
|
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
45 |
public: |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
46 |
|
26 | 47 |
enum TCertType |
48 |
{ |
|
49 |
ENone, |
|
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
50 |
EUser, |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
51 |
ECA |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
52 |
}; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
53 |
|
26 | 54 |
IMPORT_C EapCertificateEntry(); |
55 |
||
56 |
IMPORT_C virtual ~EapCertificateEntry(); |
|
57 |
||
58 |
IMPORT_C void trace() const; |
|
59 |
||
60 |
IMPORT_C EapCertificateEntry * Copy(); |
|
61 |
||
62 |
// This operator is indentionally without implementation. |
|
63 |
EapCertificateEntry * const operator = (const EapCertificateEntry * const right_type_value); // Do not use this. |
|
64 |
||
65 |
IMPORT_C EapCertificateEntry &operator = (const EapCertificateEntry &right_type_value); |
|
66 |
||
67 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
68 |
||
69 |
IMPORT_C TBool GetSubjectNamePresent() const; |
|
70 |
||
71 |
IMPORT_C TBool GetIssuerNamePresent() const; |
|
72 |
||
73 |
IMPORT_C TBool GetSerialNumberPresent() const; |
|
74 |
||
75 |
IMPORT_C TBool GetThumbprintPresent() const; |
|
76 |
||
77 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
78 |
||
79 |
IMPORT_C TBool GetLabelPresent() const; |
|
80 |
||
81 |
IMPORT_C TBool GetPrimaryNamePresent() const; |
|
82 |
||
83 |
IMPORT_C TBool GetSecondaryNamePresent() const; |
|
84 |
||
85 |
IMPORT_C TBool GetIsEnabledPresent() const; |
|
86 |
||
87 |
IMPORT_C TBool GetSubjectKeyIdPresent() const; |
|
88 |
||
89 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
90 |
||
91 |
IMPORT_C void SetSubjectNamePresent(); |
|
92 |
||
93 |
IMPORT_C void SetIssuerNamePresent(); |
|
94 |
||
95 |
IMPORT_C void SetSerialNumberPresent(); |
|
96 |
||
97 |
IMPORT_C void SetThumbprintPresent(); |
|
98 |
||
99 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
100 |
||
101 |
IMPORT_C void SetLabelPresent(); |
|
102 |
||
103 |
IMPORT_C void SetPrimaryNamePresent(); |
|
104 |
||
105 |
IMPORT_C void SetSecondaryNamePresent(); |
|
106 |
||
107 |
IMPORT_C void SetIsEnabledPresent(); |
|
108 |
||
109 |
IMPORT_C void SetSubjectKeyIdPresent(); |
|
110 |
||
111 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
112 |
||
113 |
IMPORT_C TCertType GetCertType() const; |
|
114 |
||
115 |
IMPORT_C const TDes * GetSubjectName() const; |
|
116 |
||
117 |
IMPORT_C const TDes * GetIssuerName() const; |
|
118 |
||
119 |
IMPORT_C const TDes * GetSerialNumber() const; |
|
120 |
||
121 |
IMPORT_C const TDes * GetThumbprint() const; |
|
122 |
||
123 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
124 |
||
125 |
IMPORT_C TDes * GetSubjectNameWritable(); |
|
126 |
||
127 |
IMPORT_C TDes * GetIssuerNameWritable(); |
|
128 |
||
129 |
IMPORT_C TDes * GetSerialNumberWritable(); |
|
130 |
||
131 |
IMPORT_C TDes * GetThumbprintWritable(); |
|
132 |
||
133 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
134 |
||
135 |
IMPORT_C const TDes * GetLabel() const; |
|
136 |
||
137 |
IMPORT_C const TKeyIdentifier & GetSubjectKeyId() const; |
|
138 |
||
139 |
IMPORT_C const TDes * GetPrimaryName() const; |
|
140 |
||
141 |
IMPORT_C const TDes * GetSecondaryName() const; |
|
142 |
||
143 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
144 |
||
145 |
IMPORT_C TDes * GetLabelWritable(); |
|
146 |
||
147 |
IMPORT_C TKeyIdentifier * GetSubjectKeyIdWritable(); |
|
148 |
||
149 |
IMPORT_C TDes * GetPrimaryNameWritable(); |
|
150 |
||
151 |
IMPORT_C TDes * GetSecondaryNameWritable(); |
|
152 |
||
153 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
154 |
||
155 |
IMPORT_C TInt SetCertType(const TCertType & aType); |
|
156 |
||
157 |
IMPORT_C TInt SetSubjectName(const TBuf<KGeneralStringMaxLength> & aSubjectName); |
|
158 |
||
159 |
IMPORT_C TInt SetIssuerName(const TBuf<KGeneralStringMaxLength> & aIssuerName); |
|
160 |
||
161 |
IMPORT_C TInt SetSerialNumber(const TBuf<KGeneralStringMaxLength> & aSerialNumber); |
|
162 |
||
163 |
IMPORT_C TInt SetThumbprint(const TBuf<KThumbprintMaxLength> & aThumbprint); |
|
164 |
||
165 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
166 |
||
167 |
IMPORT_C TInt SetLabel(const TCertLabel & aLabel); |
|
168 |
||
169 |
IMPORT_C TInt SetSubjectKeyId(const TKeyIdentifier & aSubjectKeyId); |
|
170 |
||
171 |
IMPORT_C TInt SetPrimaryName(const TBuf<KMaxCertNameLength> & aPrimaryName); |
|
172 |
||
173 |
IMPORT_C TInt SetSecondaryName(const TBuf<KMaxCertNameLength> & aSecondaryName); |
|
174 |
||
175 |
IMPORT_C TInt SetIsEnabled(const TBool aIsEnabled); |
|
176 |
||
177 |
IMPORT_C TInt SetIsValid(const TBool aIsValid); |
|
178 |
||
179 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
180 |
||
181 |
IMPORT_C TBool GetIsEnabled() const; |
|
182 |
||
183 |
IMPORT_C TBool GetIsValid() const; |
|
184 |
||
185 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
186 |
||
187 |
private: |
|
188 |
||
189 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
190 |
// These members are used by authentication protocols. |
|
191 |
||
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
192 |
// Specifies whether this entry describes user or CA certificate (mandatory) |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
193 |
TCertType iCertType; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
194 |
|
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
195 |
// Subject name in distinguished name ASCII form. This is optional. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
196 |
// For example "/C=US/O=Some organization/CN=Some common name". |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
197 |
TBool iSubjectNamePresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
198 |
TBuf<KGeneralStringMaxLength> iSubjectName; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
199 |
|
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
200 |
// Issuer name in distinguished name ASCII form. This is optional. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
201 |
// For example "/C=US/O=Some organization/CN=Some common name". |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
202 |
TBool iIssuerNamePresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
203 |
TBuf<KGeneralStringMaxLength> iIssuerName; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
204 |
|
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
205 |
// Serial number in ASCII form. This is optional. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
206 |
TBool iSerialNumberPresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
207 |
TBuf<KGeneralStringMaxLength> iSerialNumber; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
208 |
|
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
209 |
// Thumbprint in binary form. This is optional. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
210 |
TBool iThumbprintPresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
211 |
TBuf<KThumbprintMaxLength> iThumbprint; |
26 | 212 |
|
213 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
214 |
// These members are used by UI. |
|
215 |
||
216 |
// This holds only the certificate label. This is the text UI will show. |
|
217 |
TBool iLabelPresent; |
|
218 |
TCertLabel iLabel; |
|
219 |
||
220 |
// Primary name of the certificate if any. |
|
221 |
TBool iPrimaryNamePresent; |
|
222 |
TBuf<KMaxCertNameLength> iPrimaryName; |
|
223 |
||
224 |
// Secondary name of the certificate if any. |
|
225 |
TBool iSecondaryNamePresent; |
|
226 |
TBuf<KMaxCertNameLength> iSecondaryName; |
|
227 |
||
228 |
// UI uses this to indicate enabled certificate. |
|
229 |
TBool iIsEnabledPresent; |
|
230 |
TBool iIsEnabled; |
|
231 |
||
232 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
233 |
// These members are used by both authentication protocols and UI. |
|
234 |
||
235 |
// Subject key in binary form. This is mandatory field to find correct certificate from CUnifiedCertStore. UI uses this too. |
|
236 |
TBool iSubjectKeyIdPresent; |
|
237 |
//TBuf8<KKeyIdentifierLength> iSubjectKeyId; |
|
238 |
TKeyIdentifier iSubjectKeyId; // This is mandatory field to find correct certificate from CUnifiedCertStore. |
|
239 |
||
240 |
// Indicates this object is correctly initialized. |
|
241 |
TBool iIsValid; |
|
242 |
||
243 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
244 |
}; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
245 |
|
26 | 246 |
//------------------------------------------------------------------------------- |
247 |
||
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
248 |
class EAPSettings : public CBase |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
249 |
{ |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
250 |
public: |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
251 |
|
26 | 252 |
IMPORT_C EAPSettings(); |
253 |
||
254 |
IMPORT_C virtual ~EAPSettings(); |
|
255 |
||
256 |
IMPORT_C void trace() const; |
|
257 |
||
258 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
259 |
|
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
260 |
// Specifies the EAP type these settings are for. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
261 |
// Is not really needed but is here so just some sanity checks can be made |
26 | 262 |
TEapExpandedType iEAPExpandedType; // Use this in new code. |
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
263 |
|
26 | 264 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
265 |
||
266 |
// Use automatic CA certificate. |
|
267 |
TBool iUseAutomaticCACertificatePresent; |
|
268 |
TBool iUseAutomaticCACertificate; |
|
269 |
||
270 |
// Use automatic username. |
|
271 |
TBool iUseAutomaticUsernamePresent; |
|
272 |
TBool iUseAutomaticUsername; |
|
273 |
||
274 |
// Use automatic realm. |
|
275 |
TBool iUseAutomaticRealmPresent; |
|
276 |
TBool iUseAutomaticRealm; |
|
277 |
||
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
278 |
// Username in ASCII format |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
279 |
TBool iUsernamePresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
280 |
TBuf<KGeneralStringMaxLength> iUsername; |
26 | 281 |
|
282 |
/// Get: Whether password is stored in database. |
|
283 |
/// Set: Whether password must be cleared from database. |
|
284 |
TBool iPasswordExistPresent; |
|
285 |
TBool iPasswordExist; |
|
286 |
||
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
287 |
// Password in ASCII format |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
288 |
TBool iPasswordPresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
289 |
TBuf<KGeneralStringMaxLength> iPassword; |
26 | 290 |
|
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
291 |
// Realm in ASCII format |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
292 |
TBool iRealmPresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
293 |
TBuf<KGeneralStringMaxLength> iRealm; |
26 | 294 |
|
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
295 |
// Use pseudonym identities in EAP-SIM/AKA |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
296 |
TBool iUsePseudonymsPresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
297 |
TBool iUsePseudonyms; |
26 | 298 |
|
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
299 |
// Whether EAP-TLS/TTLS/PEAP should verify server realm |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
300 |
TBool iVerifyServerRealmPresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
301 |
TBool iVerifyServerRealm; |
26 | 302 |
|
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
303 |
// Whether EAP-TLS/TTLS/PEAP should require client authentication |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
304 |
TBool iRequireClientAuthenticationPresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
305 |
TBool iRequireClientAuthentication; |
26 | 306 |
|
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
307 |
// General session validity time (in minutes) |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
308 |
TBool iSessionValidityTimePresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
309 |
TUint iSessionValidityTime; |
26 | 310 |
|
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
311 |
// An array of allowed cipher suites for EAP-TLS/TTLS/PEAP. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
312 |
// Refer to RFC2246 chapter A.5 for the values. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
313 |
TBool iCipherSuitesPresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
314 |
RArray<TUint> iCipherSuites; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
315 |
|
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
316 |
// In EAP-PEAP is version 0 allowed |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
317 |
TBool iPEAPVersionsPresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
318 |
TBool iPEAPv0Allowed; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
319 |
TBool iPEAPv1Allowed; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
320 |
TBool iPEAPv2Allowed; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
321 |
|
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
322 |
// Array listing the allowed certificates for EAP-TLS/TTLS/PEAP. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
323 |
// Subject key ID and Certificate type are the only mandatory certificate |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
324 |
// details needed at the moment. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
325 |
TBool iCertificatesPresent; |
26 | 326 |
RPointerArray<EapCertificateEntry> iCertificates; |
327 |
||
328 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
|
329 |
||
330 |
// Use this in new code. |
|
331 |
// Array listing the enabled encapsulated Expanded EAP types (in priority order). |
|
332 |
// Use constant Expanded EAP type values from EapExpandedType.h. |
|
333 |
TBool iEnabledEncapsulatedEAPExpandedTypesPresent; |
|
334 |
RArray<TEapExpandedType> iEnabledEncapsulatedEAPExpandedTypes; |
|
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
335 |
|
26 | 336 |
// Use this in new code. |
337 |
// Array listing the disabled encapsulated Expanded EAP types. |
|
338 |
// Use constant Expanded EAP type values from EapExpandedType.h. |
|
339 |
TBool iDisabledEncapsulatedEAPExpandedTypesPresent; |
|
340 |
RArray<TEapExpandedType> iDisabledEncapsulatedEAPExpandedTypes; |
|
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
341 |
|
26 | 342 |
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - |
343 |
||
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
344 |
// Whether Authenticated provisioning mode allowed or not in EAP-FAST. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
345 |
TBool iAuthProvModeAllowedPresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
346 |
TBool iAuthProvModeAllowed; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
347 |
|
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
348 |
// Whether Unauthenticated provisioning mode allowed or not in EAP-FAST. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
349 |
TBool iUnauthProvModeAllowedPresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
350 |
TBool iUnauthProvModeAllowed; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
351 |
|
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
352 |
// PAC group reference in ASCII format for EAP-FAST. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
353 |
TBool iPACGroupReferencePresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
354 |
TBuf<KGeneralStringMaxLength> iPACGroupReference; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
355 |
|
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
356 |
// Whether to Warn (or Prompt) for ADHP (Authenticated Diffie-Hellman Protocol) |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
357 |
// auto-provisioning when there is no PAC at all. EAP-FAST specific. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
358 |
TBool iWarnADHPNoPACPresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
359 |
TBool iWarnADHPNoPAC; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
360 |
|
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
361 |
// Whether to Warn (or Prompt) for ADHP auto-provisioning when |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
362 |
// there is no PAC that matches the A-ID sent by server. EAP-FAST specific. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
363 |
TBool iWarnADHPNoMatchingPACPresent; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
364 |
TBool iWarnADHPNoMatchingPAC; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
365 |
|
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
366 |
// Whether to Warn (or Prompt) when client encouters a server that has provisioned |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
367 |
// the client with a PAC before but is not currently selected as the default server. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
368 |
// EAP-FAST specific. |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
369 |
TBool iWarnNotDefaultServerPresent; |
26 | 370 |
TBool iWarnNotDefaultServer; |
371 |
||
372 |
TBool iShowPassWordPromptPresent; |
|
373 |
TBool iShowPassWordPrompt; |
|
374 |
||
375 |
// This is used in TLS/PEAP/TTLS/FAST. It activates TLS-renegotiation, that will send user certificate with in TLS-protected application data. |
|
376 |
TBool iUseIdentityPrivacyPresent; |
|
377 |
TBool iUseIdentityPrivacy; |
|
378 |
||
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
379 |
}; |
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
380 |
|
26 | 381 |
//#include "EapSettings.inl" |
382 |
||
383 |
//------------------------------------------------------------------------------- |
|
384 |
||
385 |
#if defined(USE_EAP_TRACE) |
|
386 |
||
387 |
#define EAP_TRACE_SETTINGS(settings) { (settings)->trace(); } |
|
388 |
||
389 |
#else |
|
390 |
||
391 |
#define EAP_TRACE_SETTINGS(settings) |
|
392 |
||
393 |
#endif //#if defined(USE_EAP_TRACE) |
|
394 |
||
395 |
||
396 |
//------------------------------------------------------------------------------- |
|
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
397 |
|
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
398 |
#endif |
26 | 399 |
|
0
c8830336c852
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
400 |
// End of file |