Hello all !
I have problem with this feature As was described, I: - created separate subscriber and location database table for my second domain called subscriber.gdynia and location.gdynia - configure my script properly (I hope) ;)
if (method=="REGISTER") { # Uncomment this if you want to use digest authentication if (!www_authorize("gdynia.pl", "subscriber.gdynia")) { www_challenge("gdynia.pl", "0"); break; };
save("location.gdynia"); log(3,"REGISTER from gdynia.pl"); sl_send_reply("200", "ok"); break;
if (!www_authorize("gda.pl", "subscriber")) { www_challenge("gda.pl", "0"); break; };
save("location"); log(3,"REGISTER from gda.pl"); sl_send_reply("200", "ok"); break;
};
Nobody is regigisted from this domain :( Is this same solution ( create separate table) in the newest version of SER ?
Greetings Andrzej Radke
Hello, comments inline.
On 13-05 12:30, Andrzej Radke wrote:
Hello all !
I have problem with this feature As was described, I:
- created separate subscriber and location database table for my second
domain called subscriber.gdynia and location.gdynia
configure my script properly (I hope) ;)
if (method=="REGISTER") {
# Uncomment this if you want to use digest authentication if (!www_authorize("gdynia.pl", "subscriber.gdynia")) { www_challenge("gdynia.pl", "0"); break; };
save("location.gdynia"); log(3,"REGISTER from gdynia.pl"); sl_send_reply("200", "ok"); break; if (!www_authorize("gda.pl", "subscriber")) { www_challenge("gda.pl", "0"); break; }; save("location"); log(3,"REGISTER from gda.pl"); sl_send_reply("200", "ok"); break; };
What is this supposed to do ? The second part of the script starting with www_authorize("gda.pl", "subscriber") will never be executed because there is break before it. What are you trying to achieve ?
Jan.
On Tue, 13 May 2003, Jan Janak wrote:
Hello, comments inline.
On 13-05 12:30, Andrzej Radke wrote:
Hello all !
I have problem with this feature As was described, I:
- created separate subscriber and location database table for my second
domain called subscriber.gdynia and location.gdynia
configure my script properly (I hope) ;)
if (method=="REGISTER") {
# Uncomment this if you want to use digest authentication if (!www_authorize("gdynia.pl", "subscriber.gdynia")) { www_challenge("gdynia.pl", "0"); break; };
save("location.gdynia"); log(3,"REGISTER from gdynia.pl"); sl_send_reply("200", "ok"); break; if (!www_authorize("gda.pl", "subscriber")) { www_challenge("gda.pl", "0"); break; }; save("location"); log(3,"REGISTER from gda.pl"); sl_send_reply("200", "ok"); break; };
What is this supposed to do ? The second part of the script starting with www_authorize("gda.pl", "subscriber") will never be executed because there is break before it. What are you trying to achieve ?
Jan.
You right ! But if I remove this "break" command nothing is happend Nobody from gda.pl and gdynia.pl is registered. :( I'd like a support for 2 different domains. What can I do ? I think the problem is in my config script, not in database tables, which I created
Andrzej
On 13-05 12:48, Andrzej Radke wrote:
You right ! But if I remove this "break" command nothing is happend Nobody from gda.pl and gdynia.pl is registered. :( I'd like a support for 2 different domains. What can I do ? I think the problem is in my config script, not in database tables, which I created
OK, to achieve this you will need a condition to differentiate the domains. For example something like this:
if (uri=~".*gda.pl") { if (method=="REGISTER") { if (!www_authorize("gda.pl", "subscriber")) { www_challenge("gda.pl", "0"); break; };
save("location"); break; };
if (!lookup("location")) { sl_send_reply("404", "Not Found"); break; }; } else if (uri=~".*gdynia.pl") { if (method=="REGISTER") { if (!www_authorize("gdynia.pl", "subscriber2")) { www_challenge("gdynia.pl", "0"); break; };
save("location2"); break; };
if (!lookup("location2")) { sl_send_reply("404", "Not Found"); break; }; };
if (!t_relay()) { sl_reply_error(); };
This is easy if you have a small number of domains that you want to handle and you don't change it very often.
If you need multidomain support and the domains are created often or automatically then it is also possible to do this without modifications of the script and restarting the server. But only CVS version of ser supports that.
Jan.
OK, to achieve this you will need a condition to differentiate the domains. For example something like this:
------------cut-------------------- ------------cut--------------------
This is easy if you have a small number of domains that you want to handle and you don't change it very often.
If you need multidomain support and the domains are created often or automatically then it is also possible to do this without modifications of the script and restarting the server. But only CVS version of ser supports that.
Jan.
Thanks Jan once more for you help :)
Andrzej
On Tue, 13 May 2003, Andrzej Radke wrote:
OK, to achieve this you will need a condition to differentiate the domains. For example something like this:
------------cut-------------------- ------------cut--------------------
This is easy if you have a small number of domains that you want to handle and you don't change it very often.
If you need multidomain support and the domains are created often or automatically then it is also possible to do this without modifications of the script and restarting the server. But only CVS version of ser supports that.
Jan.
Thanks Jan once more for you help :)
One question yet. What with aliases for separate domains ? Have to I add something to my configuration ? something like this: save("aliases") save("aliases1") for separate domian registration ?
Andrzej