<?xml version='1.0' encoding='UTF-8' standalone='no'?>
<doxygen xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="compound.xsd" version="1.8.8">
  <compounddef id="remote__provisioning_8c" kind="file">
    <compoundname>remote_provisioning.c</compoundname>
    <includes refid="private_8h" local="yes">private.h</includes>
    <includes refid="xml2lpc_8h" local="yes">xml2lpc.h</includes>
      <sectiondef kind="define">
      <memberdef kind="define" id="remote__provisioning_8c_1aed29e066e0d70e6fe4e98fc8b6c9a37f" prot="public" static="no">
        <name>XML2LPC_CALLBACK_BUFFER_SIZE</name>
        <initializer>1024</initializer>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" line="22" column="9" bodyfile="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" bodystart="22" bodyend="-1"/>
      </memberdef>
      </sectiondef>
      <sectiondef kind="func">
      <memberdef kind="function" id="remote__provisioning_8c_1a93ae54a42e1fc5077949f2ec8205a2fb" prot="public" static="yes" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>void</type>
        <definition>static void xml2lpc_callback</definition>
        <argsstring>(void *ctx, xml2lpc_log_level level, const char *fmt, va_list list)</argsstring>
        <name>xml2lpc_callback</name>
        <param>
          <type>void *</type>
          <declname>ctx</declname>
        </param>
        <param>
          <type>xml2lpc_log_level</type>
          <declname>level</declname>
        </param>
        <param>
          <type>const char *</type>
          <declname>fmt</declname>
        </param>
        <param>
          <type>va_list</type>
          <declname>list</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" line="24" column="1" bodyfile="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" bodystart="24" bodyend="34"/>
      </memberdef>
      <memberdef kind="function" id="remote__provisioning_8c_1ad343f3e91d726adf521d49b1e344c51c" prot="public" static="yes" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>void</type>
        <definition>static void linphone_remote_provisioning_apply</definition>
        <argsstring>(LinphoneCore *lc, const char *xml)</argsstring>
        <name>linphone_remote_provisioning_apply</name>
        <param>
          <type><ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref> *</type>
          <declname>lc</declname>
        </param>
        <param>
          <type>const char *</type>
          <declname>xml</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" line="36" column="1" bodyfile="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" bodystart="36" bodyend="61"/>
      </memberdef>
      <memberdef kind="function" id="remote__provisioning_8c_1aabdb2498143334440f464cb597817618" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>int</type>
        <definition>int linphone_remote_provisioning_load_file</definition>
        <argsstring>(LinphoneCore *lc, const char *file_path)</argsstring>
        <name>linphone_remote_provisioning_load_file</name>
        <param>
          <type><ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref> *</type>
          <declname>lc</declname>
        </param>
        <param>
          <type>const char *</type>
          <declname>file_path</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" line="63" column="1" bodyfile="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" bodystart="63" bodyend="73"/>
      </memberdef>
      <memberdef kind="function" id="remote__provisioning_8c_1aef6371558fdc07143ccbd40c0c21be99" prot="public" static="yes" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>void</type>
        <definition>static void belle_request_process_response_event</definition>
        <argsstring>(void *ctx, const belle_http_response_event_t *event)</argsstring>
        <name>belle_request_process_response_event</name>
        <param>
          <type>void *</type>
          <declname>ctx</declname>
        </param>
        <param>
          <type>const belle_http_response_event_t *</type>
          <declname>event</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" line="75" column="1" bodyfile="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" bodystart="75" bodyend="85"/>
      </memberdef>
      <memberdef kind="function" id="remote__provisioning_8c_1a616d1a99075eecaca0b18fd8321b37bf" prot="public" static="yes" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>void</type>
        <definition>static void belle_request_process_io_error</definition>
        <argsstring>(void *ctx, const belle_sip_io_error_event_t *event)</argsstring>
        <name>belle_request_process_io_error</name>
        <param>
          <type>void *</type>
          <declname>ctx</declname>
        </param>
        <param>
          <type>const belle_sip_io_error_event_t *</type>
          <declname>event</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" line="87" column="1" bodyfile="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" bodystart="87" bodyend="90"/>
      </memberdef>
      <memberdef kind="function" id="remote__provisioning_8c_1a102b640edc8db0560f9b805bfc24bd34" prot="public" static="yes" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>void</type>
        <definition>static void belle_request_process_timeout</definition>
        <argsstring>(void *ctx, const belle_sip_timeout_event_t *event)</argsstring>
        <name>belle_request_process_timeout</name>
        <param>
          <type>void *</type>
          <declname>ctx</declname>
        </param>
        <param>
          <type>const belle_sip_timeout_event_t *</type>
          <declname>event</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" line="92" column="1" bodyfile="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" bodystart="92" bodyend="95"/>
      </memberdef>
      <memberdef kind="function" id="remote__provisioning_8c_1a0ff03b61f25cd8d3cc883eb20b6c803c" prot="public" static="yes" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>void</type>
        <definition>static void belle_request_process_auth_requested</definition>
        <argsstring>(void *ctx, belle_sip_auth_event_t *event)</argsstring>
        <name>belle_request_process_auth_requested</name>
        <param>
          <type>void *</type>
          <declname>ctx</declname>
        </param>
        <param>
          <type>belle_sip_auth_event_t *</type>
          <declname>event</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" line="97" column="1" bodyfile="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" bodystart="97" bodyend="100"/>
      </memberdef>
      <memberdef kind="function" id="remote__provisioning_8c_1ac777ea9bc4f18704e50b058c806ec41a" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>int</type>
        <definition>int linphone_remote_provisioning_download_and_apply</definition>
        <argsstring>(LinphoneCore *lc, const char *remote_provisioning_uri)</argsstring>
        <name>linphone_remote_provisioning_download_and_apply</name>
        <param>
          <type><ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref> *</type>
          <declname>lc</declname>
        </param>
        <param>
          <type>const char *</type>
          <declname>remote_provisioning_uri</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" line="102" column="1" bodyfile="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" bodystart="102" bodyend="130"/>
      </memberdef>
      <memberdef kind="function" id="group__initializing_1ga22afd021674ff152bc286eefdc9be0cd" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>void</type>
        <definition>void linphone_core_set_provisioning_uri</definition>
        <argsstring>(LinphoneCore *lc, const char *uri)</argsstring>
        <name>linphone_core_set_provisioning_uri</name>
        <param>
          <type><ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref> *</type>
          <declname>lc</declname>
        </param>
        <param>
          <type>const char *</type>
          <declname>uri</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
