== Background ==
Years ago, we would make a GeoIP lookup using a script tag added to the skin by CentralNotice. This was necessary to correctly geotarget campaigns to users, without splitting cache, etc.
This loading method has been deprecated thanks to some great work by @ori and others, and removed from the CentralNotice extension. At this point, the only thing remaining is some Javascript which parses a cookie value set by Varnish VCL into the window.Geo global. Please note that CentralNotice only uses country-level information, the rest of the data is being stored for use by other extensions.
== Recommendation ==
Let's decouple GeoIP from CentralNotice. It could go into MediaWiki core or better yet, its own library and subsystem. Not sure what the best form would be.
Everything which depends on the Geo variable should have an explicit dependency to this library.
We should audit the privacy implications of all geodata usages.
== Considerations ==
The last I checked, the following extensions make use of GeoIP:
- CentralNotice
- CoreEvents
- ImageMetrics
- NavigationTiming
- Petition
- UniversalLanguageSelector
- WikimediaShopLink
The following extensions seem to be performing their own geolocation:
- DeviceMapLogCapture
- DonationInterface
- FundraiserLandingPage
- LandingCheck
- SecureSessions