Make MYSQL Database Anonymous

Make MYSQL Database Anonymous

Alan Cherwinski -
回帖数:3

Hello,

I have a graduate student interested in running analysis on typical Moodle installations.  He requested a copy of my entire SQL database

I am not dealing with sensitive institutional learner data (corporate training), but is there any safe and quickly way to make the users anonymous at a db level?

The only work around I thought of was to create a new site and import anonymised courses and history and then export that db.

Thanks


Alan

回复Alan Cherwinski

Re: Make MYSQL Database Anonymous

Ken Task -
Particularly helpful Moodlers的头像

Don't think you want an anonymous MySQL user to be able to query remotely ... not even a system that contains non-sensitive data. Potential for *anyone* who can reach the DB server to possibly create a denial of service type attack.  

However, you could create a 'researcher' user in mysql and grant that user read only ... ie, no ability to change data.   User would have own password.

http://dev.mysql.com/doc/refman/5.1/en/adding-users.html

'spirit of sharing', Ken

回复Ken Task

Re: Make MYSQL Database Anonymous

Alan Cherwinski -

Hi Ken,

Thanks. I was not going to provide access to the live db but a copy of the dump file at .sql. I can go through the .sql (text file) and alter all the user names and email addresses.  I could probably alter the table prefix.


Thanks

回复Alan Cherwinski

Re: Make MYSQL Database Anonymous

Tim Hunt -
Core developers的头像 Documentation writers的头像 Particularly helpful Moodlers的头像 Peer reviewers的头像 Plugin developers的头像

The is not a simple question.

The answer starts out simple. Obviously you start with columns of

  • mdl_user - name, email, description ...
  • mld_user_info_data - custom use profile field values, if any.
  • mdl_user_preferences - not sure if there will be personal information there, but you should check.
But, then you need to start thinking about what users did with the Moodle site. E.g. where there any personal discussions in any forums? If so, they need to be anonymised somehow.

Did any quiz/questionnaire/feedback/survey ask students to submit personal information? If so you need to clean that up.

Any personal comments in Moodle notes or messages?

And so on.

The normal approach to anonymising the data is to replace all the string values in certain columns with random strings.