Would existing protections in the Geneva Conventions against targeting noncombatants apply to damaging infrastructure that leads to civilian fatalities?
And bridges and ports are among the priority targets for traditional air attacks to hamper enemy troop movements, supply lines and production capacity. I see no reason to prevent cyber attacks against them.
Probably the better question is whether everyone who might want to damage such infrastructure is in fact (a) a state actor who (b) was one of the signatories to the Geneva Conventions.