I am genuinely interested how this can be prevented. I don't see how it can. We are not far away from people having eyeglasses that are able to upload photos and download aggregated data. Everyone in your field of vision will have a dossier. It won't just be governments using this. It won't require some prior written permission. The same people that sold browsing data to advertisers will have this technology.
That is exactly what I wrote. Any government official/employee will be able to use this technology. If you are proposing some kind of libertarian non-government, that would be consistent with my original statement that the only way to limit this is to limit government.