Hi All,

I'm trying to follow http://www.opensips.org/Resources/DocsTutFail2ban 
for fail2ban integration.

All seems to make sense apart from the /etc/opensips/opensips.cfg 
changes seem to cause trouble.

Here is the change causing trouble:

######################
#old version:
#if ( ! www_authorize( "", "phones" ) ) {
#       www_challenge( "", "0" );
#       exit;
#}

######################
#new version:
$var(auth_code) = www_authorize("", "phones");
if ( $var(auth_code) == -1 || $var(auth_code) == -2 ) {
#       xlog("L_NOTICE","Auth error for $...@$fd from $si cause 
$var(auth_code)");
#       xlog("hello world") ;
}
if ( ! $var(auth_code) ) {
         www_challenge("", "0");
         exit;
}
######################

If I include either xlog call then opensips fails to start from init.d

Any tips here?

Regards,
Jeff

_______________________________________________
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users

Reply via email to