[OpenSIPS-Users] Request forwarding and topology hiding with b2b_init_request

Eugene Prokopiev enp at itx.ru
Thu Aug 28 07:15:39 CEST 2014


Hi,

My network scheme looks like:

10.10.2.2 ---> (10.10.2.1|10.10.1.1) ---> 10.10.1.2

I have two separate networks (10.10.1.0/24 and 10.10.2.0/24) without
routing between them. I have opensips-1.11.2 installed and with
interfaces in each network. I need to forward all requests from
10.10.2.2 to 10.10.1.2 and foward responses back.

My initial config was:

mhomed=yes
auto_aliases=no
disable_tcp=yes

mpath="/usr/lib64/opensips/modules/"

loadmodule "mi_fifo.so"
loadmodule "sl.so"

modparam("mi_fifo", "fifo_name", "/tmp/opensips_fifo")

route {
  forward("10.10.1.2:5060");
}

All requests was forwarded fine, but I see unchanged ip address from
network 10.10.2.0/24 in all requests headers forwarded to 10.10.1.2. I
need to see ip address only from network 10.10.1.0/24 in this
requests.

So, I tried to use b2b_init_request:

mhomed=yes
auto_aliases=no
disable_tcp=yes

mpath="/usr/lib64/opensips/modules/"

loadmodule "mi_fifo.so"
loadmodule "sl.so"
loadmodule "tm.so"
loadmodule "b2b_entities.so"
loadmodule "b2b_logic.so"

modparam("mi_fifo", "fifo_name", "/tmp/opensips_fifo")

modparam("b2b_logic", "db_mode", 0)
modparam("b2b_entities", "db_mode", 0)

route {
  b2b_init_request("top hiding");
  forward("10.10.1.2:5060");
}

There are no significant improvements with this configuration. I see
my original INVITE and many additional INVITE requests with UserAgent
: OpenSIPS, forwarded to 10.10.1.2, but headers contains ip addresses
from network 10.10.2.0/24.

What is wrong in my configuration? How to make the real topology hiding?

-- 
WBR,
Eugene Prokopiev



More information about the Users mailing list