Problem in connecting Mosquitto broker with paho-mqtt native

Hi everyone ! I am running the example project paho-mqtt natively on a Linux machine and have no problem following the instruction up until trying to connect to my local mosquitto broker. I can ping the bridge tapbr0 ip address, but when I runcon [tapbr0 ip address], it fails to connect. The mosquitto broker is running fine but then I don’t understand why it didn’t work not sure with the example. Does anyone have any idea ?

Is the mosquitto broker running on the same host? Is it configered to only listen on a specific interface or address?

If it’s on a different host, you can bridge the virtual network with your real one by using the --uplink <interface> parameter of tapsetup, the interface might e.g. be your Ethernet interface eth0.

Hi, the broker is running on the same host and is configered to listen to all IPv6 at port 1883. I connected my real with the virtual with tapsetup -c1 -u eth0, so that my tapbr0 connects 2 interfaces tap0 and eth0