Hi,
I noticed that if I enable tcp_accept_haproxy kamailio still can accept connections without the PROXY-protocol header.
The documentation on the wiki has the following note:
"Please note that enabling this option will reject any inbound TCP connection that does not conform to the PROXY-protocol spec."
This could be true up until a specific version of kamalio but from 5.7.4+ this limitation is seems to be removed.
Enabling tcp_accept_haproxy is breaking the outbound/rr module because it con’t find the socket based on the address and port from the flow token.
The flow tokens created by a REGISTER on a connection without a PROXY header can be used.
Flow tokens created from a connection with PROXY-protocol header will fail with "cannot find socket from flow-token” once loose_route is invoked.
loose.c:561
/* First, force the local socket */
si = find_si(&rcv->dst_ip, rcv->dst_port, rcv->proto);
if(si)
set_force_socket(_m, si);
else {
LM_INFO("cannot find socket from flow-token\n");
return -1;
}
I’m not sure if the address and/or port values stored in the flow token are incorrect or the problem lies in the matiching in find_is(…).
Wolter