This Question is Possibly Answered

1 "correct" answer available (10 pts) 1 "helpful" answer available (5 pts)
7,915 Views 17 Replies Last post: Jan 6, 2009 2:36 AM by gouriprasad RSS
Bronze 6 posts since
May 16, 2008
Currently Being Moderated

May 17, 2008 7:22 AM

Red5, SIP Phone, Sparkweb

 

I would like to thank and congratulate dele for this contribution.

 

 

I've installed an asterisk system in my company and later on I added the openfire server, which opened some doors to missing functions we were expecting from our service. The goal here was to have a single application which would like just as skype, centralizing file transfers, chat, conferences and phone calls. Sometimes, however, our employees are in mission at companies whose networks block much of the traffic and that's where I think red5 would come in handy.

 

 

The idea is that we could connect to our jabber accounts through a web browser and have access to the company's phone line thanks to the sparkweb integration, all in a unified and good looking window. I guess many other people expect this same behaviour. The thing is, I can't get it to work so far.

 

 

1- when I access the red5 test page and fill in with my proxy settings, I can register to my SIP account and even make a call (internal and externally), but dtmf does not work, so it's kinda useless for voicemail retrieval or other things that require dialing some keys. The main problem, however, is that once I go to the sparkweb page (either by changing the url or by following the link) and login to my account, I get along with my contact list a window which states "SIP Phone Error - 401 Unauthorized". I also noted that my sip peers status on asterisk is Unreachable rather than ok and once I quit the browser, it is still the same for long after.

 

 

2 - When I enter sparkweb, why should I fill in the server information?? It looks a bit obvious to me that if we reach that url, the jabber server we're looking for is pretty obvious. My complaint is rather that I find it confusing the fact the it does not accept localhost as a value and I always need to enter my server's IP address.

 

 

3 - The flash application which is running on my browser window communicates with my jabber server through which ports? I wish all communication would go through standard http, even voice... is it possible? Where could I get some details about the connections' architecture??

 

 

4 - Am I doing something wrong or the button "exit sparkweb" does not work?

 

 

Thanks for your help and attention, please keep up this good work.

 

 

Dele Olajide KeyContributor 452 posts since
Apr 10, 2006
Currently Being Moderated
May 17, 2008 10:01 AM in response to: André
Re: Red5, SIP Phone, Sparkweb

>SIP Phone Error - 401 Unauthorized".

 

I assume you are using the SIP plugin for openfire to setup the SIP profile for the user and you that you have first confirmed that this works with Spark. The Admin console web page for the SIP user profile show show "registered" or whatever the status is.

 

>I also noted that my sip peers status on asterisk is Unreachable rather than ok

 

Another bug in MjSIP that has been identified. Set Qualify=no in Asterisk as a temp solution

 

>When I enter sparkweb, why should I fill in the server information??

 

There is thread in the Spark community right now about changes that you want to see. I suggest you register this suggestion there.

 

>I wish all communication would go through standard http, even voice... is it possible?

 

Flash by default, makes an RTMP connection on port 1935. All media (audio/video) is transmitted both ways over mulitple streams. Flash will also tunnel RTMP over HTTP. That is called RTMPT. Change your Red5 URL to rtmpt://your_server:8000/sip instead if rtmp:/sip. If port 8000 does do work for you look for the file plugins/red5/WEB-INF/classes/red5-rtmpt.xml and edit it accordingly.  You can't use the HTTP-Bind port.

 

>exit sparkweb" does not work?

 

If you look at SparkWeb source code you will see "not implemented yet"

 

>but dtmf does not work

 

It is working in latest version. No audio feedback but it works for RFC2833 type DTMF which is the default for Asterisk. DTMF with INFO messages is not yet implemented. It works on my Asterisk and public phone numbers in the UK. I have not added this to SparkWeb yet.

 

>Thanks for your help and attention, please keep up this good work.

 

You are welcome.   It is however a challenge to juggle all this with a full time day job.

Dele Olajide KeyContributor 452 posts since
Apr 10, 2006
Currently Being Moderated
May 19, 2008 2:52 AM in response to: André
Re: Red5, SIP Phone, Sparkweb

