[467999] support model obfuscation of UML models and add uml based
plugins to the build

	menu contribution added to "Sample Ecore Model Editor" and "UML Model
Editor"
	Obfuscator encoding has been modified to avoid invalid characters (like
"=").

	Integrated into papyrus editor.
	When start obfuscation from papyrus, the obfuscation map will be
printed to the console.
	Profile obfuscating corrections (base_*, http* and extension_*
handling).
	Correct obfuscation for enums.

	New feature: replace old profile's of an uml model to an obfuscated
pair of it (works only in uml editor).
	Clear and comment code and renaming classes.
	UML obfuscation prefix concation replaced to the StringObfuscator

	Tests for UML obfuscation.
	Test for simple uml profile replacer.

	Add profile replacer to papyrus menu
	Profile replacer undo/redo support.
	Organize required plugins for uml based plugins

	create and extend POMs
	updated tycho version to 0.23.0	
	moved ui.uml to plugins folder
	added UML to target platform
	downgraded EMF in MANIFEST.MF
	fixed plugin versions
	change UML plugins to Java 1.6
	added xtend-gen to build
	create separated feature for uml modules
	added plugin dependencies
	corrected names and vendor to overview
	write obfuscation map into csv file
	handle that no resource is loaded
	show commands when necessary
	handle readonly attributes

Signed-off-by: Tamás Borbás <borbastomi@gmail.com>
Change-Id: I121f544bcde92230aeba932a15efda5139be51d6
58 files changed
tree: 7cc59e33da9191b3de49be3bf72b9d16a2698fea
  1. features/
  2. maven/
  3. plugins/
  4. releng/
  5. README.md
README.md

VIATRA Model Obfuscator

Obfuscate: To deliberately make more confusing in order to conceal the truth (http://en.wiktionary.org/wiki/obfuscate)

The VIATRA Model Obfuscator is a small utility for obfuscating structured graph-like models (e.g. XML documents, EMF models) by altering all data values (such as names, identifiers or other strings) in a way that the structure of the model remains the same. Two data values that were identical before the obfuscation will also be identical after it, but the obfuscated value computed based on an input obfuscation string will be completely different (e.g. “Info1” may become “K18DWVQ=”).

For more details, read this blog post.

Overview

The current version of the model obfuscator (0.7.0) only obfuscates text content in XML files and String values in EMF models. The obfuscator API receives an obfuscation string (seed) and the input model, it traverses the model and replaces all data values with an obfuscated value that is deterministically computed based on the data value and the obfuscation string.

There are several different ways for using the obfuscator:

  • Eclipse UI contribution
  • Command line application
  • Maven plugin for integration through API usage
  • OSGi bundle for integration through API usage

Eclipse UI contribution

The EMF model obfuscator can be installed from the update site and the user can perform the obfuscation on any EMF model loaded into the generic or reflective EMF editors. The obfuscator does not save the models and it is possible to undo the changes. In addition, the error log will contain an entry that provides the random obfuscation string used. Resources that are not writable are not modified.

Command line application

Both XML and EMF model obfuscators can be used with a command line application, that can be downloaded from here. The application uses a few command line arguments and a properties file for configuration, examples for both XML and EMF are provided here. Calling the application without arguments displays the usage guide.

Maven plugin

The model obfuscator is available as a Maven plugin for projects that are POM first. The plugin simply wraps the OSGi runtime bundle into a Maven plugin and is available from repo.eclipse.org.

OSGi bundle

The core runtime of the model obfuscator is a simple OSGi bundle that can be added as a dependency of plugin projects. The API of the runtime is documented in JavaDoc and there are a set of JUnit tests that show the usage of the API for both XML and EMF.