<flat-profile>
	<!-- Reset the global configuration options, now we will reset per day instead of every second. -->
	<Resync_Periodic>{$profile_resync}</Resync_Periodic>
	<Resync_On_Reset>Yes</Resync_On_Reset>
	<Profile_Rule>{$provisioning_type}://{$provisioning_path}/spa$MA.xml</Profile_Rule>

	<!-- Network Settings -->
	<DNS_Server_Order ua="na">Manual,DHCP</DNS_Server_Order>
	<Networking_Service ua="rw">Bridge</Networking_Service>
	<Enable_DHCP_Server ua="rw">No</Enable_DHCP_Server>

	{line_loop}

	<!-- Line Registration Information -->
	<Display_Name_{$line}_ ua="na">{$displayname}</Display_Name_{$line}_>
	<User_ID_{$line}_ ua="na">{$username}</User_ID_{$line}_>
	<Password_{$line}_ ua="na">{$secret}</Password_{$line}_>
	<Dial_Plan_{$line}_ ua="na">{$dial_plan}</Dial_Plan_{$line}_>
	<SIP_Port_{$line}_ group="Ext_{$line}/SIP_Settings">{$server_port}</SIP_Port_{$line}_>
	<Register_Expires_{$line}_ group="Ext_{$line}/Proxy_and_Registration">{$server_expires|3600}</Register_Expires_{$line}_>
	<Ans_Call_Without_Reg_{$line}_ ua="na">{$answer_call_without_reg|No}</Ans_Call_Without_Reg_{$line}_>

	<!-- Codec Information -->
	<Preferred_Codec_{$line}_ group="Ext_{$line}/Audio_Configuration">{$first_audio_codec}</Preferred_Codec_{$line}_>
	<Use_Pref_Codec_Only_{$line}_ group="Ext_{$line}/Audio_Configuration">No</Use_Pref_Codec_Only_{$line}_>
	<Second_Preferred_Codec_{$line}_ group="Ext_{$line}/Audio_Configuration">{$second_audio_codec}</Second_Preferred_Codec_{$line}_>
	<Third_Preferred_Codec_{$line}_ group="Ext_{$line}/Audio_Configuration">{$third_audio_codec}</Third_Preferred_Codec_{$line}_>
	
	<!-- Proxy Information -->
	<Proxy_{$line}_ group="Ext_{$line}/Proxy_and_Registration">{$server_host}</Proxy_{$line}_>
	<Use_Outbound_Proxy_{$line}_ ua="na">{$use_outbound_p|No}</Use_Outbound_Proxy_{$line}_>
	<Outbound_Proxy_{$line}_ ua="na">{$outbound_proxy_host}</Outbound_Proxy_{$line}_>
	<Proxy_Fallback_Intvl_{$line}_ ua="ro">{$proxy_fallback_intvl|3600}</Proxy_Fallback_Intvl_{$line}_>
	<Proxy_Redundancy_Method_{$line}_ ua="ro">{$proxy_redundancy_method|Normal}</Proxy_Redundancy_Method_{$line}_>
	
	<!-- DNS SRV Information -->
	<Use_DNS_SRV_{$line}_ ua="rw">{$use_dns_srv|No}</Use_DNS_SRV_{$line}_>
	<DNS_SRV_Auto_Prefix_{$line}_ group="Ext_{$line}/Proxy_and_Registration">{$dns_srv_prefix|Yes}</DNS_SRV_Auto_Prefix_{$line}_>

	<!-- NAT -->
	<NAT_Mapping_Enable_{$line}_ group="Ext_{$line}/NAT_Settings">{$nat_mapping_enabled|Yes}</NAT_Mapping_Enable_{$line}_>
	<NAT_Keep_Alive_Enable_{$line}_ group="Ext_{$line}/NAT_Settings">{$nat_keep_alive_enabled|Yes}</NAT_Keep_Alive_Enable_{$line}_>
	
	<Call_Waiting_Serv_{$line}_ ua="na" group="L{$line}/Supplementary_Service_Subscription">{$call_waiting_srv|No}</Call_Waiting_Serv_{$line}_>

	{/line_loop}

	<!-- Registration Settings -->
	<Reg_Min_Expires group="SIP/SIP_Timer_Values__sec_">1</Reg_Min_Expires>
	<Reg_Max_Expires group="SIP/SIP_Timer_Values__sec_">600</Reg_Max_Expires>
	<Reg_Retry_Intvl group="SIP/SIP_Timer_Values__sec_">10</Reg_Retry_Intvl>
	<Reg_Retry_Long_Intvl group="SIP/SIP_Timer_Values__sec_">20</Reg_Retry_Long_Intvl>

	<!-- RTP Settings -->
	<RTP_Packet_Size group="SIP/RTP_Parameters">0.020</RTP_Packet_Size>
	
	<!-- Codec Names -->
	<G711u_Codec_Name group="SIP/SDP_Payload_Types">PCMU</G711u_Codec_Name>
	<G711a_Codec_Name group="SIP/SDP_Payload_Types">PCMA</G711a_Codec_Name>
	<G726r16_Codec_Name group="SIP/SDP_Payload_Types">G726-16</G726r16_Codec_Name>
	<G726r24_Codec_Name group="SIP/SDP_Payload_Types">G726-24</G726r24_Codec_Name>
	<G726r32_Codec_Name group="SIP/SDP_Payload_Types">G726-32</G726r32_Codec_Name>
	<G726r40_Codec_Name group="SIP/SDP_Payload_Types">G726-40</G726r40_Codec_Name>
	<G729a_Codec_Name group="SIP/SDP_Payload_Types">G729</G729a_Codec_Name>
	<G729b_Codec_Name group="SIP/SDP_Payload_Types">G729</G729b_Codec_Name>
	<G722_Codec_Name group="SIP/SDP_Payload_Types">G722</G722_Codec_Name>
	
	 <!-- Firmware -->
	 <Upgrade_Enable ua="ro">{$enable_upgrade}</Upgrade_Enable>
	 <Upgrade_Rule ua="ro">{$upgrade_path}</Upgrade_Rule>
	
	<!-- Admin -->
	<Enable_Web_Server ua="na">{$enable_webserver}</Enable_Web_Server>
	<Web_Server_Port ua="na">{$webserver_port}</Web_Server_Port>
	<Enable_Web_Admin_Access ua="na">{$enable_webserver_admin}</Enable_Web_Admin_Access>
	<Admin_Passwd ua="na">{$administrator_password}</Admin_Passwd>
	<User_Password ua="na">{$user_password}</User_Password>
	<Enable_CDP group="System/VLAN_Settings">{$enable_cdp|No}</Enable_CDP>
	
	 <!-- Timezone Stuff -->
	 <Primary_NTP_Server ua="na">{$ntp}</Primary_NTP_Server>
	 <Time_Zone  ua="na">{$timezone}</Time_Zone>
	 <Daylight_Saving_Time_Rule ua="na">start=3/8/7/02:0:0;end=11/1/7/02:0:0;save=1</Daylight_Saving_Time_Rule>
	 <Daylight_Saving_Time_Enable group="Regional/Miscellaneous">No</Daylight_Saving_Time_Enable>
	
	 <!-- KeyCodes -->
	 <Call_Return_Code ua="na"> </Call_Return_Code>
	 <Blind_Transfer_Code >{$blind_transfer_code}</Blind_Transfer_Code>
	 <Call_Back_Act_Code> </Call_Back_Act_Code>
	 <Call_Back_Deact_Code> </Call_Back_Deact_Code>
	 <Cfwd_All_Act_Code> </Cfwd_All_Act_Code>
	 <Cfwd_All_Deact_Code> </Cfwd_All_Deact_Code>
	 <Cfwd_Busy_Act_Code> </Cfwd_Busy_Act_Code>
	 <Cfwd_Busy_Deact_Code> </Cfwd_Busy_Deact_Code>
	 <Cfwd_No_Ans_Act_Code> </Cfwd_No_Ans_Act_Code>
	 <Cfwd_No_Ans_Deact_Code> </Cfwd_No_Ans_Deact_Code>
	 <CW_Act_Code> </CW_Act_Code>
	 <CW_Deact_Code> </CW_Deact_Code>
	 <CW_Per_Call_Act_Code> </CW_Per_Call_Act_Code>
	 <CW_Per_Call_Deact_Code> </CW_Per_Call_Deact_Code>
	 <Block_CID_Act_Code> </Block_CID_Act_Code>
	 <Block_CID_Deact_Code> </Block_CID_Deact_Code>
	 <Block_CID_Per_Call_Act_Code> </Block_CID_Per_Call_Act_Code>
	 <Block_CID_Per_Call_Deact_Code> </Block_CID_Per_Call_Deact_Code>
	 <Block_ANC_Act_Code> </Block_ANC_Act_Code>
	 <Block_ANC_Deact_Code> </Block_ANC_Deact_Code>
	 <DND_Act_Code> </DND_Act_Code>
	 <DND_Deact_Code> </DND_Deact_Code>
	 <Secure_All_Call_Act_Code> </Secure_All_Call_Act_Code>
	 <Secure_No_Call_Act_Code> </Secure_No_Call_Act_Code>
	 <Secure_One_Call_Act_Code> </Secure_One_Call_Act_Code>
	 <Secure_One_Call_Deact_Code> </Secure_One_Call_Deact_Code>
	 <Paging_Code ua="na">{$page_code}</Paging_Code>
	 <Call_Park_Code> </Call_Park_Code>
	 <Call_Pickup_Code> </Call_Pickup_Code>
	 <Call_UnPark_Code> </Call_UnPark_Code>
	 <Group_Call_Pickup_Code> </Group_Call_Pickup_Code>
	 <Media_Loopback_Code> </Media_Loopback_Code>
	 <Referral_Services_Codes> </Referral_Services_Codes>

	<!-- Debug Information -->
	<Syslog_Server group="System/Optional_Network_Configuration">{$syslog_server}</Syslog_Server>
	<Debug_Level group="System/Optional_Network_Configuration">3</Debug_Level>
	<Debug_Server group="System/Optional_Network_Configuration">{$syslog_server}</Debug_Server>
	
	<!-- IP information -->
	<Connection_Type group="System/Internet_Connection_Type_">{$connection_type}</Connection_Type>
	<Static_IP group="System/_Static_IP_Settings">{$current_ip}</Static_IP>
	<NetMask group="System/_Static_IP_Settings">{$current_netmask}</NetMask>
	<Gateway group="System/_Static_IP_Settings">{$current_gateway}</Gateway>
	<Primary_DNS group="System/Optional_Network_Configuration">{$primary_dns}</Primary_DNS>

	<!-- Speed Dial -->
	<Speed_Dial_2 ua="rw">{$speed_dial_2}</Speed_Dial_2>
	<Speed_Dial_3 ua="rw">{$speed_dial_3}</Speed_Dial_3>
	<Speed_Dial_4 ua="rw">{$speed_dial_4}</Speed_Dial_4>
	<Speed_Dial_5 ua="rw">{$speed_dial_5}</Speed_Dial_5>
	<Speed_Dial_6 ua="rw">{$speed_dial_6}</Speed_Dial_6>
	<Speed_Dial_7 ua="rw">{$speed_dial_7}</Speed_Dial_7>
	<Speed_Dial_8 ua="rw">{$speed_dial_8}</Speed_Dial_8>
	<Speed_Dial_9 ua="rw">{$speed_dial_9}</Speed_Dial_9>
</flat-profile>