>On the other hand, the /red5/sparkweb/ section uses the parameters set both on the red5 (the red5 URL being that initially set with rtmp:/somewierdaddress which I have changed to rtmpt://220.110.24.198:8000/sip) admin section and the sip phone section

 

My bad!!. It does not. I missed that opportunity. SparkWeb does a service discovery to get SIP parameters, but does not query the Red5 plugin. It is hard-coded with rtmp/sip.

 

From com/jivesoftware/spark/managers/SiparkManager.as

 

 

>          private function login():void {     

>             & nbsp; netConnection.connect("rtmp:/sip");

>             & nbsp; setStatus("Registering");

>          }

>

 

Thanks for finding this. I will try and fix this as soon as I possibly can. I have made a few changes to MjSIP, so upgrade to latest version if you can.

-dele

Dele Olajide KeyContributor 452 posts since
Apr 10, 2006
Currently Being Moderated
May 19, 2008 3:17 AM in response to: André
Re: Red5, SIP Phone, Sparkweb

The lastest fixes will always be at http://red5.4ng.net/red5.war while the stable version will be on igniterealtime.

 

As your asterisk and openfire installs are on the same server and are both listening on UDP, you have to make sure your MjSIP ports (SIP & RTP) do not clash with Asterisk. It think asterisk config is in etc/asterisk/udp.conf. Latest version is 0.0.20 and it only fixes the problem with incoming calls sometimes being ignored. I saw the SIP messages, but can't analyse them right now.

 

-dele

Bruce Silver 139 posts since
Jul 26, 2007
Currently Being Moderated
May 25, 2008 8:03 PM in response to: Dele Olajide
Re: Red5, SIP Phone, Sparkweb

Hi Dele like the new plugin very much.But am having trubles setting up the openfire sip gatway I keep getting phone not registered no matter how I program the sip.I have even got a Gizmo account witch the gatway connects fine but nun of the client side apps will register.I am not sure what I mite be doing wrong.I cant find any error or debug that mite shed any light on this.So I am lost  :_|

 

Bruce

Dele Olajide KeyContributor 452 posts since
Apr 10, 2006
Currently Being Moderated
May 26, 2008 1:53 AM in response to: Bruce
Re: Red5, SIP Phone, Sparkweb

Hi Bruce,

 

>I have even got a Gizmo account which the gatway connects fine but none of the client side apps will register

 

Can you give us a bit more info on what you are doing. Are you trying to us the Red5Phone Flex (connects directly to SIP from MjSIP inside Red5 Plugin) or are you trying to use SparkWeb which uses Red5Phone with Openfire SIP plugin or are you trying to make this work with the old Red5Gateway?

 

-dele

Bruce Silver 139 posts since
Jul 26, 2007
Currently Being Moderated
May 26, 2008 6:59 AM in response to: Dele Olajide
Re: Red5, SIP Phone, Sparkweb

I am running openfire 3.5.1 red5 v0.0.21 on windowsxp to .All clients including the flash phone shoe in admin page as

RegistrationFailed on the  sip phone  admin page spark web when I click the phone icon get the message phone not registerd.I am using the openfire sip plugin cant fined any error or debug logs that aply to using the sip just

RegistrationFailed.I wish I had more info but there is nun.should I have any spacific type of sip server installed on my system.As for Gizmo I have an account and used ther sip gateway connection setup got this when I run the test

SIP Account Successfully Tested.But sparkweb and spark get the same RegistrationFailed and if I try to make a phone call with the falsh pnone on the gizmo account the call will not work.There is nothing in the logs to post .It seems the problem is the clients registering with the openfire sip phone plugin.

Dele Olajide KeyContributor 452 posts since
Apr 10, 2006
Currently Being Moderated
May 26, 2008 9:12 AM in response to: Bruce
Re: Red5, SIP Phone, Sparkweb

>.I wish I had more info but there is nun.

 

The SIP client log files are in the logs folder and are named xxxx.xxxx.xxxx.xxxx:nnnn_messages and xxxx.xxxx.xxxx.xxxx:nnnn_events. Look in stdout.log, red5.log and red5error.log for the Red5 plugin log messages.

 

-dele

Bruce Silver 139 posts since
Jul 26, 2007
Currently Being Moderated
May 26, 2008 2:19 PM in response to: Dele Olajide
Re: Red5, SIP Phone, Sparkweb

 

here is spark error logs

 

 

net.java.sipmack.sip.CommunicationsException: Could not create a register transaction!

Check that the Registrar address is correct!

at net.java.sipmack.sip.RegisterProcessing.register(RegisterProcessing.java:315)

at net.java.sipmack.sip.SipManager.register(SipManager.java:575)

at net.java.sipmack.sip.SipManager.startRegisterProcess(SipManager.java:615)

at net.java.sipmack.softphone.SoftPhoneManager.handleRegisterRequest(SoftPhoneMana ger.java:393)

at net.java.sipmack.softphone.SoftPhoneManager$2.run(SoftPhoneManager.java:910)

at java.lang.Thread.run(Unknown Source)

javax.sip.InvalidArgumentException: Address already in use: Cannot bind

at gov.nist.javax.sip.SipStackImpl.createListeningPoint(SipStackImpl.java:678)

at net.java.sipmack.sip.SipManager.start(SipManager.java:304)

at net.java.sipmack.sip.SipManager.registrationFailed(SipManager.java:665)

at net.java.sipmack.sip.SipManager.fireRegistrationFailed(SipManager.java:1279)

at net.java.sipmack.sip.RegisterProcessing.register(RegisterProcessing.java:333)

at net.java.sipmack.sip.SipManager.register(SipManager.java:575)

at net.java.sipmack.sip.SipManager.startRegisterProcess(SipManager.java:615)

at net.java.sipmack.softphone.SoftPhoneManager.handleRegisterRequest(SoftPhoneMana ger.java:393)

at net.java.sipmack.softphone.SoftPhoneManager$2.run(SoftPhoneManager.java:910)

at java.lang.Thread.run(Unknown Source)

Caused by: java.io.IOException: Address already in use: Cannot bind

at gov.nist.javax.sip.stack.UDPMessageProcessor.<init>(UDPMessageProcessor.j ava:141)

at gov.nist.javax.sip.stack.SIPTransactionStack.createMessageProcessor(SIPTransact ionStack.java:1669)

at gov.nist.javax.sip.SipStackImpl.createListeningPoint(SipStackImpl.java:659)

... 9 more

net.java.sipmack.sip.CommunicationsException: Could not create a register transaction!

Check that the Registrar address is correct!

at net.java.sipmack.sip.RegisterProcessing.register(RegisterProcessing.java:315)

at net.java.sipmack.sip.SipManager.register(SipManager.java:575)

at net.java.sipmack.sip.SipManager.register(SipManager.java:523)

at net.java.sipmack.sip.SipManager.registrationFailed(SipManager.java:667)

at net.java.sipmack.sip.SipManager.fireRegistrationFailed(SipManager.java:1279)

at net.java.sipmack.sip.RegisterProcessing.register(RegisterProcessing.java:333)

at net.java.sipmack.sip.SipManager.register(SipManager.java:575)

 

 

red5 logs

 

 

2008-05-26 08:36:45,703 pool-9-thread-1 INFO  org.red5.server.jmx.JMXAgent - JMX HTML adapter was not enabled

2008-05-26 08:36:45,718 pool-9-thread-1 INFO  org.red5.server.jmx.JMXAgent - JMX RMI adapter was not enabled

2008-05-26 08:36:49,265 pool-9-thread-1 INFO  o.r.s.net.rtmp.RTMPMinaTransport - RTMP Mina Transport Settings

2008-05-26 08:36:49,281 pool-9-thread-1 INFO  o.r.s.net.rtmp.RTMPMinaTransport - IO Threads: 2

2008-05-26 08:36:49,281 pool-9-thread-1 INFO  o.r.s.net.rtmp.RTMPMinaTransport - Event Threads - core: 4, max: 8, queue: -1, keepalive: 60

2008-05-26 08:36:49,531 pool-9-thread-1 INFO  o.r.s.net.rtmp.RTMPMinaTransport - TCP No Delay: true

2008-05-26 08:36:49,546 pool-9-thread-1 INFO  o.r.s.net.rtmp.RTMPMinaTransport - Receive Buffer Size: 65536

2008-05-26 08:36:49,562 pool-9-thread-1 INFO  o.r.s.net.rtmp.RTMPMinaTransport - Send Buffer Size: 271360

2008-05-26 08:36:49,687 pool-9-thread-1 INFO  o.r.s.net.rtmp.RTMPMinaTransport - RTMP Mina Transport bound to 0.0.0.0/0.0.0.0:1935

2008-05-26 08:36:49,703 pool-9-thread-1 INFO  org.red5.server.jmx.JMXFactory - Object name: org.red5.server:type=RTMPMinaTransport,address=0.0.0.0,port=1935

2008-05-26 08:36:49,734 pool-9-thread-1 INFO  org.red5.server.jmx.JMXFactory - Object name: org.red5.server:type=IoServiceManager,address=0.0.0.0,port=1935

 

 

 

 

 

red5 error logs empty

 

 

can I have sample  of a working sip user set up I have tried many thay all do the same I used the instructions from gizmo sip setup the gismo account. 

 

 

 

 

 

 

 

 

Joe Perez Bronze 50 posts since
Jan 3, 2008
Currently Being Moderated
May 26, 2008 2:54 PM in response to: Dele Olajide
Re: Red5, SIP Phone, Sparkweb

Same problem here too, this is from the openfire error log file

 

Let me back up.  In the version 3.4.3 of openfire without ever having installed red5 (didn't know about it) the SIP plugin worked sucessfully with Gizmo Account settings.  Since openfire's revisions I have not been able to get a connections with SIP support at all for a Gizmo account to register in openfire.  Below is a copy of the error log in openfire when trying to register with Gizmo with the SIP support plugin.  Hopefully someone could lend a helping hand on this error.  Thank you for your time.

 

Gizmo Settings:

 

server:  proxy01.sipphone.com

port: 5060

**described setting on gizmo site: proxy01.sipphone.com:5060

 

stun: stun01.sipphone.com

stun port: 3478

**described setting on gizmo site: stun01.sipphone.com:3478

 

2008.05.26 10:12:28 org.jivesoftware.openfire.stun.STUNService.startLocalServer(STUNService.java:161 )

Disabling STUN server

java.net.BindException: Cannot assign requested address: Cannot bind

at java.net.PlainDatagramSocketImpl.bind0(Native Method)

at java.net.PlainDatagramSocketImpl.bind(Unknown Source)

at java.net.DatagramSocket.bind(Unknown Source)

at java.net.DatagramSocket.<init>(Unknown Source)

at java.net.DatagramSocket.<init>(Unknown Source)

at de.javawi.jstun.test.demo.StunServer.<init>(StunServer.java:32)

at org.jivesoftware.openfire.stun.STUNService.startLocalServer(STUNService.java:15 4)

at org.jivesoftware.openfire.stun.STUNService.start(STUNService.java:143)

at org.jivesoftware.openfire.XMPPServer.startModules(XMPPServer.java:600)

at org.jivesoftware.openfire.XMPPServer.start(XMPPServer.java:466)

at org.jivesoftware.openfire.XMPPServer.<init>(XMPPServer.java:161)

at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)

at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)

