liyuanwei / imsdroid

Automatically exported from code.google.com/p/imsdroid
0 stars 0 forks source link

How to add parameter of any SIP message header? #122

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1.I want to add a parameter of SIP message header.
2.For example,"Session-Expires: 3600;refresher=uac" and "Accept-Contact: 
*;+g.oma.sip-im"
3.addCaps() method of SipSession class only can add parameter of Contact 
header.So no method can be called to add parameter of any SIP message 
header,such as "Accept-Contact: *;+g.oma.sip-im"
What is the expected output? What do you see instead?

What version of the product are you using? On what operating system?

Please provide any additional information below.

Original issue reported on code.google.com by yuwenbin...@gmail.com on 11 Dec 2010 at 5:38

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
You should not use addHeader() to enable session timers.
-To enable session timers use CallSession::setSessionTimer(long timeout, String 
refresher) which will add the header.

-To add a header with parameter you can use addHeader like this: 
addHeader("MyHeader", "value;test=v1");

-addCaps() will add "Accept-Contact" header if the request doesn't contain a 
"Contact" header (e.g. PUBLISH, MESSAGE,...) otherwise the caps will be added 
to the "Contact" header.
You can also do this: addHeader("Accept-Contact", "*;+g.oma.sip-im");

Original comment by boss...@yahoo.fr on 13 Dec 2010 at 5:39

GoogleCodeExporter commented 9 years ago
Thank you very much for your response.

Original comment by yuwenbin...@gmail.com on 13 Dec 2010 at 6:00

GoogleCodeExporter commented 9 years ago
For information, I have published the alpha version of our windows client 
(http://code.google.com/p/boghe/) if you want to test it.

Original comment by boss...@yahoo.fr on 13 Dec 2010 at 6:13

GoogleCodeExporter commented 9 years ago
Ha,in fact,I have been studying source code of IMSDroid project based on 
doubango.

Original comment by yuwenbin...@gmail.com on 13 Dec 2010 at 6:21

GoogleCodeExporter commented 9 years ago
doubango is not built with OpenSSL.

Original comment by yuwenbin...@gmail.com on 13 Dec 2010 at 6:22

GoogleCodeExporter commented 9 years ago

Original comment by boss...@yahoo.fr on 24 Dec 2010 at 12:34