The Agreement Governing the Activities of States on the Moon and Other Celestial Bodies, better known as the Moon Treaty or Moon Agreement, is an international treaty that turns jurisdiction of all celestial bodies (including the orbits around such bodies) over to the international community. Thus, all activities must conform to international law (notably this includes the UN Charter).
In practice it is a failed treaty since it has not been ratified by any nation which engages in self-launched manned space exploration or has plans to do so (e.g. the United States, some member states of the European Space Agency, Russian Federation, People’s Republic of China, Japan, and India) since its creation in 1979, and thus has a negligible effect on actual spaceflight.
Wikipedia article Moon Treaty
They tried to make laws about behavior on the moon but nobody who’s even come close to the moon signed it. Very telling.
(Also they included “Other Celestial Bodies” so Mars gets policed too.)