|
1 /* |
|
2 * Copyright (c) 2003-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: |
|
15 * This class is used to handle IKEv2 configuration payload attributes. |
|
16 * |
|
17 */ |
|
18 #ifndef __IKEV2CONFIG_H_ |
|
19 #define __IKEV2CONFIG_H_ |
|
20 #include <e32base.h> |
|
21 #include "vpnmandefs.h" |
|
22 |
|
23 class CIkev2Acquire; |
|
24 class TCPPayloadIkev2; |
|
25 class TDataAttributes; |
|
26 class TInetAddr; |
|
27 // |
|
28 // |
|
29 // CIkev2Config |
|
30 // This class is used to handle IKEv2 config payload attributes |
|
31 // |
|
32 |
|
33 NONSHARABLE_CLASS(CIkev2Config) : public CBase |
|
34 { |
|
35 public: |
|
36 static CIkev2Config* NewL(CIkev2Acquire* aAcquire, TInetAddr* aRemoteIp=NULL); |
|
37 ~CIkev2Config(); |
|
38 TBool ProcessCpL(TCPPayloadIkev2* aCpPayload); |
|
39 TPtrC8 Cp() const; |
|
40 TUint8 CpType() const; |
|
41 TUint32 ExpireTime() const; |
|
42 TVPNAddress VirtualIp(); |
|
43 |
|
44 |
|
45 private: |
|
46 void ConstructL(CIkev2Acquire* aAcquire, TInetAddr* aRemoteIp); |
|
47 TInt AddAttribute(TDataAttributes* aAttr, TUint8 aType, TInt aLth, TUint8* aData); |
|
48 |
|
49 private: |
|
50 TBool iRequestGoing; // CP Request going |
|
51 TUint32 iAddressExpiry; // Address expiration time |
|
52 HBufC8* iCp; // CP Payload buffer |
|
53 TUint8 iCpType; |
|
54 TVPNAddress iVIP; // Virtual IP |
|
55 }; |
|
56 |
|
57 |
|
58 #endif |