Added license file.
Added functionality for storing rules.