|
||
This section explains how to configure the Comms database for a VPN connection on a mobile device. The Comms database stores the Symbian OS network configuration settings. This section is aimed at developers writing applications that use VPN connections on a mobile device. Refer to Comms Database Configuration Overview for more information on using the Comms database.
This section is a use case of the Comms database for VPN connections and explains various tables that should be configured. You can configure tables in any order, but we recommend that you follow the same order as listed here. The configuration settings are stored in an XML file as shown in the sample configuration file. The file can be edited using CED and CEDDUMP tools.
The following tables are needed when configuring VPN connections. Note that CED generates blank tables if any of the tables listed below is not configured.
The Proxy table should be configured when the LAN uses proxy servers.
There should be at least one record created for this table.
<NetworkTable>
<Network operation="add">
<Name>Intranet1</Name>
</Network>
<NetworkTable>
There should be at least one record created for the IAP table but usually more than one record is used. Each record in this table specifies an access point.
<IAPTable>
<IAP operation="add">
<Name>Cisco VPN IAP</Name>
<IAPService>VpnService.cisco.tunnel</IAPService>
<IAPBearer>VirtualBearer.VPN Bearer1</IAPBearer>
<IAPNetwork>Network.Intranet1 </IAPNetwork>
<IAPNetworkWeighting>0</IAPNetworkWeighting>
<LocationRef>Location.Office </LocationRef>
</IAP>
</IAPTable>
The sample IAP table shows that the IAP record has reference to records in other tables like Network table, Virtual service table and Location table. The IAP records specify the access point settings and hence there are several records in this table for different access types used by the applications.
For full list of fields and possible values, Refer to Comms Database Reference.
There should be at least one record created for this table as the VPN connection requires a real bearer.
<LANBearerTable>
<LANBearer operation="add">
<Name>Assabet on-board ethernet</Name>
<Agent>nullagt.agt</Agent>
<IfName>ethint</IfName>
<PDDName>not used</PDDName>
<PacketDriverName>not used</PacketDriverName>
<LastSocketActivityTimeout>-1</LastSocketTimeout>
<LastSessionClosedTimeout>-1</LastSessionClosedTimeout>
<LastSocketClosedTimeout>-1</LastSocketClosedTimeout>
</LANBearer>
</LANBearerTable>
The LAN bearer table contains the details of the bearer settings and the device drivers used. There may be other bearers configured for different applications.
For full list of fields and possible values, Refer to Comms Database Reference.
There should be at least one record created for this table containing the gateway address and IP settings.
<LANServiceTable>
<LANService operation="add">
<Name>Ethernet</Name>
<Ifnetworks>ip</IfNetworks>
<IpNetmask>xxx.xxx.xxx.xxx</IpNetmask>
<IpGateway>yyy.yyy.yyy.yyy</IpGateway>
<IpAddr>zzz.zzz.zzz.zzz</IpAddr>
<IpAddrFromServer>TRUE</IpAddrFromServer>
<IpDNSAddrFromServer>TRUE</IpDNSAddrFromServer>
<Ip6DNSAddrFromServer>TRUE</Ip6DNSAddrFromServer>
<IpNameServer1>aaa.aaa.aaa.aaa</IpNameServer1>
<IpNameServer2>bbb.bbb.bbb.bbb</IpNameServer2>
</LANService>
</LANServiceTable>
For full list of fields and possible values, Refer to Comms Database Reference.
There should be at least one record created for this table. The record containing the most preferred connection should have ranking 1 and the record containing the next preferred connection should have ranking 2. All other records created in this table should have the ranking 0. The record with ranking 1 is attempted first, if it fails the connection with ranking 2 is attempted. .
<ConnectionPreferencesTable>
<ConnectionPreferences operation="add">
<Name>ConnectionPreferenceTable1</Name>
<Ranking>1</Ranking>
<Direction>OUTGOING</Direction>
<DialogPref>PROMPT</DialogPref>
<BearerSet>LAN</BearerSet>
<IAPRef>IAP.Cisco VPN</IAPRef>
</ConnectionPreferences>
</ConnectionPreferencesTable>
This sample record contains the settings for an outgoing connection. A Similar record can be created for incoming connections.
For full list of fields and possible values, Refer to Comms Database Reference.
There should be only one record created for
this table. The record should have valid references in the Modem bearer,
Location and Network table
s.
<GloballSettingsTable>
<GlobalSettings operation="add">
<Name>GlobalSettingstable1</Name>
<WAPAccess>WAPAccessPoint.Default DialInISP</WAPAccess>
<RedialAttempts>3</RedialAttempts>
<SMSBearer>WAPSMSBearer.WAPSMSBearerTable1</SmsBearer>
<SmsReceiveMode>2</SmsReceiveMode>
<GPRSAttachMode>1</GPRSAttachMode>
<AcceptIncomingGprs>1</AcceptIncomingGPRS>
<ConnectionAttempts>2</ConnectionAttempts>
<ModemForDataAndFax>2</ModemForDataAndFax>
<ModemForPhoneServiceAndSMS>2</ModemForPhoneServiceAndSms>
<LocationForDataAndFax>Location.office</LocationForDataAndFax>
<LocationForPhoneservicesAndSMS>Location.Office</LocationForPhoneservicesAndSms>
<GPRSClassCBearer>GSM</GPRSClassCBearer>
<DefaultNetwork>Network.Intranet1</DefaultNetwork>
<BearerAvailabilityCheckTSY>mm</BearerAvailabilityCheckTSY>
</GlobalSettings>
</GlobalSettingsTable>
For full list of fields and possible values, Refer to Comms Database Reference.
There should be at least one record for this table with the location details.
<LocationTable>
<Location operation="add">
<Name>office</Name>
<Mobile>FALSE</Mobile>
<UsePulseDial>FALSE</UsePulseDial>
<WaitForDialTone>FALSE</WaitForDialTone>
<PauseAfterDialOut>0</PauseAfterDialOut>
<IntlPrefixCode>00</IntlPrefixCode>
<NatCode>44</NatCode>
<AreaCode>207</AreaCode>
<DialOutCode>0</DialOutCode>
</Location>
</Locationtable>
For full list of fields and possible values, Refer to Comms Database Reference.
There should be at least one record created for this table as VPN connection requires a virtual bearer.
<VirtualBearerTable>
<VirtualBearer operation="add">
<Name>VPN bearer1</Name>
<Agent>vpnconnagt.agt</Agent>
<IfName>tunnelnif</Ifname>
<LastSocketActivityTimeOut>-1</LastSocketActivityTimeout>
<LastSessionClosedTimeout>-1</LastSessionClosedTimeout>
<LastSocketClosedTimeout>-1</LastSocketClosedTimeout>
</VirtualBearer>
</VirtualBearerTable>
There should be at least one record created for this table. This table contains the details of the VPN policy used and reference to the real IAP used.
<VPNServiceTable>
<VPNService operation="add">
<Name>cisco tunnel</Name>
<Policy>policy name used</Policy>
<HomeIAP>IAP.DynRAS on comm1</HomeIAP>
<HomeNetwork>Network.Intranet1</HomeNetwork>
</VPNService>
<VPNServiceTable>
This table contains the proxy server settings. This table should be configured when proxy servers are used.
<ProxyTable>
<Proxy operation="add">
<Name>Proxy table1</Name>
<ISPRef>reference to an ISP</ISPRef>
<UseProxyServer>TRUE</UseProxyserver>
<ProtocolName>http</ProtocolName>
<ProxyServerName>www.aproxyserver.com</ProxyserverName>
<PortNumber>80</PortNumber>
<Exceptions>www.anotherproxyserver.com</Exceptions>
</Proxy>
</Proxytable>
For full list of fields and possible values, Refer to Comms Database Reference.