[Serusers] forward_msg: no 2nd via found in reply

Cyprien Simons cyprien.simons at tu-berlin.de
Tue Jul 13 16:52:59 CEST 2004


Hi everybody,

I'm trying to use Asterisk as SUA and SER as SIP router. But Asterisk doesn't 
succeed to register the Asterisk user to SER... the standard error output 
tell me:
"ERROR: forward_msg: no 2nd via found in reply"

the SIP message looks like:

 to 193.175.133.19:5060
Retransmitting #5 (no NAT):
REGISTER sip:potemkin.fokus.fraunhofer.de SIP/2.0
Via: SIP/2.0/UDP 193.175.133.19:5060;branch=z9hG4bK625558ec
From: <sip:cys at potemkin.fokus.fraunhofer.de>;tag=as238e1f29
To: <sip:cys at potemkin.fokus.fraunhofer.de>
Call-ID: 6b8b4567327b23c6643c986966334873 at 193.175.133.19
CSeq: 102 REGISTER
User-Agent: Asterisk PBX
Expires: 120
Contact: <sip:1234 at 193.175.133.19>
Event: registration
Content-Length: 0

and the configuration file is like:

###main routing logic
route{
        # initial sanity checks -- messages with
        # max_forwards==0, or excessively long requests
        if (!mf_process_maxfwd_header("10")) {
                sl_send_reply("483","Too Many Hops");
                break;
        };
        if ( msg:len > max_len ) {
                sl_send_reply("513", "Message too big");
                break;
        };

        record_route();

        # Do strict routing if pre-loaded route headers present
	loose_route();

        # message should be from 127.0.0.1 or
        # from other listening address

        if (src_ip==127.0.0.1) {
                if (method=="REGISTER") {
                        save("location");
                        break;
                };
                if (uri == myself) {
                        # 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();
                };
        } else if (src_ip == myself) {
                # this is a request from local domain
                # but not from 127.0.0.1, must be from UA
                if (method=="REGISTER") {
                        # register message, save it and forward to
                        # security server
                        save("location");
                        forward (127.0.0.1, 4050);
                        break;
               };
                forward (127.0.0.1, 4050);
                break;
        };
}


I'm using ser 0.8.12, SuSE 9.1, Asterisk 0.9.1

I am quite new on SER, and I am trying to pursue the work of another person, 
so if something in it seems stupid, don't hesitate to tell me so...

Cyprien




More information about the sr-users mailing list