test/xx.cfg
dda9dab1
 # forwarding to Cisco phone
 #
 # $Id$
 #
 
 
9598488f
 debug=9          # debug level (cmd line: -dddddddddd)
dda9dab1
 log_stderror=yes # (cmd line: -E)
 check_via=yes     # (cmd. line: -v)
 dns=on           # (cmd. line: -r)
 rev_dns=yes      # (cmd. line: -R)
4bd1673d
 fork=yes
 children=4
 #fork=no          # (cmd. line: -D)
dda9dab1
 port=5080
 #listen=127.0.0.1
 listen=192.168.99.100
 loop_checks=1
 # for more info: sip_router -h
 
 #modules
 loadmodule "modules/print/print.so"
 #loadmodule "modules/tm/tm.so"
 
4f3faaaf
 
ea6721d7
 route[0]{
dda9dab1
 	if ( t_lookup_request()) {
 		if ( method=="ACK" )	{
 			t_release();
 #			forward(195.37.77.100, 5090 );
 #			forward(195.37.78.146, 5060 );
 # once it supports ACK too
 #			t_forward(195.37.77.100, 5090 );
 			t_forward("195.37.78.146", "5060" );
 		} else {
 			t_retransmit_reply();
 		};
 		t_unref();
 	} else {
 		if (method=="ACK") {
 #			forward(195.37.77.100, 5090 );
 			forward(195.37.78.146, 5060 );
 		} else {
 			t_add_transaction();
 			if (method=="CANCEL") {
 				t_send_reply( "200", "glad to cancel");
 			} else {
 				t_send_reply("100", "trying -- your call is important to us");
 			};
 #			t_forward("195.37.77.100", "5090" );
 			t_forward("195.37.78.146", "5060" );
4bd1673d
 			break;
dda9dab1
 			t_unref();
 		};
 	};
 		
 }
ea6721d7
 
 #route[0] {
 #	forward(195.37.78.146, 5060);
 #	drop;
 #}