Background
The IP reveal access policy allows users to automatically gain the right to reveal IP addresses for temporary accounts if:
- User account is a minimum of 6 months old, and
- User account has made a minimum of 300 edits to the local project.
As discussed in the parent task (T327913), we will use the AutoPromoteOnce mechanism for this. An alternative would be to use AutoPromote but it wouldn't be possible to revoke access.
It is worth reading the following documentation pages:
- https://www.mediawiki.org/wiki/Manual:$wgAutopromote
- https://www.mediawiki.org/wiki/Manual:$wgAutopromoteOnce
Technical background
Useful reading:
AutopromoteOnce groups are added to a user's groups in UserGroupManager::getUserAutopromoteOnceGroups.
This checks the user against the AutoPromoteOnce config, which defines which user groups a user can be automatically added to, and what the criteria are for adding a user to each group. This config also defines what type of event should trigger such a check (e.g. when a user edits, when a user views the page).
MediaWiki defines some autopromote conditions, including APCOND_EDITCOUNT and APCOND_AGE which we will use here.
What needs doing here
- Create the checkuser-temporary-account-viewer group on wikis with temporary accounts enabled
- Add an entry to AutoPromoteOnce in operations/mediawiki-config to auto-promote users into the above group when they meet the requirements listed in the background section