I carry out the training task on networks. At one stage, the following should occur:
- A packet sent to computer # 3 from computer # 4 is sent to an address that is not represented on the network (for example, 123.123.123.123)
- on computer No. 3, the received packet is redirected to computers No. 1 and No. 2 (that is, it is necessary to duplicate and replace the destination address)

Tried to do as follows:
# дублируем все пакеты, предназначенные для 123.123.123.123, на компьютер №2 iptables -t mangle -A PREROUTING -d 123.123.123.123 -j TEE --gateway 6.6.1.1 # изменяем поле назначения непродублированных пакетов на адрес компьютера №1 iptables -t nat -A PREROUTING -d 123.123.123.123 -j DNAT --to-destination 6.6.0.1 To computer number 1 packages reach. Packets arrive (duplicated) and to computer # 2 - but their destination fields remain unchanged (123.123.123.123)
The problem is that I could not find a way to duplicate traffic with putting the correct fields (in particular the destination)