at java.lang.reflect.Constructor.newInstance(Unknown Source)

at java.lang.Class.newInstance0(Unknown Source)

at java.lang.Class.newInstance(Unknown Source)

at org.jivesoftware.openfire.starter.ServerStarter.start(ServerStarter.java:106)

at org.jivesoftware.openfire.starter.ServerStarter.main(ServerStarter.java:51)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)

at java.lang.reflect.Method.invoke(Unknown Source)

at com.exe4j.runtime.LauncherEngine.launch(Unknown Source)

at com.exe4j.runtime.WinLauncher.main(Unknown Source)

Joe Perez Bronze 50 posts since
Jan 3, 2008
Currently Being Moderated
Dec 18, 2008 3:26 PM in response to: Joe Perez
Re: Red5, SIP Phone, Sparkweb

well an update since my last post on this issue

 

Well it appears that Gizmo SIP settings for Registering SIP in Spark is now successful which all of you may know already.

 

Here is the settings I used:

 

Gizmo Settings:

server:  proxy01.sipphone.com

port: 5060

**described setting on gizmo site: proxy01.sipphone.com:5060

http://powerplus.hopto.org/images/SIP_Settings01.PNG

stun: stun01.sipphone.com

stun port: 3478

**described setting on gizmo site: stun01.sipphone.com:3478