<para>Set URI where to download xml configuration file at startup. This can also be set from configuration file or factory config file, from [misc] section, item &quot;config-uri&quot;. Calling this function does not load the configuration. It will write the value into configuration so that configuration from remote URI will take place at next LinphoneCore start. <parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername>lc</parametername>
</parameternamelist>
<parameterdescription>
<para>the linphone core </para></parameterdescription>
</parameteritem>
<parameteritem>
<parameternamelist>
<parametername>uri</parametername>
</parameternamelist>
<parameterdescription>
<para>the http or https uri to use in order to download the configuration. </para></parameterdescription>
</parameteritem>
</parameterlist>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" line="132" column="1" bodyfile="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" bodystart="132" bodyend="134"/>
      </memberdef>
      <memberdef kind="function" id="group__initializing_1gafd1d893fa58a15873ab7848cf09c5df6" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>const char *</type>
        <definition>const char* linphone_core_get_provisioning_uri</definition>
        <argsstring>(const LinphoneCore *lc)</argsstring>
        <name>linphone_core_get_provisioning_uri</name>
        <param>
          <type>const <ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref> *</type>
          <declname>lc</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
<para>Get provisioning URI. <parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername>lc</parametername>
</parameternamelist>
<parameterdescription>
<para>the linphone core </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>the provisioning URI. </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" line="136" column="1" bodyfile="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" bodystart="136" bodyend="138"/>
      </memberdef>
      <memberdef kind="function" id="remote__provisioning_8c_1a130204d95049bd994029d01cd5f7bdbb" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>bool_t</type>
        <definition>bool_t linphone_core_is_provisioning_transient</definition>
        <argsstring>(LinphoneCore *lc)</argsstring>
        <name>linphone_core_is_provisioning_transient</name>
        <param>
          <type><ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref> *</type>
          <declname>lc</declname>
        </param>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
