Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Derby.js (Racer) access control

I'm new in Derby.js environment, and as far as I see Racer is exposing all the data on client side.

So, basically anybody could manipulate any data stored on server? Am I correct? Is there any way to manage access control?

like image 404
Dmitry Demidenko Avatar asked Dec 19 '13 15:12

Dmitry Demidenko


2 Answers

There is plugin for Racer - racer-access

Use it like this:

var racerAccess = require('racer-access');
derby.use(racerAccess);
store.allow('change', 'users', function (some usefull arguments) {
    return true || false;
});
like image 109
Vladimir Makhaev Avatar answered Nov 20 '22 06:11

Vladimir Makhaev


At now racer-access is deprecated. You can use share-access.

like image 2
KNOFF Avatar answered Nov 20 '22 05:11

KNOFF