Jaring: add function checkAccess and handleRequest.

* _out: variable to save json output.
* checkAccess: server side check of user permission.
* handleRequest: simple RESTful.