PJSIP Registration error

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

  I am new to PJSIP and I have modified the simplesua sample program to
include registration. But I always get :

                SIP Registration failed, status=503 (service unavailable)

 

I am using asterisk server as my SIP proxy. 

 

                //listening SIP address/port

                char contact_char[256];                                

                sprintf(contact_char,"sip:"SIP_USER"@192.168.xxx.xxx:5060");

                contact = pj_str(contact_char);

                

                acc=&acc_var;

                

                //Initialize acc.cfg

                acc->cfg.id = pj_str("sip:" SIP_USER "@" SIP_DOMAIN);

                acc->cfg.reg_uri = pj_str("sip:" SIP_DOMAIN);

                acc->cfg.cred_count = 1;

                acc->cfg.cred_info[0].realm = pj_str("*");

                acc->cfg.cred_info[0].scheme = pj_str("digest");

                acc->cfg.cred_info[0].username = pj_str(SIP_USER "@"
SIP_DOMAIN);

                acc->cfg.cred_info[0].data_type =
0;//PJSIP_CRED_DATA_PLAIN_PASSWD;

                acc->cfg.cred_info[0].data = pj_str(SIP_PASSWD);

                acc->cfg.reg_timeout = PJSIP_REGC_EXPIRATION_NOT_SPECIFIED;

 

 

Can anyone please help me, what is that I am missing. The user gets
registered when I try with pjsua sample. But I need to use the pjlib rather
than pjsua. 

 

Thanks and Regards,

Ram

********************************************************************

UnitedPro Software Solutions Pvt  Ltd |Off: 42187875 / 76 |
www.unitedprotech.com 

********************************************************************

The contents of this email and any attachments are confidential. They are
intended for the named recipient(s) only.
If you have received this email in error please notify the system manager or
the sender immediately and do not disclose the contents to anyone or make
copies. 

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20110818/20a648dc/attachment.html>


[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux