hello, I got the same issue. my sip device getting ok from kamailio, but asterisk reply 401.
but.
this is my config: http://pastebin.com/jGCak01E

and I changed regfwd route to
        $du = "sip:50.0.0.10:5060;transport=udp";
        forward();

and now I see this in logs:

Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [parser/msg_parser.c:633]: parse_msg(): SIP Reply  (status):
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [parser/msg_parser.c:635]: parse_msg():  version: <SIP/2.0>
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [parser/msg_parser.c:637]: parse_msg():  status:  <200>
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [parser/msg_parser.c:639]: parse_msg():  reason:  <OK>
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [parser/parse_via.c:1284]: parse_via_param(): Found param type 232, <branch> = <0>; state=16
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [parser/parse_via.c:2672]: parse_via(): end of header reached, state=5
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [parser/msg_parser.c:513]: parse_headers(): parse_headers: Via found, flags=2
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [parser/msg_parser.c:515]: parse_headers(): parse_headers: this is the first via
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [receive.c:152]: receive_msg(): After parse_msg...
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: tm [t_lookup.c:1071]: t_check_msg(): DEBUG: t_check_msg: msg id=25 global id=24 T start=(nil)
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [parser/parse_addr_spec.c:176]: parse_to_param(): DEBUG: add_param: tag=006cfccc318be31188fc19977b3a5651
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [parser/parse_addr_spec.c:885]: parse_addr_spec(): end of header reached, state=29
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [parser/msg_parser.c:190]: get_hdr_field(): DEBUG: get_hdr_field: <To> [63]; uri=[sip:77.37.241.151:5060
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [parser/msg_parser.c:192]: get_hdr_field(): DEBUG: to body [<sip:77.37.241.151:5060>]
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [parser/msg_parser.c:170]: get_hdr_field(): get_hdr_field: cseq <CSeq>: <1> <OPTIONS>
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: tm [t_lookup.c:1045]: t_reply_matching(): DEBUG: t_reply_matching: failure to match a transaction
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: tm [t_lookup.c:1140]: t_check_msg(): DEBUG: t_check_msg: msg id=25 global id=25 T end=(nil)
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [parser/msg_parser.c:204]: get_hdr_field(): DEBUG: get_hdr_body : content_length=0
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [parser/msg_parser.c:106]: get_hdr_field(): found end of header
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [forward.c:784]: do_forward_reply(): reply cannot be forwarded - no 2nd via
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [usr_avp.c:644]: destroy_avp_list(): DEBUG:destroy_avp_list: destroying list (nil)
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [usr_avp.c:644]: destroy_avp_list(): DEBUG:destroy_avp_list: destroying list (nil)
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [usr_avp.c:644]: destroy_avp_list(): DEBUG:destroy_avp_list: destroying list (nil)
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [usr_avp.c:644]: destroy_avp_list(): DEBUG:destroy_avp_list: destroying list (nil)
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [usr_avp.c:644]: destroy_avp_list(): DEBUG:destroy_avp_list: destroying list (nil)
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [usr_avp.c:644]: destroy_avp_list(): DEBUG:destroy_avp_list: destroying list (nil)
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [xavp.c:448]: xavp_destroy_list(): destroying xavp list (nil)
Feb  3 15:13:38 kamaz /usr/sbin/kamailio[14502]: DEBUG: <core> [receive.c:296]: receive_msg(): receive_msg: cleaning up


any ideas?
and show me ur conf please.


--

Hi All,


I'm running into an issue, I'm not sure whether any of you seen this
yourselves and resolved it. Please share some pointers. My network is:

clients <--> Public IP(Kamailio/RTPProxy)10.1.128.11 <--> 10.1.128.34
(Freeswitch)

The 200 OK response from Freeswitch (on the way back from called party to
caller) to Kamailio is shown below. Notice the Contact header URI host part
contains Freeswitch Private IP (10.1.128.34). Kamailio suppose to change
that to Public IP before forwarding the 200 OK (copied below) to Caller in
public domain. But, it's not. As a result, ACK from Caller is not reaching
back to Kamailio.

How did you or anybody out there using Kamailio resolve this problem? If
needed, I can copy/paste my kamailio.cfg.

--
yours respectfully, Alexander Vasin.

8 926 1437200
icq: 9906064