Commit Graph

96 Commits

Author SHA1 Message Date
Ritchie Martori 6bb0ba2d95 Add missing assert in user model 2014-01-10 10:07:39 -08:00
Ritchie fcc4bba82d Add reference documentation using sdocs 2013-12-19 17:49:47 -08:00
Raymond Feng a47317de0d Update README for application model 2013-12-19 13:42:12 -08:00
Ritchie Martori 16b790a93a Merge pull request #102 from strongloop/fix/user
Various Fixes and Behavioral Changes to the User Model
2013-12-18 21:34:30 -08:00
Raymond Feng ac2f4de9d3 Remove the default values for gateway/port 2013-12-18 12:28:48 -08:00
Raymond Feng 598b1e6b61 Reformat the code using 2 space identation 2013-12-18 11:49:09 -08:00
Raymond Feng 95ad3e8c04 Allow cert/key data to be shared by push/feedback 2013-12-18 10:58:34 -08:00
Ritchie Martori 98ed38302a Logout now automatically pulls the accessToken from the request 2013-12-17 21:22:05 -08:00
Ritchie Martori 939df463fe Fix tests depending on old behavior of default User ACLs 2013-12-17 21:10:05 -08:00
Ritchie Martori 3152960336 Add default user ACLs 2013-12-17 20:42:28 -08:00
Miroslav Bajtoš d09e3225cd Define schema for GCM push-notification settings
Remove unused property PushNotificationSettingSchema.platform.

Flatten GCM settings schema. There is no need to distinquish between
pushOptions and feedback, as there is only single HTTP channel shared
by both.
2013-12-17 18:44:13 +01:00
Ritchie Martori 0794f141c1 Improve debug statements for access control 2013-12-16 18:12:13 -08:00
Ritchie Martori b62b8fa47d Fix user not allowed to delete itself if user
**Note: the only code required for the fix is in role.js:203**. The
other changes are to help organize debug output.
2013-12-11 19:15:19 -08:00
Ritchie Martori ad58a8ec13 Only look at cookies if they are available 2013-12-11 16:43:23 -08:00
Raymond Feng 0f86f69880 Remove the empty comment and set default token 2013-12-11 16:21:37 -08:00
Raymond Feng 97dc0aa441 Refactor to the code use wrapper classes
Add AccessContext, Principal, and AccessRequest
Add debug information
2013-12-11 16:03:48 -08:00
Raymond Feng 178674ec9a Enhance getRoles() to support smart roles 2013-12-11 09:06:21 -08:00
Raymond Feng 82eeaeee6b Fix the algorithm for Role.isInRole and ACL.checkAccess 2013-12-10 23:33:57 -08:00
Ritchie Martori 4560ec0964 Various ACL fixes 2013-12-10 21:49:18 -08:00
Ritchie Martori b0f51e20f7 Add user default ACLs 2013-12-10 19:43:59 -08:00
Ritchie Martori dfcb43e613 Allow requests without auth tokens 2013-12-10 15:57:55 -08:00
Raymond Feng 7f51c28539 Fix the ACL resolution against rules by matching score 2013-12-09 15:26:53 -08:00
Ritchie Martori af2b8dd4ff Merge feature/password-reset 2013-12-06 17:35:14 -08:00
Ritchie Martori 216fee3015 Add access type checking 2013-12-06 17:04:47 -08:00
Ritchie Martori 2f9403016c Initial auth implementation 2013-11-22 12:26:59 -08:00
Ritchie Martori e92c46a4e4 Add password reset 2013-11-20 14:20:47 -08:00
Raymond Feng 344c74297c Add unauthenticated role 2013-11-20 13:43:02 -08:00
Raymond Feng bee8a3b022 Add checkAccess for subject and token 2013-11-20 13:43:01 -08:00
Raymond Feng 2c7c5fc7ec Start to support smart roles such as owner 2013-11-20 13:43:01 -08:00
Ritchie Martori da0545bed6 Initial auto wiring for model dataSources 2013-11-18 16:13:40 -08:00
Raymond Feng 44dfe34647 Allow ACLs for methods/relations 2013-11-15 10:08:49 -08:00
Raymond Feng 8381b05da1 Allows LDL level ACLs 2013-11-15 09:41:26 -08:00
Raymond Feng 8e679d0927 Fix the permission resolution 2013-11-14 21:19:57 -08:00
Raymond Feng cc7560b258 Simplify check permission 2013-11-14 21:19:57 -08:00
Raymond Feng 94f12d0fce Fix the permission check 2013-11-14 21:19:57 -08:00
Raymond Feng be3c40c3d3 Add oauth2 related models 2013-11-14 21:19:56 -08:00
Raymond Feng be32341467 Add a stub to register role resolvers 2013-11-14 21:19:56 -08:00
Raymond Feng 660ef89755 Merge ScopeACL into ACL 2013-11-14 21:19:56 -08:00
Raymond Feng 0430cd2ae3 Add tests for isInRole and getRoles 2013-11-14 21:19:56 -08:00
Raymond Feng c3a1a85159 Add constants and more tests 2013-11-14 21:19:56 -08:00
Raymond Feng 48a0242711 Define the models/relations for ACL 2013-11-14 21:19:56 -08:00
Raymond Feng 67b934357b Start to build the ACL models 2013-11-14 21:19:56 -08:00
Raymond Feng 492aca7724 Update acl/role models 2013-11-14 21:19:56 -08:00
Raymond Feng f9849454e9 Update ACL model 2013-11-14 21:19:09 -08:00
Ritchie Martori 1de2a40e88 Update AccessToken and User relationship
- Add created default
 - Default TTLs for user login access tokens
 - Break out User / AccessToken relationship
2013-11-14 19:41:29 -08:00
Ritchie Martori efce5039f6 Added AccessToken created property 2013-11-14 16:47:24 -08:00
Ritchie Martori 1bb95607b9 Update session / token documentation 2013-11-14 15:42:37 -08:00
Ritchie Martori 64d8ff986b Add loopback.token() middleware 2013-11-14 13:01:47 -08:00
Ritchie 77a137eca6 Rename Session => AccessToken 2013-11-14 10:05:13 -08:00
Ritchie Martori 77e842d2a3 Fix bundle model name casing 2013-11-11 13:35:54 -08:00