<para>Gets if the provisioning URI should be removed after it&apos;s been applied successfully <parameterlist kind="param"><parameteritem>
<parameternamelist>
<parametername>lc</parametername>
</parameternamelist>
<parameterdescription>
<para>the linphone core </para></parameterdescription>
</parameteritem>
</parameterlist>
<simplesect kind="return"><para>TRUE if the provisioning URI should be removed, FALSE otherwise </para></simplesect>
</para>        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" line="140" column="1" bodyfile="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c" bodystart="140" bodyend="142"/>
      </memberdef>
      </sectiondef>
    <briefdescription>
    </briefdescription>
    <detaileddescription>
    </detaileddescription>
    <programlisting>
<codeline lineno="1"><highlight class="comment">/*</highlight></codeline>
<codeline lineno="2"><highlight class="comment">remote_provisioning.c</highlight></codeline>
<codeline lineno="3"><highlight class="comment">Copyright<sp/>(C)<sp/>2010<sp/><sp/>Belledonne<sp/>Communications<sp/>SARL</highlight></codeline>
<codeline lineno="4"><highlight class="comment"></highlight></codeline>
<codeline lineno="5"><highlight class="comment">This<sp/>program<sp/>is<sp/>free<sp/>software;<sp/>you<sp/>can<sp/>redistribute<sp/>it<sp/>and/or</highlight></codeline>
<codeline lineno="6"><highlight class="comment">modify<sp/>it<sp/>under<sp/>the<sp/>terms<sp/>of<sp/>the<sp/>GNU<sp/>General<sp/>Public<sp/>License</highlight></codeline>
<codeline lineno="7"><highlight class="comment">as<sp/>published<sp/>by<sp/>the<sp/>Free<sp/>Software<sp/>Foundation;<sp/>either<sp/>version<sp/>2</highlight></codeline>
<codeline lineno="8"><highlight class="comment">of<sp/>the<sp/>License,<sp/>or<sp/>(at<sp/>your<sp/>option)<sp/>any<sp/>later<sp/>version.</highlight></codeline>
<codeline lineno="9"><highlight class="comment"></highlight></codeline>
<codeline lineno="10"><highlight class="comment">This<sp/>program<sp/>is<sp/>distributed<sp/>in<sp/>the<sp/>hope<sp/>that<sp/>it<sp/>will<sp/>be<sp/>useful,</highlight></codeline>
<codeline lineno="11"><highlight class="comment">but<sp/>WITHOUT<sp/>ANY<sp/>WARRANTY;<sp/>without<sp/>even<sp/>the<sp/>implied<sp/>warranty<sp/>of</highlight></codeline>
<codeline lineno="12"><highlight class="comment">MERCHANTABILITY<sp/>or<sp/>FITNESS<sp/>FOR<sp/>A<sp/>PARTICULAR<sp/>PURPOSE.<sp/><sp/>See<sp/>the</highlight></codeline>
<codeline lineno="13"><highlight class="comment">GNU<sp/>General<sp/>Public<sp/>License<sp/>for<sp/>more<sp/>details.</highlight></codeline>
<codeline lineno="14"><highlight class="comment"></highlight></codeline>
<codeline lineno="15"><highlight class="comment">You<sp/>should<sp/>have<sp/>received<sp/>a<sp/>copy<sp/>of<sp/>the<sp/>GNU<sp/>General<sp/>Public<sp/>License</highlight></codeline>
<codeline lineno="16"><highlight class="comment">along<sp/>with<sp/>this<sp/>program;<sp/>if<sp/>not,<sp/>write<sp/>to<sp/>the<sp/>Free<sp/>Software</highlight></codeline>
<codeline lineno="17"><highlight class="comment">Foundation,<sp/>Inc.,<sp/>59<sp/>Temple<sp/>Place<sp/>-<sp/>Suite<sp/>330,<sp/>Boston,<sp/>MA<sp/><sp/>02111-1307,<sp/>USA.</highlight></codeline>
<codeline lineno="18"><highlight class="comment">*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="19"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/>&quot;private.h&quot;</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="20"><highlight class="normal"></highlight><highlight class="preprocessor">#include<sp/>&quot;xml2lpc.h&quot;</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="21"><highlight class="normal"></highlight></codeline>
<codeline lineno="22"><highlight class="normal"></highlight><highlight class="preprocessor">#define<sp/>XML2LPC_CALLBACK_BUFFER_SIZE<sp/><sp/>1024</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="23"><highlight class="normal"></highlight></codeline>
<codeline lineno="24"><highlight class="normal"></highlight><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>xml2lpc_callback(</highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>*ctx,<sp/>xml2lpc_log_level<sp/>level,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*fmt,<sp/>va_list<sp/>list)<sp/>{</highlight></codeline>
<codeline lineno="25"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>buffer[XML2LPC_CALLBACK_BUFFER_SIZE];</highlight></codeline>
<codeline lineno="26"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>vsnprintf(buffer,<sp/>XML2LPC_CALLBACK_BUFFER_SIZE,<sp/>fmt,<sp/>list);</highlight></codeline>
<codeline lineno="27"><highlight class="normal"></highlight></codeline>
<codeline lineno="28"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(level<sp/>==<sp/>XML2LPC_ERROR)</highlight></codeline>
<codeline lineno="29"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>ms_error(</highlight><highlight class="stringliteral">&quot;%s&quot;</highlight><highlight class="normal">,<sp/>buffer);</highlight></codeline>
<codeline lineno="30"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(level<sp/>==<sp/>XML2LPC_WARNING)</highlight></codeline>
<codeline lineno="31"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>ms_warning(</highlight><highlight class="stringliteral">&quot;%s&quot;</highlight><highlight class="normal">,<sp/>buffer);</highlight></codeline>
<codeline lineno="32"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="comment">/*else</highlight></codeline>
<codeline lineno="33"><highlight class="comment"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>ms_message(&quot;%s&quot;,<sp/>buffer);<sp/>//<sp/>Don&apos;t<sp/>log<sp/>debug<sp/>messages<sp/>*/</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="34"><highlight class="normal">}</highlight></codeline>
<codeline lineno="35"><highlight class="normal"></highlight></codeline>
<codeline lineno="36"><highlight class="normal"></highlight><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>linphone_remote_provisioning_apply(<ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref><sp/>*lc,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*xml)<sp/>{</highlight></codeline>
<codeline lineno="37"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>xml2lpc_context<sp/>*context<sp/>=<sp/>xml2lpc_context_new(xml2lpc_callback,<sp/>lc);</highlight></codeline>
<codeline lineno="38"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>result<sp/>=<sp/>xml2lpc_set_xml_string(context,<sp/>xml);</highlight></codeline>
<codeline lineno="39"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*<sp/>error_msg<sp/>=<sp/>NULL;</highlight></codeline>
<codeline lineno="40"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(result<sp/>==<sp/>0)<sp/>{</highlight></codeline>
<codeline lineno="41"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="group__misc_1ga047b6550aab7dd244268e695fab98fd6" kindref="member">LpConfig</ref><sp/>*<sp/>lpc<sp/>=<sp/><ref refid="group__misc_1ga0634038b0304863380c65d6743448cab" kindref="member">linphone_core_get_config</ref>(lc);</highlight></codeline>
<codeline lineno="42"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>result<sp/>=<sp/>xml2lpc_convert(context,<sp/>lpc);</highlight></codeline>
<codeline lineno="43"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(result<sp/>==<sp/>0)<sp/>{</highlight></codeline>
<codeline lineno="44"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//<sp/>if<sp/>the<sp/>remote<sp/>provisioning<sp/>added<sp/>a<sp/>proxy<sp/>config<sp/>and<sp/>none<sp/>was<sp/>set<sp/>before,<sp/>set<sp/>it</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="45"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(<ref refid="group__misc_1ga15bf033627637f54ebc03380d5dfb2d1" kindref="member">lp_config_has_section</ref>(lpc,<sp/></highlight><highlight class="stringliteral">&quot;proxy_0&quot;</highlight><highlight class="normal">)<sp/>&amp;&amp;<sp/><ref refid="group__misc_1ga36d08c0cbc78d88fd4f043e61e9b9637" kindref="member">lp_config_get_int</ref>(lpc,<sp/></highlight><highlight class="stringliteral">&quot;sip&quot;</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">&quot;default_proxy&quot;</highlight><highlight class="normal">,<sp/>-1)<sp/>==<sp/>-1){</highlight></codeline>
<codeline lineno="46"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="group__misc_1gab7608c4c6b40a734eb00a4b398e47ba5" kindref="member">lp_config_set_int</ref>(lpc,<sp/></highlight><highlight class="stringliteral">&quot;sip&quot;</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">&quot;default_proxy&quot;</highlight><highlight class="normal">,<sp/>0);</highlight></codeline>
<codeline lineno="47"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="48"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="group__misc_1ga39f6f202e10581591ac6e68a636236bc" kindref="member">lp_config_sync</ref>(lpc);</highlight></codeline>
<codeline lineno="49"><highlight class="normal"></highlight></codeline>
<codeline lineno="50"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/>{</highlight></codeline>
<codeline lineno="51"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>error_msg<sp/>=<sp/></highlight><highlight class="stringliteral">&quot;xml<sp/>to<sp/>lpc<sp/>failed&quot;</highlight><highlight class="normal">;</highlight></codeline>
<codeline lineno="52"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="53"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/>{</highlight></codeline>
<codeline lineno="54"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>error_msg<sp/>=<sp/></highlight><highlight class="stringliteral">&quot;invalid<sp/>xml&quot;</highlight><highlight class="normal">;</highlight></codeline>
<codeline lineno="55"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="56"><highlight class="normal"></highlight></codeline>
<codeline lineno="57"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>xml2lpc_context_destroy(context);</highlight></codeline>
<codeline lineno="58"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>linphone_configuring_terminated(lc</highlight></codeline>
<codeline lineno="59"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>,error_msg<sp/>?<sp/>LinphoneConfiguringFailed<sp/>:<sp/>LinphoneConfiguringSuccessful</highlight></codeline>
<codeline lineno="60"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>,<sp/>error_msg);</highlight></codeline>
<codeline lineno="61"><highlight class="normal">}</highlight></codeline>
<codeline lineno="62"><highlight class="normal"></highlight></codeline>
<codeline lineno="63"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>linphone_remote_provisioning_load_file(<sp/><ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref>*<sp/>lc,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal">*<sp/>file_path){</highlight></codeline>
<codeline lineno="64"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>status<sp/>=<sp/>-1;</highlight></codeline>
<codeline lineno="65"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal">*<sp/>provisioning=ms_load_path_content(file_path,<sp/>NULL);</highlight></codeline>
<codeline lineno="66"><highlight class="normal"></highlight></codeline>
<codeline lineno="67"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(provisioning){</highlight></codeline>
<codeline lineno="68"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>linphone_remote_provisioning_apply(lc,<sp/>provisioning);</highlight></codeline>
<codeline lineno="69"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>status<sp/>=<sp/>0;</highlight></codeline>
<codeline lineno="70"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>ms_free(provisioning);</highlight></codeline>
<codeline lineno="71"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="72"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>status;</highlight></codeline>
<codeline lineno="73"><highlight class="normal">}</highlight></codeline>
<codeline lineno="74"><highlight class="normal"></highlight></codeline>
<codeline lineno="75"><highlight class="normal"></highlight><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>belle_request_process_response_event(</highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>*ctx,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/>belle_http_response_event_t<sp/>*event)<sp/>{</highlight></codeline>
<codeline lineno="76"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref><sp/>*lc<sp/>=<sp/>(<ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref><sp/>*)ctx;</highlight></codeline>
<codeline lineno="77"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>belle_sip_message_t<sp/>*message<sp/>=<sp/>BELLE_SIP_MESSAGE(event-&gt;response);</highlight></codeline>
<codeline lineno="78"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*body<sp/>=<sp/>belle_sip_message_get_body(message);</highlight></codeline>
<codeline lineno="79"><highlight class="normal"></highlight></codeline>
<codeline lineno="80"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal"><sp/>(belle_http_response_get_status_code(event-&gt;response)<sp/>==<sp/>200)<sp/>{</highlight></codeline>
<codeline lineno="81"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>linphone_remote_provisioning_apply(lc,<sp/>body);</highlight></codeline>
<codeline lineno="82"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/>{</highlight></codeline>
<codeline lineno="83"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>linphone_configuring_terminated(lc,<sp/>LinphoneConfiguringFailed,<sp/></highlight><highlight class="stringliteral">&quot;http<sp/>error&quot;</highlight><highlight class="normal">);</highlight></codeline>
<codeline lineno="84"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="85"><highlight class="normal">}</highlight></codeline>
<codeline lineno="86"><highlight class="normal"></highlight></codeline>
<codeline lineno="87"><highlight class="normal"></highlight><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>belle_request_process_io_error(</highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>*ctx,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/>belle_sip_io_error_event_t<sp/>*event)<sp/>{</highlight></codeline>
<codeline lineno="88"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref><sp/>*lc<sp/>=<sp/>(<ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref><sp/>*)ctx;</highlight></codeline>
<codeline lineno="89"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>linphone_configuring_terminated(lc,<sp/>LinphoneConfiguringFailed,<sp/></highlight><highlight class="stringliteral">&quot;http<sp/>io<sp/>error&quot;</highlight><highlight class="normal">);</highlight></codeline>
<codeline lineno="90"><highlight class="normal">}</highlight></codeline>
<codeline lineno="91"><highlight class="normal"></highlight></codeline>
<codeline lineno="92"><highlight class="normal"></highlight><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>belle_request_process_timeout(</highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>*ctx,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/>belle_sip_timeout_event_t<sp/>*event)<sp/>{</highlight></codeline>
<codeline lineno="93"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref><sp/>*lc<sp/>=<sp/>(<ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref><sp/>*)ctx;</highlight></codeline>
<codeline lineno="94"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>linphone_configuring_terminated(lc,<sp/>LinphoneConfiguringFailed,<sp/></highlight><highlight class="stringliteral">&quot;http<sp/>timeout&quot;</highlight><highlight class="normal">);</highlight></codeline>
<codeline lineno="95"><highlight class="normal">}</highlight></codeline>
<codeline lineno="96"><highlight class="normal"></highlight></codeline>
<codeline lineno="97"><highlight class="normal"></highlight><highlight class="keyword">static</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>belle_request_process_auth_requested(</highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/>*ctx,<sp/>belle_sip_auth_event_t<sp/>*event)<sp/>{</highlight></codeline>
<codeline lineno="98"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref><sp/>*lc<sp/>=<sp/>(<ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref><sp/>*)ctx;</highlight></codeline>
<codeline lineno="99"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>linphone_configuring_terminated(lc,<sp/>LinphoneConfiguringFailed,<sp/></highlight><highlight class="stringliteral">&quot;http<sp/>auth<sp/>requested&quot;</highlight><highlight class="normal">);</highlight></codeline>
<codeline lineno="100"><highlight class="normal">}</highlight></codeline>
<codeline lineno="101"><highlight class="normal"></highlight></codeline>
<codeline lineno="102"><highlight class="normal"></highlight><highlight class="keywordtype">int</highlight><highlight class="normal"><sp/>linphone_remote_provisioning_download_and_apply(<ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref><sp/>*lc,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*remote_provisioning_uri)<sp/>{</highlight></codeline>
<codeline lineno="103"><highlight class="normal"></highlight></codeline>
<codeline lineno="104"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>belle_generic_uri_t<sp/>*uri=belle_generic_uri_parse(remote_provisioning_uri);</highlight></codeline>
<codeline lineno="105"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal">*<sp/>scheme<sp/>=<sp/>uri<sp/>?<sp/>belle_generic_uri_get_scheme(uri)<sp/>:<sp/>NULL;</highlight></codeline>
<codeline lineno="106"><highlight class="normal"></highlight></codeline>
<codeline lineno="107"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal">(<sp/>scheme<sp/>&amp;&amp;<sp/>(strcmp(scheme,</highlight><highlight class="stringliteral">&quot;file&quot;</highlight><highlight class="normal">)<sp/>==<sp/>0)<sp/>){</highlight></codeline>
<codeline lineno="108"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="comment">//<sp/>We<sp/>allow<sp/>for<sp/>&apos;local<sp/>remote-provisioning&apos;<sp/>in<sp/>case<sp/>the<sp/>file<sp/>is<sp/>to<sp/>be<sp/>opened<sp/>from<sp/>the<sp/>hard<sp/>drive.</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="109"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal">*<sp/>file_path<sp/>=<sp/>remote_provisioning_uri<sp/>+<sp/>strlen(</highlight><highlight class="stringliteral">&quot;file://&quot;</highlight><highlight class="normal">);<sp/></highlight><highlight class="comment">//<sp/>skip<sp/>scheme</highlight><highlight class="normal"></highlight></codeline>
<codeline lineno="110"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>linphone_remote_provisioning_load_file(lc,<sp/>file_path);</highlight></codeline>
<codeline lineno="111"><highlight class="normal"></highlight></codeline>
<codeline lineno="112"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordflow">if</highlight><highlight class="normal">(<sp/>scheme<sp/>&amp;&amp;<sp/>strncmp(scheme,<sp/></highlight><highlight class="stringliteral">&quot;http&quot;</highlight><highlight class="normal">,<sp/>4)<sp/>==<sp/>0<sp/>)<sp/>{</highlight></codeline>
<codeline lineno="113"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>belle_http_request_listener_callbacks_t<sp/>belle_request_listener={0};</highlight></codeline>
<codeline lineno="114"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>belle_http_request_listener_t<sp/>*listener;</highlight></codeline>
<codeline lineno="115"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>belle_http_request_t<sp/>*request;</highlight></codeline>
<codeline lineno="116"><highlight class="normal"></highlight></codeline>
<codeline lineno="117"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>belle_request_listener.process_response=belle_request_process_response_event;</highlight></codeline>
<codeline lineno="118"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>belle_request_listener.process_auth_requested=belle_request_process_auth_requested;</highlight></codeline>
<codeline lineno="119"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>belle_request_listener.process_io_error=belle_request_process_io_error;</highlight></codeline>
<codeline lineno="120"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>belle_request_listener.process_timeout=belle_request_process_timeout;</highlight></codeline>
<codeline lineno="121"><highlight class="normal"></highlight></codeline>
<codeline lineno="122"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>listener<sp/>=<sp/>belle_http_request_listener_create_from_callbacks(&amp;belle_request_listener,<sp/>lc);</highlight></codeline>
<codeline lineno="123"><highlight class="normal"></highlight></codeline>
<codeline lineno="124"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>request=belle_http_request_create(</highlight><highlight class="stringliteral">&quot;GET&quot;</highlight><highlight class="normal">,uri,<sp/>NULL);</highlight></codeline>
<codeline lineno="125"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>belle_http_provider_send_request(lc-&gt;http_provider,<sp/>request,<sp/>listener);</highlight></codeline>
<codeline lineno="126"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>}<sp/></highlight><highlight class="keywordflow">else</highlight><highlight class="normal"><sp/>{</highlight></codeline>
<codeline lineno="127"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>ms_error(</highlight><highlight class="stringliteral">&quot;Invalid<sp/>provisioning<sp/>URI<sp/>[%s]<sp/>(missing<sp/>scheme?)&quot;</highlight><highlight class="normal">,remote_provisioning_uri);</highlight></codeline>
<codeline lineno="128"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/>-1;</highlight></codeline>
<codeline lineno="129"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/>}</highlight></codeline>
<codeline lineno="130"><highlight class="normal">}</highlight></codeline>
<codeline lineno="131"><highlight class="normal"></highlight></codeline>
<codeline lineno="132"><highlight class="normal"></highlight><highlight class="keywordtype">void</highlight><highlight class="normal"><sp/><ref refid="group__initializing_1ga22afd021674ff152bc286eefdc9be0cd" kindref="member">linphone_core_set_provisioning_uri</ref>(<ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref><sp/>*lc,<sp/></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal"><sp/>*uri)<sp/>{</highlight></codeline>
<codeline lineno="133"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/><ref refid="group__misc_1ga2b9f058c7b12d124be96149100d9b079" kindref="member">lp_config_set_string</ref>(lc-&gt;config,</highlight><highlight class="stringliteral">&quot;misc&quot;</highlight><highlight class="normal">,</highlight><highlight class="stringliteral">&quot;config-uri&quot;</highlight><highlight class="normal">,uri);</highlight></codeline>
<codeline lineno="134"><highlight class="normal">}</highlight></codeline>
<codeline lineno="135"><highlight class="normal"></highlight></codeline>
<codeline lineno="136"><highlight class="normal"></highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/></highlight><highlight class="keywordtype">char</highlight><highlight class="normal">*<ref refid="group__initializing_1gafd1d893fa58a15873ab7848cf09c5df6" kindref="member">linphone_core_get_provisioning_uri</ref>(</highlight><highlight class="keyword">const</highlight><highlight class="normal"><sp/><ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref><sp/>*lc){</highlight></codeline>
<codeline lineno="137"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/><ref refid="group__misc_1ga9657ebf1d68b43184a796c9bdc68c29a" kindref="member">lp_config_get_string</ref>(lc-&gt;config,</highlight><highlight class="stringliteral">&quot;misc&quot;</highlight><highlight class="normal">,</highlight><highlight class="stringliteral">&quot;config-uri&quot;</highlight><highlight class="normal">,NULL);</highlight></codeline>
<codeline lineno="138"><highlight class="normal">}</highlight></codeline>
<codeline lineno="139"><highlight class="normal"></highlight></codeline>
<codeline lineno="140"><highlight class="normal">bool_t<sp/>linphone_core_is_provisioning_transient(<ref refid="group__initializing_1gaa5cf635b82dd338e7ee2dd3599d05f0a" kindref="member">LinphoneCore</ref><sp/>*lc)<sp/>{</highlight></codeline>
<codeline lineno="141"><highlight class="normal"><sp/><sp/><sp/><sp/><sp/><sp/><sp/><sp/></highlight><highlight class="keywordflow">return</highlight><highlight class="normal"><sp/><ref refid="group__misc_1ga36d08c0cbc78d88fd4f043e61e9b9637" kindref="member">lp_config_get_int</ref>(lc-&gt;config,<sp/></highlight><highlight class="stringliteral">&quot;misc&quot;</highlight><highlight class="normal">,<sp/></highlight><highlight class="stringliteral">&quot;transient_provisioning&quot;</highlight><highlight class="normal">,<sp/>0)<sp/>==<sp/>1;</highlight></codeline>
<codeline lineno="142"><highlight class="normal">}</highlight></codeline>
    </programlisting>
    <location file="C:/Jenkins/workspace/linphone-gtk-win32/coreapi/remote_provisioning.c"/>
  </compounddef>
</doxygen>
