Add user data policy note to MDN registration page(s)

VERIFIED FIXED in 0.9.3

Status

Mozilla Developer Network
Demo Studio / Dev Derby
--
blocker
VERIFIED FIXED
7 years ago
5 years ago

People

(Reporter: jay, Assigned: oremj)

Tracking

unspecified
0.9.3

Details

Attachments

(1 attachment)

(Reporter)

Description

7 years ago
After talking to legal about this, we need to find a way to add some language to the MDN registration page about how we plan to use their data.  Recommended text is:

"Your contact information will only be used for developer related communications from Mozilla."

Based on conversations so far, there are a number of ways we can accomplish this, but a few of them are not possible or technically challenging:

1. Update the registration page in Deki with a footnote.
2. Add the text in parenthesis next to the "Email" field title.
3. Add a bar to the footer (above the feedback bar) with the text and only display it on the registration page.

According to Sheppy, #1 is not possible since Deki has that page locked down from edits.

Not sure if we can change the title of the form field to include the new text somehow for #2.

The easiest solution might be #3 if Craig can find a way to add that to the Deki template and only display for the registration page URLs.

Craig: Do you think you can make #3 happen? 

Sheppy:  Do you know if we can manage the form fields for that page via the Deki admin panel?

Due to the nature of Demo Studio and the expected bump in new members, this needs to be implemented before we go live for 0.9.3.  Marking blocker.
(Reporter)

Updated

7 years ago
Blocks: 622182
I've added the language to the Deki registration page in r82338, though it has to be implemented as a plugin so it will take some additional effort to get it into production.

Mindtouch keeps all of its special page plugins in [site root]/deki/plugins/special_page/ so that's where our modified version has to go. 

Each plugin gets its own folder and ours will be at [site root]/deki/plugins/special_page/special_userregistration_mdn/special_userregistration_mdn.php (note Deki requires the folder and php file to have identical names).

Once that file and folder are in place, we have to activate the plugin by modifying LocalSettings.php in the Deki root to add:

$wgDekiSpecialPages[] = 'special_userregistration_mdn';

See LocalSettings.php.dist for reference.

And that should be that.
(Reporter)

Comment 2

7 years ago
oremj:  can you please get this working on stage9 so we can test and verify before it's time to push to production?
Assignee: nobody → jeremy.orem+bugs

Comment 3

