Hey

Jeff Sharrow wrote:
Hello,

I am running kannel 1.4 on a test server. I have been able to submit a message to the PPG portion of kannel using test_ppg and have it delivered to phone through my SMSC. What I am having a problem with is that I want to send a service indicator message with using the test_ppg. I found a perl script that does most of what I want, but kannel replies with bad formatting. I have done captures at the packet level of both the test_PPG from another machine to my test server and from my perl script. The only things that I cannot get to match up are the X-wap-Application-Id and the following which I will pull from the packet capture:


MIME Multipart Media Encapsulation, Type: multipart/related, Boundary: "asdlfkjiurwghasf"

    Type: multipart/related


You don't have to match up any headers. This is a basic example (taken from elsewhere in the archives:

Content-Type: multipart/related; type=application/xml; boundary=WPL38woVbhESdfalYevGqpdzLCs

--WPL38woVbhESdfalYevGqpdzLCs
Content-Type: application/xml; charset=UTF-8

<?xml version="1.0"?>
<!DOCTYPE pap PUBLIC "-//WAPFORUM//DTD PAP 1.0//EN" "http://www.wapforum.org/DTD/pap_1.0.dtd";>
<pap>
<push-message push-id="64062/198/Openwave Push">
<address address-value="WAPPUSH=+571585****/[EMAIL PROTECTED]"/>
<quality-of-service delivery-method="unconfirmed" network="GSM" network-required="true" bearer="SMS" bearer-required="true"/>
</push-message>
</pap>
--WPL38woVbhESdfalYevGqpdzLCs
Content-Type: text/vnd.wap.si; charset=UTF-8

<?xml version="1.0"?>
<!DOCTYPE si PUBLIC "-//WAPFORUM//DTD SI 1.0//EN"
"http://www.wapforum.org/DTD/si.dtd";>
<si>
<indication href=""http://192.168.*.*/wapi/index.php";>http://192.168.*.*/wapi/index.php"; action="">
Alerta Kannel
</indication>
</si>
--WPL38woVbhESdfalYevGqpdzLCs--


The content type is just set to what the Content-Type says above and the rest is just the content of the post. No magic. The only thing that got me when I started with this was that you have to have \r\n as the line ending.


Cheers,

Gareth


--
Gareth Reakes, Managing Director      Parthenon Computing
+44-1865-811184                  http://www.parthcomp.com

Reply via email to