[Serusers] does_uri_exist does not find user in subscriber db?

Jan Janak jan at iptel.org
Sat Jul 24 15:15:27 CEST 2004


Please update the the latest stable version from CVS, the use_domain
parameter was added later.

 Jan.

On 21-07 11:17, Francisco Cuellar wrote:
> Hello Jan,
> here is the information you requested
> 
>  * $Id: uri_mod.c,v 1.12 2003/04/27 18:17:25 jiri Exp $
> 
> Thanks for the help.
> Francisco
> 
> -----Original Message-----
> From: Jan Janak [mailto:jan at iptel.org]
> Sent: Wednesday, July 21, 2004 4:15 AM
> To: Francisco Cuellar
> Cc: cisco at ifreedomcom.com; serusers at lists.iptel.org
> Subject: Re: [Serusers] does_uri_exist does not find user in subscriber db?
> 
> 
> Sorry for late reply. It looks to me like you are using unstable version
> of ser, because stable version contains this parameter in uri module.
> Could you look at the beginning of sip_router/modules/uri/uri_mod.c and
> report the revision to me ?
> 
>  Jan.
> 
> On 20-07 02:20, Francisco Cuellar wrote:
> > any ideas? anyone? am I using the wrong version of uri module somehow?
> >
> > thanks for the help.
> >
> > -----Original Message-----
> > From: serusers-bounces at iptel.org [mailto:serusers-bounces at lists.iptel.org]On
> > Behalf Of Francisco Cuellar
> > Sent: Thursday, July 15, 2004 2:09 AM
> > To: Jan Janak; cisco at ifreedomcom.com
> > Cc: serusers at lists.iptel.org
> > Subject: RE: [Serusers] does_uri_exist does not find user in subscriber
> db?
> >
> >
> > Hello Jan,
> > and thanks for the quick reply, I tried what you suggested and here is
> what
> > I got
> >
> > Jul 15 00:43:36 sip ser: ser shutdown succeeded
> > Jul 15 00:43:37 sip ser: set_mod_param_regex: parameter <use_domain> not
> > found in module <uri>
> > Jul 15 00:43:37 sip ser: parse error (101,32-33): Can't set module
> parameter
> > Jul 15 00:43:37 sip ser: ERROR: bad config file (1 errors)
> > Jul 15 00:43:37 sip ser: ser startup failed
> >
> > any ideas? I don't see use_domain in uri README
> >
> > Francisco
> >
> > -----Original Message-----
> > From: serusers-bounces at iptel.org [mailto:serusers-bounces at lists.iptel.org]On
> > Behalf Of Jan Janak
> > Sent: Wednesday, July 14, 2004 11:53 PM
> > To: cisco at ifreedomcom.com
> > Cc: serusers at lists.iptel.org
> > Subject: Re: [Serusers] does_uri_exist does not find user in subscriber
> db?
> >
> >
> > My quick guess is that the domain part of the Request-URI does not match
> > the domain in subscriber table. Try to set the following:
> >
> > modparam("uri", "use_domain", 0)
> >
> > that would disable domain matching, or compare the domain part of the
> > Request-URI of the SIP message to the domain in subscriber table to see if
> > they are the same.
> >
> >   Jan.
> >
> > On 14-07 16:46, Francisco Cuellar wrote:
> > > Hello all,
> > >
> > > I've been having trouble with does_uri_exist function in uri module..for
> > > some reason it does not see the username in the subscriber table..
> > > am running ser-0.8.12 stable,
> > > checks.c file where function does_uri_exist resides in uri directory of
> > Ser
> > > source is $Id: checks.c,v 1.10 2003/04/28 22:08:03 janakj Exp $
> > >
> > > here are the options I'm loading for uri module
> > >
> > > modparam("uri", "db_url", "mysql://seruser:serpasswd@localhost/ser")
> > > modparam("uri", "subscriber_table", "subscriber")
> > > modparam("uri", "uri_table", "uri")
> > > modparam("uri", "uri_user_column", "username")
> > > modparam("uri", "uri_domain_column", "domain")
> > > modparam("uri", "uri_uriuser_column", "uri_user")
> > > modparam("uri", "subscriber_user_column", "username")
> > > modparam("uri", "subscriber_domain_column", "domain")
> > >
> > > this is the part on ser.cfg where I am trying to apply does_uri_exist
> > >
> > >   if (!lookup("location")) {
> > >                 log(1, "LOG:USRLOC request not found\n");
> > >                 if (does_uri_exist()) {
> > >                         log(1, "LOG:URI Exists\n");
> > >                         if (is_user_in("Request-URI", "voicemail")) {
> > >                                 rewritehostport("192.168.10.10:5090");
> > >                                 log(1, "LOG:USRLOC request not found,VM
> > > set,relay to VM\n");
> > >                                 if (!t_relay()) {
> > >                                         sl_reply_error();
> > >                                         break;
> > >                                 };
> > >                         break;
> > >                         };
> > >                 };
> > >         };
> > >
> > > I know that the username is in the subscriber table username 4500
> > >
> > > when I check the mysql db I get
> > > mysql> select * from subscriber where username=4500;
> > >
> > > | phplib_id                        | username | domain              |
> > > password |
> > >  first_name | last_name | phone | email_address            |
> > > datetime_created
> > >  | datetime_modified   | confirmation | flag | sendnotification |
> greeting
> > |
> > > ha1
> > >                               | ha1b                             | perms
> |
> > > allow
> > > _find | timezone |
> > > ------+----------+
> > > | c493919a77f0c3e2671dce9048a78cce | 4500     | sip.mydomain.com| 4500
> > |
> > >             |           |       | 4500 at sip.mydomain.com| 2004-06-25
> > 00:32:27
> > >  | 0000-00-00 00:00:00 |              | o    |                  |
> > |
> > > c49
> > > 3919a77f0c3e2671dce9048a78cce | 643bfb0b11229b401fc32c4af1b538d4 | NULL
> |
> > 0
> > >       | NULL     |
> > >
> >
> +----------------------------------+----------+---------------------+-------
> > > ---+
> > >
> > > but while running debug during a call to 4500 which is not in location
> db
> > > but is in subscriber table i get
> > >
> > >  0(20262) lookup(): '4500' Not found in usrloc
> > >  0(20262) LOG:USRLOC request not found
> > >  0(20262) does_uri_exit(): User in request uri does not exist
> > >  0(20262) LOG: Called not in location DB/n 0(20262) parse_headers:
> > > flags=16384
> > >
> > > Is there something missing in my script that is needed by
> does_uri_exist?
> > >
> > > I really appreciate any help pointing me in the right direction
> > >
> > > Thanks
> > > Francisco
> >
> > > _______________________________________________
> > > Serusers mailing list
> > > serusers at lists.iptel.org
> > > http://lists.iptel.org/mailman/listinfo/serusers
> >
> > _______________________________________________
> > Serusers mailing list
> > serusers at lists.iptel.org
> > http://lists.iptel.org/mailman/listinfo/serusers
> >
> > _______________________________________________
> > Serusers mailing list
> > serusers at lists.iptel.org
> > http://lists.iptel.org/mailman/listinfo/serusers
> >
> 




More information about the sr-users mailing list