Hi Nils!
Le mar 18/02/2003 à 16:56, Nils Ohlmeier a écrit :
> Hard to say without seeing the config file. But '-E' as command line
> parameter should work and will overwrite any value in your config
> file.
Here it is (the HelloWorld.cfg):
<snip>
log_stderror=yes
route[0]
{
log("Hello World!");
}
</snip>
Here is the SIP message I send to SER:
<snip>
INVITE sip:alice@127.0.0.1 SIP/2.0
Via: SIP/2.0/UDP 127.0.0.1:5070
To: Alice <sip:alice@localhost>
From: Me <sip:me@localhost>
Call-ID:123456789@127.0.0.1
CSeq: 1 INVITE
Content-Length: 0
</snip>
Here is the answer I get from SER:
<snip>
SIP/2.0 404 Not Found
Via: SIP/2.0/UDP 127.0.0.1:5070
To: Alice
<sip:alice@localhost>;tag=d907c037823644515dfe0ede38ca9976.de25
From: Me <sip:me@localhost>
Call-ID:123456789@127.0.0.1
CSeq: 1 INVITE
Server: Sip EXpress router (0.8.10 (i386/linux))
Content-Length: 0
Warning: 392 127.0.0.1:5060 "Noisy feedback tells: pid=9995
req_src_ip=127.0.0.1 in_uri=sip:alice@127.0.0.1
out_uri=sip:alice@127.0.0.1 via_cnt==1"
</snip>
And here is what I get from SER in stdout/stderr:
<snip>
$ ser -E HelloWorld.cfg
Listening on
127.0.0.1 [127.0.0.1]::5060
172.25.49.134 [172.25.49.134]::5060
Aliases: XXX.alcatel.fr:5060 localhost:5060 localhost.localdomain:5060
XXX:5060
</snip>
And from /var/log/messages
<snip>
Feb 18 17:33:21 frilld0030711 ser[9994]: INFO: udp_init: SO_RCVBUF is
initially 65535
Feb 18 17:33:21 frilld0030711 ser[9994]: INFO: udp_init: SO_RCVBUF is
finally 131070
Feb 18 17:33:21 frilld0030711 ser[9994]: INFO: udp_init: SO_RCVBUF is
initially 65535
Feb 18 17:33:21 frilld0030711 ser[9994]: INFO: udp_init: SO_RCVBUF is
finally 131070
Feb 18 17:33:21 frilld0030711 ser[10003]: INFO: fifo process starting:
10003
Feb 18 17:33:21 frilld0030711 ser[10003]: SER: open_uac_fifo: fifo
server up at /tmp/ser_fifo...
</snip>
So there is sadly no "HelloWorld!" somewhere... would it be because of
the "404 not found" error I get ?
TIA,
-- Sebastien
Hi all,
I am trying to implement a very simple call forwarding use case with
SER. This use case is directly taken from a book entitled "Internet
Applications with SIP".
Here are the actors:
- SIP caller, wants to call <alice@domain>
- Proxy server of <domain>
- SIP phone which is default terminal for <alice(a)domain.com>
- Voicemail server
Here is the scenario:
0) SIP caller INVITEs <alice@domain>
1) Proxy receives INVITE
2) Proxy forwards INVITE to alice default SIP phone
3) Proxy responses 100 TRYING to SIP caller
4) SIP phone responses 100 TRYING to proxy
5) SIP phone responses 180 RINGING to proxy
6) Proxy reponses 180 RINGING to caller
7) After timeout, proxy send CANCEL to default SIP phone
8) SIP phone responses OK to proxy...
...
X) Proxy forward original INVITE to voice mail server...
The fact is that the proxy first notifies the caller that it is trying
to locate alice, listens for "180 RINGING" and forward it to the caller,
then cancels on the SIP phone side because of a timeout -- then the
proxy forwards the INVITE to the voice mail.
I have tried some configurations, but I did not see how to listen for
the 180 RINGING and forward them to the caller... is there a way to bind
a "route" to a provisional response like:
route[0]
{
...
#In case a 180 occur, we execute route[1]
t_on_provisional("180", "1");
#But we're also waiting for an OK or a timer
#event to arrive
t_on_negative("2");
t_relay();
...
}
route[1]
{
#Forwards the 180 Ringing from the SIP phone to
#the caller
t_relay();
}
BTW, I was wondering if t_on_negative is a *blocking* action ?
TIA,
-- Sebastien
Hi Nils!
Le mar 18/02/2003 à 16:03, Nils Ohlmeier a écrit :
> On Tuesday 18 February 2003 15:57, Sebastien Pierre wrote:
> > I was just wondering (did not find in User or Dev guide) where to get
> > the result of SER "log" action... I have written a fake SIP UA that
> syslog (probably /var/log/messages) if log_stderror=no, otherwise stderr (your
> console).
I thought I did not install syslog with root privileges, so I did not
look in the *obvious* file!
Anyway, I put a "log_sterror=yes" line at the beginning of my SER
configuration script, but SER keeps outputting on /var/log/messages and
not on STDERR... what did I do wrong ?
> > sends SIP messages written in a file to test custom SER configurations,
> > but I don't know if SER properly receives my messages or executes my
> > routing program. Any advices ?
> Congratulation for reinventing the wheel -> http://sipsak.berlios.de :-)
I know about it but...
>> sipsak -s sip:alice@localhost
error: this FQDN or IP is not valid: frwed00304
I'm still puzzled about this FQDN and my hostname... and I could not
resist making a 20 lines Python script to get SER tested ;)
-- Seb
Hello,
check your php.ini file if you have:
register_globals = On
Karel
>
> >Hi,
> >
> >I' ve installed SERWEB.....But when I try to register or login...nothing happens... the page is reload. The Apache server is working. Anyone had this same problem?
> >
> >Thanks,
> >
> >Adriana Simizo
> >Telefonica Brasil - Telecomunicaçőes de Săo Paulo S. A.
> >
>
> --
> Jiri Kuthan http://iptel.org/~jiri/
I have resolved this problem. The radiusclient library was not
included in the both radius modules, somehow. After I statically
linked the radiusclient library with the option -lradiusclient when
compiling, it works.
regards
yang
-------------------
> The modules need radiusclient library but linker is unable to find
> symbols from the library. Do you have the radiusclient library
installed
> correctly ?
>
> regards, Jan.
>
> On 14-02 14:35, Yang Xiang wrote:
> > Hi,
> >
> > I get the same error.
> >
> > I have compiled the whole server and try to load modules on the
host where
> > the server was compiled. Unfortunatelly it doesn't work. I get the
same
> > error message as before.
> >
> > What should I do????
> >
> > Regards
> >
> > Yang
> >
> >
> > ----- Original Message -----
> > From: "Jan Janak" <J.Janak(a)sh.cvut.cz>
> > To: "Yang Xiang" <yang.xiang(a)iitb.fraunhofer.de>
> > Sent: Friday, February 14, 2003 2:03 PM
> > Subject: Re: [Serusers] problem with loading compiled radius
modules
> >
> >
> > > Recompile the whole server if you can. As you said you use
precomplied
> > > binaries and it is possible that it was compiled using a
different
> > > compiler.
> > >
> > > regards, Jan.
> > >
> > > On 14-02 13:56, Yang Xiang wrote:
> > > > Hi,
> > > >
> > > > Now I get more error messages:
> > > >
> > > > 0(22528) ERROR: load_module: could not open module
> > > > </usr/local/lib/ser/modules/radius_acc.so>: ld.so.1: ser:
fatal:
> > relocation
> > > > error: file /usr/local/lib/ser/modules/radius_acc.so: symbol
> > rc_avpair_add:
> > > > referenced symbol not found
> > > > 0(22528) parse error (30,13-54): failed to load module
> > > > 0(22528) ERROR: load_module: could not open module
> > > > </usr/local/lib/ser/modules/radius_auth.so>: ld.so.1: ser:
fatal:
> > relocation
> > > > error: file /usr/local/lib/ser/modules/radius_auth.so: symbol
> > > > rc_read_config: referenced symbol not found
> > > > 0(22528) parse error (31,13-55): failed to load module
> > > > ERROR: bad config file (2 errors)
> > > >
> > > > What is wrong? In acc_mod.c and auth_mod.c I changed the
definition of
> > > > CONFIG_FILE and let it point to an absolute path
> > > > "/usr/local/etc/radiusclient/radiusclient.conf". By the way, I
compiled
> > the
> > > > modiles on another mashine and copied them to the mashine
where ser
> > runs. Is
> > > > that right?
> > > >
> > > > regards,
> > > >
> > > > yang
> > > >
> > >
> > >
> >
>
>
Folks,
Our company mostly finished development of the SIP VoIP system that
consists of the SER for registration, de-NATifying, and routing and
B2BUA for debit applications. Now we would like to test performance of
the whole system under the load. In the SER's documentation I saw very
impressive performance numbers and wonder how they were obtained. Are
there any freely-available tools for creating huge number of SIP
sessions simulateneously and if yes, how they can be obtained?
Any pointers are greatly appreciated.
Thanks!
-Maxim
Hi,
> simply use fi_check() in the configuration script. That will call your
> function.
Thats what I thought also, but unfortunately, SER does not run when. If
I run it with a call fi_check() in the ser.cfg file it logs a parse error:
Feb 14 14:15:00 DISCUS ser: parse error (39,1-9): parse error
Feb 14 14:15:00 DISCUS ser: parse error (39,1-9):
I have attached the complete cfg file. But if I remove that fi_check()
call, ser runs fine. Have I messed something up with parameters????
Thanks for your help!
Mario
--
Mario Kolberg phone: +44 (0)1786 46 7440
Lecturer in Computing Science fax : +44 (0)1786 46 4551
email: mko(a)cs.stir.ac.uk
Department of Computing Science and Mathematics
University of Stirling
Stirling FK9 4LA
Scotland, UK
--
The University of Stirling is a university established in Scotland by
charter at Stirling, FK9 4LA. Privileged/Confidential Information may
be contained in this message. If you are not the addressee indicated
in this message (or responsible for delivery of the message to such
person), you may not disclose, copy or deliver this message to anyone
and any action taken or omitted to be taken in reliance on it, is
prohibited and may be unlawful. In such case, you should destroy this
message and kindly notify the sender by reply email. Please advise
immediately if you or your employer do not consent to Internet email
for messages of this kind. Opinions, conclusions and other
information in this message that do not relate to the official
business of the University of Stirling shall be understood as neither
given nor endorsed by it.
#
# $Id: ser.cfg,v 1.12 2002/10/21 02:40:06 jiri Exp $
#
# simple quick-start config script
#
# ----------- global configuration parameters ------------------------
debug=3 # debug level (cmd line: -dddddddddd)
fork=yes
log_stderror=no # (cmd line: -E)
check_via=no # (cmd. line: -v)
dns=no # (cmd. line: -r)
rev_dns=no # (cmd. line: -R)
port=5060
children=4
fifo="/tmp/ser_fifo"
alias="cs.stir.ac.uk"
# ------------------ module loading ----------------------------------
# Uncomment this if you want to use SQL database
#mario
loadmodule "//usr/lib/ser/modules/mysql.so"
loadmodule "//usr/lib/ser/modules/sl.so"
loadmodule "//usr/lib/ser/modules/tm.so"
loadmodule "//usr/lib/ser/modules/rr.so"
loadmodule "//usr/lib/ser/modules/maxfwd.so"
loadmodule "//usr/lib/ser/modules/usrloc.so"
loadmodule "//usr/lib/ser/modules/registrar.so"
loadmodule "//usr/lib/ser/modules/fi.so"
# Uncomment this if you want digest authentication
# mysql.so must be loaded !
#mario
loadmodule "//usr/lib/ser/modules/auth.so"
fi_check();
# ----------------- setting module-specific parameters ---------------
# -- usrloc params --
modparam("usrloc", "db_mode", 0)
# Uncomment this if you want to use SQL database
# for persistent storage and comment the previous line
#mario
modparam("usrloc", "db_mode", 2)
# -- auth params --
# Uncomment if you are using auth module
#
#modparam("auth", "secret", "alsdkhglaksdhfkloiwr")
#mario
modparam("auth", "calculate_ha1", yes)
#
# If you set "calculate_ha1" parameter to yes (which true in this config),
# uncomment also the following parameter)
#
#mario
modparam("auth", "password_column", "password")
# ------------------------- request routing logic -------------------
# main routing logic
route{
# initial sanity checks -- messages with
# max_forwars==0, or excessively long requests
if (!mf_process_maxfwd_header("10")) {
sl_send_reply("483","Too Many Hops");
break;
};
if (len_gt( max_len )) {
sl_send_reply("513", "Message too big");
break;
};
# Do strict routing if pre-loaded route headers present
rewriteFromRoute();
# if the request is for other domain use UsrLoc
# (in case, it does not work, use the following command
# with proper names and addresses in it)
if (uri==myself) {
if (method=="REGISTER") {
# Uncomment this if you want to use digest authentication
#mario
if (!www_authorize("cs.stir.ac.uk", "subscriber")) {
www_challenge("cs.stir.ac.uk", "0");
break;
};
save("location");
break;
};
# native SIP destinations are handled using our USRLOC DB
if (!lookup("location")) {
sl_send_reply("404", "Not Found");
break;
};
};
# forward to current uri now
if (!t_relay()) {
sl_reply_error();
};
}
Hi,
I am trying to write a module for SER. I managed to write a tiny test
module ("hello world") and it compiles fine (the source is attached).
However, I'm not quite sure I fully understood how to execute the
functions defined in the module.
I included the module to sr_modules.c and also a line 'loadmodule' in
the ser.cfg. But how do I actually execute the function in the module
every time a (INVITE) message is received by the server?
The docs couldn't really help ...
Thanks very much!
Regards,
Mario
--
Mario Kolberg phone: +44 (0)1786 46 7440
Lecturer in Computing Science fax : +44 (0)1786 46 4551
email: mko(a)cs.stir.ac.uk
Department of Computing Science and Mathematics
University of Stirling
Stirling FK9 4LA
Scotland, UK
--
The University of Stirling is a university established in Scotland by
charter at Stirling, FK9 4LA. Privileged/Confidential Information may
be contained in this message. If you are not the addressee indicated
in this message (or responsible for delivery of the message to such
person), you may not disclose, copy or deliver this message to anyone
and any action taken or omitted to be taken in reliance on it, is
prohibited and may be unlawful. In such case, you should destroy this
message and kindly notify the sender by reply email. Please advise
immediately if you or your employer do not consent to Internet email
for messages of this kind. Opinions, conclusions and other
information in this message that do not relate to the official
business of the University of Stirling shall be understood as neither
given nor endorsed by it.
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include "../../sr_module.h"
#include "../../dprint.h"
#include "../../error.h"
#include "../../ut.h"
static int fi_check(struct sip_msg* msg,char* str,char* str2);
static int mod_init(void);
#ifdef STATIC_FI
struct module_exports fi_exports = {
#else
struct module_exports exports= {
#endif
"fi_module",
(char*[]){
"fi_check"
},
(cmd_function[]){
fi_check
},
(int[]){
0
},
(fixup_function[]){
0
},
1, NULL, NULL, NULL, 0,
mod_init,
(response_function) 0,
(destroy_function) 0,
0,
0
};
static int mod_init(void)
{
printf("FI module initializing\n");
return 0;
}
static int fi_check(struct sip_msg* msg, char* str1,char* str2)
{
printf("FI module executing\n");
return 1;
}
/* digging through the archives to make sure I haven't missed anything
while I was off-line last weeks ...
*/
I actually think that is a backwards compatibility issue in SIP.
Loose-routing works correctly if sender knows whether the next-hop
is loose or strict router. That is a correct assumption as long as
the routing information collected automatically in record-route
tells you that. If you use pre-configured Route along with an
outbound proxy, you configure this strict/loose on your own and
you need to get it right. Hence, when you configure loose routing
for use with a strict outbound router, things will fail.
Anyway, with lr support in next ser release, it should not matter
any more. We've had the same issue with kphone previouly, it works
since an option has been introduce to enforce use of strict routing.
see http://www.ietf.org/mail-archive/working-groups/sipping/current/msg03451.ht…
-Jiri
At 11:18 AM 2/5/2003, Klaus Darilion wrote:
>Hello!
>
>I've installed ser (sip:obelix.ict.tuwien.ac.at) und want'ed to use it
>with linphone, so I configured linphone to use ser as outbound proxy and
>registrar. The registration works fine but not the INVITEs. ser answers
>to an INVITE from linphone with a 404 Not Found and I found out that the
>problem is the "Route" header in the INVITE from linphone.
>
>Route: <sip:obelix.ict.tuwien.ac.at;lr>
>
>When I remove the header from the invite and send it manually (sipsak)
>the ser proxy accepts the invite and forwards it. I think ser reacts
>wrong because if an RFC3261 proxy gets an request with a route header
>which points to itself it should remove the header and forward the
>request.
>
>Than I tried the same with an different proxy in the route header:
>
>Route: <sip:iptel.org;lr>
>
>Now, my ser proxy (sip:obelix.ict.tuwien.ac.at) accepts the request and
>forwards it to iptel.org, but it rewrites the invite to:
>INVITE sip:iptel.org;lr SIP/2.0
>
>Thats what an RFC2543 proxy would do, but not an RFC3261 proxy, which
>only is allowed to do that if the route header has no "lr" parameter or
>if he is responsible for the domain in the request URI. If there is an
>"lr" parameter the proxy must not change the request URI.
>
>If I'm wrong please let me know.
>
>I use ser 0.8.10 with the standard config file and linphone 0.9.1 &
>0.10.0
>
>Regards,
>Klaus
>_______________________________________________
>Serusers mailing list
>serusers(a)lists.iptel.org
>http://lists.iptel.org/mailman/listinfo/serusers
--
Jiri Kuthan http://iptel.org/~jiri/