Do some renaming to avoid name conflicts with the OS object from osfile.jsm
Put ruleset database in a place where it can be safely replaced and reloaded from
Removed unused code