So, since I am British and have a UK registered boat and know a bit about this. The law that applies (The Merchant Shipping Act 1995 section 5) requires that we should fly the flag when entering or leaving a foreign port or upon a signal by one of Her Majestys ships [1]. Flying a flag routinely in international waters is very much not required, and very few vessels fly a flag out there, because there is not much there to look at it and it just flaps itself to bits.
With the trouble brewing with the Russian shadow fleet in the Baltics, flying a flag seem quite important unless you want the coast guard to stop you (they have also increased their presence significant the last 5-10 years and do a lot of random checks).
Who needs stealth when a cheap piece of fabric provides cover.
https://en.wikipedia.org/wiki/Russian_shadow_fleet
https://eutoday.net/eu-sanction-issuers-of-fake-flags-to-rus...
https://www.nytimes.com/interactive/2023/05/30/world/asia/ru...
https://www.nrk.no/vestland/xl/over-100-ships-have-sailed-wi...
You seem to really equate this with the idea of planes flying without filing a flight plan. Are you OK with the US military shooting down any plane that doesn't file a flight plan, without even trying to communicate with the vessel or intervene in any other way previously, even if that vessel doesn't appear to be heading towards any specific US territory or vessel? Is that also allowable under international law?
No. You're not supposed to be bombing any boat you find in international waters that doesn't have a flag on it for whatever reason you can come up with.
I wouldn't do that with the current US administration's actions and level of attention to detail.