This extends to labor conditions as well as to crimes committed on board the ship, even if docked at a port.
The regulations extend to both labor practices and criminal activity aboard the vessel, regardless of whether it's in port or not.