Adding the webservices plugin (Bug 1393530)

Adding in the plugin from
https://github.com/piersharding/mahara-contrib-auth-webservice

Change-Id: Ib5dea8c908cb5fd225687ecd37e80dc211dbe5f2
Signed-off-by: Robert Lyon <robertl@catalyst.net.nz>
Tidying up the initial code to mahara standards (Bug #1393530)

Change-Id: I398479c34771df1978a98ac42b1b866afe4e7917
Signed-off-by: Robert Lyon <robertl@catalyst.net.nz>
Handling webservices validate_password better (Bug 1393530)

Getting it to use the internal validate_password() function instead of
just repeating what it does

Change-Id: Iad1d39a1f7a212ec425ce5ed2a09d7409aa9fd88
Signed-off-by: Robert Lyon <robertl@catalyst.net.nz>
Restricting the institution get members (Bug 1393530)

to only those in the institution indicated

Change-Id: Ic4292676017af5f6aecdb491880901e84027dca6
Signed-off-by: Robert Lyon <robertl@catalyst.net.nz>
Fix data in service group on creation

Bug #1396433: Service groups should be disabled upon creation,
and tokenuser cannot be null (or it'll crash)

Change-Id: Id33279390c275e4c1b6f5316d85700a445970d71
Signed-off-by: Robert Lyon <robertl@catalyst.net.nz>
Change webservice config to not have nested Pieforms (Bug #1397128)

The webservices config had a parent Pieform without <form> tags,
which was used solely for layout. Inside this it nested other Pieforms.
This caused problems due to the nested forms (fieldsets and legends
didn't work properly).

This patch replaces the parent Pieform with a Dwoo template to avoid
those problems.

Change-Id: Ic5b8fa935f403e1002669efa315627f110bcdcc3
Signed-off-by: Robert Lyon <robertl@catalyst.net.nz>
Merge changes Ic5b8fa93,Id3327939,Ic4292676,Iad1d39a1,I398479c3,Ib5dea8c9

* changes:
  Change webservice config to not have nested Pieforms (Bug #1397128)
  Fix data in service group on creation
  Restricting the institution get members (Bug 1393530)
  Handling webservices validate_password better (Bug 1393530)
  Tidying up the initial code to mahara standards (Bug #1393530)
  Adding the webservices plugin (Bug 1393530)