I am working on a project which uses Docker containers. Docker is installed on a Windows 10 host machine. The aim of the project is to forward the data packets that are received on the host to the docker containers so that the container functions make use of those data packets and in turn forward them to other linked containers.
For eg, consider there are 2 containers(container 1 and container 2) running some arbitrary functions. The following has to be achieved:
Host(Windows 10)----->Container 1------->Container 2------->Host
where ------> represents packet forwarding(after the container functions work on them)
As of now, packets are received using Wireshark in the host which just receives the packet and displays the packet details. How can these received packets forwarded to the Docker containers from the host, and from one container to other? Can it be done using Scapy(host to container)? I know that container networking can be used to link different containers,but can data packets be forwarded between them?
Also, by any chance could python or java socket programming be used in the host and inside the containers in any of the context above? Could libraries such as libpcap be used for this purpose?