Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Customize privacy options on installation #6581

Merged
merged 9 commits into from Nov 3, 2014

Conversation

mnapoli
Copy link
Contributor

@mnapoli mnapoli commented Nov 3, 2014

This PR addresses #5052 and #6566 (as well as #6579 which is included in the first one).

It contains an update script for 2.9 that will disable IP anonymization if it wasn't configured before. The reason is that we change from "disabled by default" to "enabled by default", so we don't want to enable it on previous Piwik installs.

It also adds a new form in the last installation step. This form is dynamic and constructed with events so that there is no explicit mention of other plugins (as suggested by @tsteur), that means that plugins can add their own field here (but I guess it shouldn't be abused).

The form shows the default settings. The user can then submit the form which will saves his settings in the database. If he refreshes Piwik to get to the homepage somehow, then he will still use the default settings so all is good ("do not track" and "IP anonymization" are enabled by default).

screen

Please review as it affects upgrade and installation, and I guess we really don't want to break those parts ;)

@mnapoli mnapoli self-assigned this Nov 3, 2014
@mnapoli mnapoli added this to the Piwik 2.9.0 milestone Nov 3, 2014
@mnapoli mnapoli added Pull Request WIP Indicates the current pull request is still work in progress and not ready yet for a review. Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc. labels Nov 3, 2014
@@ -2,6 +2,7 @@
"PrivacyManager": {
"AnonymizeIpDescription": "Select \"Yes\" if you want Piwik not to track fully qualified IP-Addresses.",
"AnonymizeIpInlineHelp": "Anonymize the last byte(s) of visitors IP addresses to comply with your local privacy laws\/guidelines.",
"AnonymizeIpExtendedHelp": "When users visit your website, Piwik will not use the full IP address (such as 213.34.51.91) but instead Piwik will anonymise it first (to 213.34.0.0). IP address anonymisation is one of the requirements set by the privacy laws in some countries such as Germany.",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here you could maybe replace 213.34.51.91 and 213.34.0.0 by %1$s and %2$s and sprintf the values so translators cannot make typos

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@mattab
Copy link
Member

mattab commented Nov 3, 2014

It also adds a new form in the last installation step. This form is dynamic and constructed with events so that there is no explicit mention of other plugins (as suggested by @tsteur)

nice idea 👍

PR looks good to me!

}

$view->addForm($form);

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should I add Piwik::checkUserHasSuperUserAccess(); in this installation step? Because it doesn't do $this->checkPiwikIsNotInstalled(); like in the other steps, so I guess anybody can go to this step?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good for spotting this! 👍

…dy installed

The last step is now also not optional, you need to visit the page to mark installation as finished
mattab pushed a commit that referenced this pull request Nov 3, 2014
Customize privacy options on installation
@mattab mattab merged commit 56e9596 into master Nov 3, 2014
@mnapoli mnapoli deleted the installation_privacy_options branch November 4, 2014 01:29
@mattab mattab added the c: Privacy For issues that impact or improve the privacy. label Aug 17, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c: Privacy For issues that impact or improve the privacy. Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc. Pull Request WIP Indicates the current pull request is still work in progress and not ready yet for a review.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants