The simple fact of the matter is that due to how this data is created, it's publicly accessible information: All airplanes flying in civilian airspace are required to broadcast ADS-B data for safety reasons. It gives controllers (and other aircraft in your nearby airspace) a view of what's happening. Your airplane essentially broadcasts a payload every second that sends out your GPS coordinates, heading, speed, altitude, aircraft identification information, etc.
The COOL thing (speaking as an aviation geek), is that you can buy a cheap little antenna, plug it into a Raspberry Pi and start seeing these raw packets from airplanes FLYING OVER YOUR HOUSE. FlightRadar24 and ADSB Exchange basically crowd source a bunch of real-time data from people who have these antennas and are running various types of software.
Basically, since this is happening in public view and the data is available (primarily for safety reasons), then there is really no reasonable expectation of privacy. In a way, it's like people taking a photo of you on the street and posting about it -- since you're in a public space, there is no expectation of privacy. You might not like it, morally it might feel wrong, but there is no reasonable legal reason that bans this.
Fortunately (for Elon), he is a billionaire and can lobby to change laws he doesn't like if he so wishes.
I don’t question the legal right to use this data this way, although I think good arguments could be made that if you are using the data this way, your intention is suspicious and you invite scrutiny. I am challenging the folks commenting here that the data being used this way is a positive use of the data.