http://powerplus.hopto.org/images/SIP_Settings03.png

 

SIP Phone Mapping:

SIP Username: {YOUR GIZMO USER NAME}

Authorization Name: {YOUR GIZMO USER NAME}

Display Phone Number: {YOUR GIZMO SIP PHONE NUMBER}

Outbound Proxy: {LEAVE THIS BLANK}

http://powerplus.hopto.org/images/SIP_Settings02.png

 

When you add these Settings TEST DOES NOT WORK, however this will register when you start spark with SIP plugin enabled.  Don't be discouraged by the failed TEST.  Launch Spark and this should work, as always make sure you have the appropriate ports open on your firewall.

 

 

Problems are:

What does prompt for user credentials do?

Is this only for Asterisk SIP?

DELE:***ACCOUNT DOES NOT REGISTER IN SPARK WEB ~~~ DELE IF YOUR READING THIS WHAT DO YOU SUGGEST ON THIS PROBLEM?

 

Hope this helps anyone, since this has been a thorn in my side for a while.

Dele Olajide KeyContributor 452 posts since
Apr 10, 2006
Currently Being Moderated
Dec 18, 2008 5:57 PM in response to: Joe Perez
Re: Red5, SIP Phone, Sparkweb

Display Phone number is used in SIP addresss  (sip:phone@server)
Server is used as SIP Realm/domain  (sip:phone@server)

