I got hundreds of networks with Mikrotik routers and need to build a layer 2 tunnel between each of that networks and windows client for using the tools that works only inside LAN (no TCP/IP). One of the possibility I see it to make a RouterOS “client” device, create the tunnel and provide one of the “routeros client”'s ports to be bridged with the tunnel but I need hundreds of the ports… Is there any soft that could dynamically up and down some kind of the tunnels with Mikrotik on other side?
The older versions of OpenVPN clients for Windows can use L2 tunneling. Other than that, one of the many projects named iptools includes a part called ubridge that can bridge an “L2 loopback” interface with another bridge using VXLAN, https://sourceforge.net/projects/iptools/files - but the last update took place 10 years ago so it might require some work to make it compatible with contemporary releases of Windows. You can also run a CHR as a VM in Hyper-V on the Windows machine.
@gosha; Managing hundreds of manual tunnels is a nightmare without proper enterprise-grade network management tools.
If your Mikrotik routers are ARM based, I strongly recommend checking out ZeroTier that is part of ROS v7. It supports Layer 2 bridging and can scale to manage hundreds or even thousands of networks and devices with ease.
If running it on the router is not possible, you can also install ZeroTier directly on each computer as an alternative.
Both methods are cleaner and more scalable than trying to build and maintain static tunnels manually.