The users can now be dumped and loaded as JSON objects. This allows easier parsing and handling of users while still retaining the possibility to manually edit the output. Added tests for dumping and loading the JSON form users. Also fixed a deadlock in Users::remove() where the same lock was acquired twice and a faulty test case where failed authentication was expected to work.