Outbound Proxy is the SIP server host name or IP Address

Username and Password are used for SIP registration

 

Authorization Username is unused

 

In your settings, the Outbound proxy and Display Phone number will not work with SparkWeb

Bruce Silver 139 posts since
Jul 26, 2007
Currently Being Moderated
May 26, 2008 5:22 PM in response to: Dele Olajide
Re: Red5, SIP Phone, Sparkweb

 

here is a snapshot of my openfire startup

 

 

 

 

 

Attachments:
john li Bronze 22 posts since
Feb 12, 2007
Currently Being Moderated
Jul 10, 2008 11:38 PM in response to: Bruce
Re: Red5, SIP Phone, Sparkweb

 

Hi dele, 

 

 

I get 401 message from my asterisk pbx with my red5phone(red5 plugin 0.024), but can not send authentication info back to asterisk, How to get around 401?

 

 

 

 

 

Thanks 

 

 

 

 

 

korgme Bronze 2 posts since
Jan 3, 2009
Currently Being Moderated
Jan 3, 2009 11:08 PM in response to: john li
Re: Red5, SIP Phone, Sparkweb

Hi;

 

   I was meet same problem with red5,

   my setting detail:

   Red5 Properties-->url:rtmpt://ip_address:8000/sip

   and sip phone mapping display user registered.

   and have change the red5/sparkweb/index.html setting same to rtmpt://ip_address:8000/sip.

 

  but when two sparkweb user call is ok, but when press make telphone call icon will get

  "SIP Phone Error:phone not registered"

 

  so, any one can help me resolve it?

 

  thanks
  k.lin

gouriprasad Bronze 23 posts since
Dec 1, 2008
Currently Being Moderated
Jan 6, 2009 2:40 AM in response to: korgme
Re: Red5, SIP Phone, Sparkweb

Hi,

 

I too faced the same 401 Unauthorized problem. When I changed my red5url & in index.html to "rtmpt://mySIPserverIPAddress:8000/sip" now the problem is solved. But in Phone Mappings it showing as Registering and I can't see registered users list in my openser server. I guess it's not hitting SIP Server. I don't know what mistake did I made in the settings.

My Settings are:

1. I have created two users in my SIP(OpenSER) Server say as Gouri & Prasad.

2. In Openfire admin console I have added the same two users in USers/Groups Tab.

          Username: Gouri

          Name: Gouri

          Password: gouri123

          Confirm Password: gouri123

3. I have se the in Red5 as

          Name: red5

          URL: rtmpt://210.24.31.133:8000/sip where 210.24.31.133 is my SIP(OpenSER)  Server IP Address

3. I have Mapped the two users as

          XMPP: Gouri

          SIP Username: Gouri

          Authorized Username: Gouri

          Display Phone No: sip:Gouri@210.24.31.133 where 210.24.31.133 is SIP(OpenSER)  Server IP Address.

          Password: gouri123

          Server: 210.24.31.133:5080 where where 210.24.31.133 is SIP(OpenSER)  Server IP Address and 5080 is my SIP Port.

4. My SIP Settings:

          SIP Server: 210.24.31.133:5080

          StunServer: stun01.sipphone.com

          Port: 3478

 

Can anyone please tell me what mistake I have made in my settings or Can anyone give me the solution for call working(any document) in sparkweb.

 

Thanks,

Gouri Prasad.

More Like This

  • Retrieving data ...

Bookmarked By (0)