liyuanwei / imsdroid

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

sending message by sip message method #189

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I can't solute the follow problems
1.return 202(Accepted for later delivery) or 400(Bad request) when call the 
messagingSession::send().
2.return 903(Dialog terminated) in SipService::OnDialogEvent()
3.the client or runing on android platform no response

Ehe core codes:
remoteUri = UriUtils.makeValidSipUri(remoteUri);
if(sipStack.getSigCompId() != 
null){      session.addSigCompCompartment(sipStack.getSigCompId());
  }
session.addHeader("Proxy-Authorization", "Digest realm=\"sip2sip.info\"");
session.setToUri(remoteUri);
session.addHeader("Content-Type", "text/plain");
final ByteBuffer payload = ByteBuffer.allocateDirect(content.length);
payload.put(content);
success = session.send(payload, content.length);

providing any help for me,please.

Original issue reported on code.google.com by sundl2...@gmail.com on 28 Feb 2011 at 8:40

GoogleCodeExporter commented 9 years ago
You MUST not add "Proxy-Authorization" header. The stack will automatically add 
this header if required (e.g when we receive a 401/407 response).
Please attach the network (Wireshark) trace.

Original comment by boss...@yahoo.fr on 28 Feb 2011 at 9:18

GoogleCodeExporter commented 9 years ago
hi,
If I did't add "Proxy-Authorization" header. It' will be note respose "407" in 
the network(Wireshark) trace and two functions SipService::OnDialogEvent() and 
SipService::OnMessagingEvent() will not be call.

Original comment by sundl2...@gmail.com on 1 Mar 2011 at 5:20

Attachments:

GoogleCodeExporter commented 9 years ago
If I add "Proxy-Authorization" header. It will return 202 or 400(sometime)

Original comment by sundl2...@gmail.com on 1 Mar 2011 at 5:22

Attachments:

GoogleCodeExporter commented 9 years ago

Original comment by boss...@yahoo.fr on 5 Jun 2011 at 5:23