Hi, Marian
I use xten's x-lite as client. I configure is with authen user:test and
passwod:test. But it register failed. I have dump the
packet ser sent and recived.
interface: eth0 (210.22.131.224/255.255.255.248)
filter: ip and ( port 5060 )
#
U 210.22.131.226:6000 -> 210.22.131.227:5060
REGISTER sip:210.22.131.227 SIP/2.0..Via: SIP/2.0/UDP
192.168.0.155:6000;rport;branch=z9hG4bK51FEF4A2B3
FD41F9A189553FAC96CC88..From: Jiang zhou
<sip:10644@210.22.131.227>;tag=211297029..To: Jiang zhou <sip:
10644@210.22.131.227>..Contact: "Jiang zhou"
<sip:10644@192.168.0.155:6000>..Call-ID: 8C00955F27B948689
50083564E946D6A@210.22.131.227..CSeq: 31339 REGISTER..Expires:
1800..Max-Forwards: 70..User-Agent: X-Li
te release 1103m..Content-Length: 0....
#
U 210.22.131.227:5060 -> 210.22.131.226:6000
SIP/2.0 401 Unauthorized..Via: SIP/2.0/UDP
192.168.0.155:6000;rport=6000;branch=z9hG4bK51FEF4A2B3FD41F9
A189553FAC96CC88;received=210.22.131.226..From: Jiang zhou <sip:10644@210.
22.131.227>;tag=211297029..To
: Jiang zhou
<sip:10644@210.22.131.227>;tag=b27e1a1d33761e85846fc98f5f3a7e58.f65e..Call-I
D: 8C00955F27B
94868950083564E946D6A@210.22.131.227..CSeq: 31339
REGISTER..WWW-Authenticate: Digest realm="sipod.com",
nonce="4191bcb2194d3467d01427c31b2af82175efdd72"..Server: Sip EXpress
router (0.8.14 (i386/linux))..Co
ntent-Length: 0..Warning: 392 210.22.131.227:5060 "Noisy feedback tells:
pid=32612 req_src_ip=210.22.1
31.226 req_src_port=6000 in_uri=sip:210.22.131.227 out_uri=sip:210.22.131.
227 via_cnt==1"....
#
U 210.22.131.226:6000 -> 210.22.131.227:5060
REGISTER sip:210.22.131.227 SIP/2.0..Via: SIP/2.0/UDP
192.168.0.155:6000;rport;branch=z9hG4bK8ADF977EB4
7944DDB520CD41FD1538FE..From: Jiang zhou
<sip:10644@210.22.131.227>;tag=211297029..To: Jiang zhou <sip:
10644@210.22.131.227>..Contact: "Jiang zhou"
<sip:10644@192.168.0.155:6000>..Call-ID: 8C00955F27B948689
50083564E946D6A@210.22.131.227..CSeq: 31340 REGISTER..Expires:
1800..Authorization: Digest username="te
st",realm="sipod.com",nonce="4191bcb2194d3467d01427c31b2af82175efdd72",respo
nse="8479b6b844a227d2e1d68b
e8af158423",uri="sip:210.22.131.227"..Max-Forwards: 70..User-Agent:
X-Lite
release 1103m..Content-Lengt
h: 0....
#
U 210.22.131.227:5060 -> 210.22.131.226:6000
SIP/2.0 500 Server Internal Error..Via: SIP/2.0/UDP
192.168.0.155:6000;rport=6000;branch=z9hG4bK8ADF977
EB47944DDB520CD41FD1538FE;received=210.22.131.226..From: Jiang zhou
<sip:10644@210.22.131.227>;tag=2112
97029..To: Jiang zhou
<sip:10644@210.22.131.227>;tag=b27e1a1d33761e85846fc98f5f3a7e58.d68b..Call-I
D: 8C
00955F27B94868950083564E946D6A@210.22.131.227..CSeq: 31340
REGISTER..Server: Sip EXpress router (0.8.14
(i386/linux))..Content-Length: 0..Warning: 392 210.22.131.227:5060 "Noisy
feedback tells: pid=32611 r
eq_src_ip=210.22.131.226 req_src_port=6000 in_uri=sip:210.22.131.227
out_uri=sip:210.22.131.227 via_cnt
==1"....
#
U 210.22.131.226:6000 -> 210.22.131.227:5060
..
exit
7 received, 0 dropped
-----邮件原件-----
发件人: Marian Dumitru [mailto:marian.dumitru@voice-sistem.ro]
发送时间: 2004年11月10日 1:46
收件人: Jiang zhou
抄送: serusers(a)lists.iptel.org
主题: Re: [Serusers] Does someone use dbtext database?
Hi Jiang,
what exactly is the problem? Do you get some errors? AFAIK, the config
section look ok, but I'm not sure if the field you put in the file are
enough.
Best regards,
Marian
Jiang zhou wrote:
Hi, all:
I wang to use dbtext to authentication. But I can't config it
successful . Can some give me the ser.cfg and dbtext file?
My config file is below:
ser.cfg:
loadmodule "/usr/local/lib/ser/modules/dbtext.so"
loadmodule "/usr/local/lib/ser/modules/sl.so"
loadmodule "/usr/local/lib/ser/modules/tm.so"
loadmodule "/usr/local/lib/ser/modules/rr.so"
loadmodule "/usr/local/lib/ser/modules/maxfwd.so"
loadmodule "/usr/local/lib/ser/modules/usrloc.so"
loadmodule "/usr/local/lib/ser/modules/registrar.so"
loadmodule "/usr/local/lib/ser/modules/textops.so"
loadmodule "/usr/local/lib/ser/modules/auth.so"
loadmodule "/usr/local/lib/ser/modules/auth_db.so"
loadmodule "/usr/local/lib/ser/modules/nathelper.so"
# ----------------- setting module-specific parameters ---------------
#modparam("registrar", "append_branches", 0)
modparam("usrloc", "db_mode", 0)
#modparam("usrloc", "db_mode", 2)
# -- auth params --
modparam("auth_db", "db_url", "dbtext:/var/dbtext/ser/")
modparam("auth_db", "calculate_ha1", 1) modparam("auth_db",
"password_column", "password")
...
if (uri==myself) {
if (method=="REGISTER") {
if (!www_authorize("abc.com", "subscriber")) {
www_challenge("abc.com", "0");
break;
};
save("location");
break;
};
[dbtext config]:
[root@localhost ser]# pwd
/var/dbtext/ser
[root@localhost ser]# ls
subscriber
[root@localhost ser]# more subscriber
username(str) password(str) ha1(str) domain(str) ha1b(str)
test:test:xxx:abc.com:xxx [root@localhost ser]#
Jiang zhou
Best Regards
_______________________________________________
Serusers mailing list
serusers(a)lists.iptel.org
http://lists.iptel.org/mailman/listinfo/serusers
--
Voice Sistem
http://www.voice-sistem.ro