- <?xml version="1.0" encoding="utf-8"?>
- <include>
- <context name="one">
- <extension name="unloop">
- <condition field="${unroll_loops}" expression="^true$"/>
- <condition field="${sip_looped_call}" expression="^true$">
- <action application="deflect" data="${destination_number}"/>
- </condition>
- </extension>
- <extension name="global" continue="true">
- <condition field="${call_debug}" expression="^true$" break="never">
- <action application="info"/>
- </condition>
- <condition field="${rtp_has_crypto}" expression="^($${rtp_sdes_suites})$" break="never">
- <action application="set" data="rtp_secure_media=true"/>
- </condition>
- <condition field="${endpoint_disposition}" expression="^(DELAYED NEGOTIATION)"/>
- <condition field="${switch_r_sdp}" expression="(AES_CM_128_HMAC_SHA1_32|AES_CM_128_HMAC_SHA1_80)" break="never">
- <action application="set" data="rtp_secure_media=true"/>
- </condition>
- <condition>
- <action application="hash" data="insert/${one}-spymap/${caller_id_number}/${uuid}"/>
- <action application="hash" data="insert/${one}-last_dial/${caller_id_number}/${destination_number}"/>
- <action application="hash" data="insert/${one}-last_dial/global/${uuid}"/>
- <action application="export" data="RFC2822_DATE=${strftime(%a, %d %b %Y %T %z)}"/>
- </condition>
- </extension>
- <extension name="Local_Extension">
- <condition field="destination_number" expression="^([8|9][0-2][0-9])$">
- <action application="export" data="dialed_extension=$1"/>
- <action application="bind_meta_app" data="1 b s execute_extension::dx XML features"/>
- <action application="bind_meta_app" data="2 b s record_session::$${recordings_dir}/${caller_id_number}.${strftime(%Y-%m-%d-%H-%M-%S)}.wav"/>
- <action application="bind_meta_app" data="3 b s execute_extension::cf XML features"/>
- <action application="bind_meta_app" data="4 b s execute_extension::att_xfer XML features"/>
- <action application="set" data="ringback=${us-ring}"/>
- <action application="set" data="transfer_ringback=$${hold_music}"/>
- <action application="set" data="call_timeout=30"/>
- <action application="set" data="hangup_after_bridge=true"/>
- <action application="set" data="continue_on_fail=true"/>
- <action application="hash" data="insert/${one}-call_return/${dialed_extension}/${caller_id_number}"/>
- <action application="hash" data="insert/${one}-last_dial_ext/${dialed_extension}/${uuid}"/>
- <action application="set" data="called_party_callgroup=${user_data(${dialed_extension}@${one} var callgroup)}"/>
- <action application="hash" data="insert/${one}-last_dial_ext/${called_party_callgroup}/${uuid}"/>
- <action application="hash" data="insert/${one}-last_dial_ext/global/${uuid}"/>
- <action application="hash" data="insert/${one}-last_dial/${called_party_callgroup}/${uuid}"/>
- <action application="bridge" data="user/${dialed_extension}@${one}"/>
- <action application="answer"/>
- <action application="sleep" data="1000"/>
- <action application="bridge" data="loopback/app=voicemail:default ${one} ${dialed_extension}"/>
- </condition>
- </extension>
- <extension name="sip_uri">
- <condition field="destination_number" expression="^sip:(.*)$">
- <action application="bridge" data="sofia/${use_profile}/$1"/>
- </condition>
- </extension>
- <X-PRE-PROCESS cmd="include" data="one/*.xml"/>
- <extension name="acknowledge_call">
- <condition field="destination_number" expression="^(.*)$">
- <action application="acknowledge_call"/>
- <action application="ring_ready"/>
- <action application="playback" data="$${hold_music}"/>
- </condition>
- </extension>
- </context>
- </include>