Closed GoogleCodeExporter closed 9 years ago
I am also getting 401 unauthorized when i am trying to register with asterisk
server.Please help to solve the issue.
Thanks
Original comment by errach...@gmail.com
on 31 Mar 2009 at 11:46
Hi All,
I am also facing the same issue while registering with asterisk server.can any
body help me to solve the problem.
Thanks in Advance
Original comment by allath...@gmail.com
on 1 Apr 2009 at 2:47
hi
this problem is result of someone changed my code :)
in SIPUser.java there is no use of "realm" just proxy value while in the
function:
public void register() it try to use realm
ra = new SIPRegisterAgent( sip_provider, user_profile.fromUrl,
user_profile.contactUrl, username,
user_profile.realm, password, this );
to fix it:
line 136 add "private String realm;"
line 181 add "this.realm = realm;"
line 183 change to be like:"String fromURL = "\"" + phone + "\" <sip:" + phone
+ "@"
+ realm + ">";"
problem solved!!!
BR,
Lior
Original comment by lior.her...@gmail.com
on 2 Apr 2009 at 7:30
1. I can't reproduce this error
2. If we use realm in fromURL, it will be a problem when realm name is not an
address. For example, for Asterisk the default realm of asterisk is "asterisk"
and
for Cisco call manager is "sipline"
Original comment by olajide....@gmail.com
on 4 Apr 2009 at 2:57
hi
in sip stack extendedInviteDialog.java was old for handling correct 401 error
with
new branch.
2nd thing is to fixed this realm,domain,proxy once and for all.
the realm is osmething that use only in Authentication header and can be any
string
like "asterisk" or "spiderman".
the current way we use realm in the code is should be reffer as Proxy or Domain
and
the value we use in Proxy should be called "outbound proxy".
so To: and From: header should be "subscriber@proxy", but the meesage should be
send
to the outbound proxy ip. the realm should be used only in realm="value" in WWW-
Authentication header. this value can be exteracted automaticlly from the 401
or
407 authentication challenge.
to solve it can leave realm and proxy as it is and read outbound_proxy from
sip.cfg,
but as far as i see red5 standalone do not use sip.cfg
Original comment by lior.her...@gmail.com
on 6 Apr 2009 at 2:21
So best thing would be to pass it from client API and softphones
Original comment by olajide....@gmail.com
on 7 Apr 2009 at 12:26
I can't reproduce this error still.
lior.her...@suomenpuhelin.com,
why the sipphone mapping( plugin of openfire) can test sip config success?
Original comment by louli2...@gmail.com
on 21 Apr 2009 at 2:23
ok i find a method!handle the sip register 401&407 failer
refresh new brach id in mjsiplib ExtendedInviteDialog.onTransFailureResponse
code like this:
ViaHeader v=(ViaHeader)req.getViaHeader();
v.setBranch(SipProvider.pickBranch());
req.removeViaHeader();
req.addViaHeader(v);
Original comment by louli2...@gmail.com
on 21 Apr 2009 at 2:48
Original issue reported on code.google.com by
chengwei...@gmail.com
on 27 Mar 2009 at 8:08