7 years ago
Thanks for adding me Jay. I'm adding Alex Fowler as well.
(In reply to comment #2)
> oremj:  can you please get this working on stage9 so we can test and verify
> before it's time to push to production?

Let me know if you have questions or hit any snags. Deki makes us jump through hoops to achieve the simplest of goals...
(Assignee)

Comment 5

7 years ago
This is done.
Status: NEW → RESOLVED
Last Resolved: 7 years ago
Resolution: --- → FIXED
(Reporter)

Comment 6

7 years ago
(In reply to comment #5)
> This is done.

Thanks Oremj.  Did you make the change to LocalSettings.php as well?  I ask because I am not seeing anything new yet on stage9.

Craig:  Anything we need to do on the Deki admin panel?
Status: RESOLVED → UNCONFIRMED
Ever confirmed: false
Resolution: FIXED → ---
No, there's nothing we need to do in the admin panel, it should "just work" (with heavy emphasis on the "should"). It works for me locally in my Deki VM, but stage and prod may differ so I'm not sure what else we may need to do there.
Status: UNCONFIRMED → RESOLVED
Last Resolved: 7 years ago7 years ago
Resolution: --- → FIXED
(Reporter)

Comment 8

7 years ago
Sorry, reopening since these changes haven't had the effect we are looking for on the registration page.

oremj: could you double-check the changes you made and work with craig to see if things match what he has on his local server?
Status: RESOLVED → REOPENED
Ever confirmed: true
Resolution: FIXED → ---
(Assignee)

Comment 9

7 years ago
Bah, I forgot to update LocalSettings.php. Done now.
Status: REOPENED → RESOLVED
Last Resolved: 7 years ago7 years ago
Resolution: --- → FIXED
Looks like a naming collision with an existing plugin that I thought was disabled. I renamed the function in r82610, which seems to have fixed that error at least, but I still don't see the message on the signup page. I have no idea why that may be or what else we need to do. We might have to contact Mindtouch for help.

Failing that, I can try to find a way to detect when a specific page is loaded and show a notice on that page alone, but I'm not sure Deki provides the right logical hooks to do that.
(Reporter)

Comment 11

7 years ago
reopening so we can update with craig's latest patch.

let's see if that works and if not, we can ping mindtouch.

craig: do you have access to file tickets with mindtouch?

cc'ing sheppy in case he can help in any way.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
You can replace the default login/registration form with your own by simply dropping in a replacement. I don't know details about how this works. Is that what you want me to check with MindTouch on? Simply cc'ing me doesn't really tell me what you want me to ask MindTouch about here. :)
(Reporter)

Comment 13

7 years ago
(In reply to comment #12)
> You can replace the default login/registration form with your own by simply
> dropping in a replacement. 

I thought you said we cannot edit that page?  The login/registration needs to be for Deki accounts, since Deki is our master record for MDN users right now.  Is there a workaround to editing that particular page?  Can we create an entirely new one with the right hooks and have it update the Deki database?

I don't know details about how this works. Is that
> what you want me to check with MindTouch on? Simply cc'ing me doesn't really
> tell me what you want me to ask MindTouch about here. :)

Commend #1 seems to have a nice summary of the changes Craig made.  If you need more details, please ask here so he can share more.

I think the basic question for you is:  Are we missing any steps for activating a custom plugin for Deki that will add a bar to the registration page with the copy we need regarding user date?
We can certainly modify the original form, but it's core Deki code that can be overwritten in a future update so that's usually something to avoid. If it comes to that we can still do it and just have to deal with the consequences. If/when MDN ever upgrades to Mindtouch 10 we'll probably have to edit the registration page again.

So we need to ask Mindtouch how to add text to the registration page without modifying core code that is likely to be overwritten. If they tell us it can't be done, so be it, we'll just hack the page and upgrade carefully from now on.

I'm also just curious why this plugin method works locally but not on stage9. It *can* be done. I've seen it. There's either something different between the two servers or we missed some step in deploying the code, and it's the mystery that vexes me.
(Assignee)

Comment 15

7 years ago
Craig, should this bug be assigned to you at this point?
(Reporter)

Comment 16

7 years ago
Assigning to Craig.

If we can't figure out why the plugin is not working, let's get a simple patch in for hacking the Deki code to show the necessary legal copy.  It's a one-liner and if we accidentally update the code and overwrite that, we can always do this all over again. ;-)

We can add the disclaimer below the registration form and be done with it.  Any objections?
Assignee: jeremy.orem+bugs → craigcook.bugz
(In reply to comment #16)
 
> We can add the disclaimer below the registration form and be done with it.  Any
> objections?

No objections here. I don't like touching core code as a rule, but in this case we're not doing anything to affect any functionality and if our changes are overwritten it will do no real harm. Plus it's not as if Deki gets updated all that often anyway.

I'll add the line to the reg form today.
Updated in r82675.

The file in question is /deki/plugins/special_page/special_userregistration/special_userregistration.php but it's not autosyncing from SVN (I suspect only the /skins/ folder is set up for that) so we I think we have to push that manually.

While we're at it, we can also remove the line we added to LocalSettings.php since we don't need it any more.
Assignee: craigcook.bugz → jeremy.orem+bugs
(Assignee)

Comment 19

7 years ago
I've removed this:
$wgDekiSpecialPages[] = 'special_userregistration_mdn';

and copied over the file mentioned in comment 18.
Status: REOPENED → RESOLVED
Last Resolved: 7 years ago7 years ago
Resolution: --- → FIXED
Ok, reopening since this is still a blocker. I'm STILL not seeing this on stage9. There is something very funky going on here. This last update modified the ORIGINAL CODE and yet stage9 is not showing the modified page. Inconceivable. 

So I'm guessing this means stage9 is showing some other page besides the original registration page. And that's been the case all along, that might explain why the previous plugin didn't work either. Since I can't poke around in stage9's files I can't see what's happening.

So I'm completely baffled. Is there a cache that needs to get purged maybe?
Assignee: jeremy.orem+bugs → craigcook.bugz
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
(Assignee)

Comment 21

7 years ago
If it helps, this is a svn diff against dekiwiki source:

[root@mradm02 dekiwiki9]# svn diff
Index: includes/DefaultSettings.php
===================================================================
--- includes/DefaultSettings.php	(revision 23248)
+++ includes/DefaultSettings.php	(working copy)
@@ -696,6 +696,7 @@
 
 $wgVarnishCache = null;
 $wgVarnishMaxage = 18000;
+$wgFeedMaxAge = null;
 
 $wgSessionsInMemcached = false;
 $wgMemCachedServers = array();
Index: deki/plugins/special_page/special_advanced_properties.php
===================================================================
--- deki/plugins/special_page/special_advanced_properties.php	(revision 23248)
+++ deki/plugins/special_page/special_advanced_properties.php	(working copy)
@@ -278,13 +278,15 @@
 		}
 		else
 		{
-			foreach ($properties as $name => &$value)
-			{
+			foreach ($properties as $name_raw => &$value_raw)
+			{			
+			        $name = htmlspecialchars($name_raw);
 				$Tr = $Table->addRow();
 				$Tr->setAttribute('id', 'deki-pageproperties-'. md5($name));
-				
+
+				$name_encoded = htmlspecialchars($name);
 				$Td = $Table->addCol(
-					DekiForm::singleInput('checkbox', 'property_names[]', $name, array(), $name)
+					DekiForm::singleInput('checkbox', 'property_names[]', $name_encoded, array(), $name_encoded)
 				);
 				$Td->setAttribute('colspan', 2);
 				$Td->addClass('name');
Index: deki/plugins/special_page/special_userregistration/special_userregistration.php
===================================================================
--- deki/plugins/special_page/special_userregistration/special_userregistration.php	(revision 23248)
+++ deki/plugins/special_page/special_userregistration/special_userregistration.php	(working copy)
@@ -229,6 +229,7 @@
 		$Title = Title::newFromText('UserRegistration', NS_SPECIAL);
 		// build the markup
 		$html = '<form class="user-registration" method="post" action="'. $Title->getLocalUrl() .'">';
+		$html .= '<p>Your contact information will only be used for developer related communications from Mozilla.</p>';
 		
 		// username field
 		$html .= '<div class="field">';
Index: deki/core/deki_request.php
===================================================================
--- deki/core/deki_request.php	(revision 23248)
+++ deki/core/deki_request.php	(working copy)
@@ -160,7 +160,7 @@
 	public function getInt($key, $default = null)
 	{
 		$val = $this->get($key, $default);
-		return $val == $default ? $val : intval($val);
+		return $val == $default ? $default : intval($val);
 	}
 	
 	public function getVal($key = null, $default = null) 
Index: favicon.ico
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream
(Assignee)

Comment 22

7 years ago
Here are the SpecialPages settings:
[root@mradm02 dekiwiki9]# cat LocalSettings.php  | grep Special
$wgDekiSpecialPages[] = 'special_userregistration_mdc';
$wgDekiSpecialPages[] = 'special_tagrename';
$wgDekiSpecialPages[] = 'special_diespammers';
$wgDekiSpecialPages[] = 'special_userregistration_recaptcha';
(In reply to comment #22)
> $wgDekiSpecialPages[] = 'special_userregistration_recaptcha';

I believe this one is the page being shown currently, so this is the one we need to modify but it isn't in SVN. 

oremj, can you find this file and add it to SVN (or attach it to the bug)? It'll occupy its own folder, named "special_userregistration_recaptcha", and will be in either /plugins/mindtouch/ or in /deki/plugins/special_page/. Then I can make the edit and we should (hopefully, finally, fingers crossed) be done.
Pinging oremj

Can you get the special_userregistration_recaptcha file into SVN so I can make this change? I'm hoping it's a simple edit, I just don't have access to the file.
Pinging again. This is assigned to me and is still a blocker for the release but I can't fix the problem until someone can get me the file to edit. Should I reassign?
I have no idea who's supposed to do what here. I assume oremj needs to get you this file, but I'm not really sure.
Created attachment 515946 [details]
recaptcha user reg page from dekiwiki
Attached what I found from dekiwiki9
(In reply to comment #28)
> Attached what I found from dekiwiki9

Thanks!

Added statement in r83564, let's see if this works... Not sure if this auto-syncs to stage or has to be pushed manually. And I don't have a password for stage9 now that it's locked up so someone else may need to verify.
(Reporter)

Comment 30

7 years ago
I still don't see anything at https://developer-stage9.mozilla.org/Special:UserRegistration

Assigning to oremj to see if he needs to push anything manually to get this thing working.
Assignee: craigcook.bugz → jeremy.orem+bugs
(Assignee)

Comment 31

7 years ago
Unfortunately, special_userregistration_recaptcha is part of dekiwiki, so we need to locally patch instead of replacing the whole directory.

[root@mradm02 special_userregistration_recaptcha]# diff --exclude='.svn' -ru ./ /data/devmostage/www/dekiwiki_mozilla/deki/plugins/special_page/special_userregistration_recaptcha/ | patch -p0 
patching file ./special_userregistration_recaptcha.php
[root@mradm02 special_userregistration_recaptcha]# svn diff
Index: special_userregistration_recaptcha.php
===================================================================
--- special_userregistration_recaptcha.php	(revision 23248)
+++ special_userregistration_recaptcha.php	(working copy)
@@ -195,6 +195,7 @@
 		$Title = Title::newFromText('UserRegistration', NS_SPECIAL);
 		// build the markup
 		$html = '<form class="user-registration" method="post" action="'. $Title->getLocalUrl() .'">';
+		$html .= '<p>Your contact information will only be used for developer related communications from Mozilla.</p>';
 		
 		// username field
 		$html .= '<div class="field">';
Status: REOPENED → RESOLVED
Last Resolved: 7 years ago7 years ago
Resolution: --- → FIXED
(Reporter)

Comment 32

7 years ago
Thanks oremj!  I see the copy now at the top of the registration page at https://developer-stage9.mozilla.org/Special:UserRegistration.

Marking v.fixed.
Status: RESOLVED → VERIFIED
Version: MDN → unspecified
Component: Demos → Demo Studio / Dev Derby
Product: Mozilla Developer Network → Mozilla Developer Network
You need to log in before you can comment on or make changes to this bug.