The Umbrella Corporation wrote:
I also believe the Baku and Sona are not trespassing. They were there before the Federation, Romulan, Klingon empires were formed.
The ring planet was the Romulan Empire's territory at the time that the Baku arrived there. This comes from ENT during the augment arc.
The planet and the entire briar patch changed hand a few times eventually becoming federation territory. In the movie, the Enterprise crew knew about conditions in the briar patch (no warp, reduced impulse speeds) so at some point the federation surveyed the patch (or someone did it for them).
While true the federation hadn't formed yet, it's unclear if the Klingon Empire was already in existence.