Genuine question: is it the act of recording that is illegal or is it the publishing of recorded material where this applies?
Also there are limitations, e.g. implicit consent or "panoramic freedom" (when the people on the picture are not recognizable).
I assume there also have to be carveouts for newspaper/magazine editorial.