Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Difference Setting ACL js(parse.com) and android(hosted). #1390

Closed
2 of 3 tasks
ghost opened this issue Apr 6, 2016 · 7 comments · Fixed by #1429
Closed
2 of 3 tasks

Difference Setting ACL js(parse.com) and android(hosted). #1390

ghost opened this issue Apr 6, 2016 · 7 comments · Fixed by #1429
Labels
type:bug Impaired feature or lacking behavior that is likely assumed

Comments

@ghost
Copy link

ghost commented Apr 6, 2016

Check out this issue for an ideal bug report. The closer your issue report is to that one, the more likely we are to be able to help, and the more likely we will be to fix the issue quickly!

For implementation related questions or technical support, please refer to the Stack Overflow and Server Fault communities.

Make sure these boxes are checked before submitting your issue -- thanks for reporting issues back to Parse Server!

Description

When I creating new user, I setting acl control. JS(from Parse.com api) side is okay, but Android side (from azure server side) is strange.

  • use parse.com for testing somtime.

Environment Setup

  • Microsoft Azure
    • Parse Server 2.2.6 (Webapp)
      • Azure Storage File Adapter
      • Forked 'parse-server-example', Customized.
    • MongoDB 3.0.10 (MS Azure VM - Cent OS 6.7)
  • Android Build Version 6.0.1, 5.1.x (with Android Studio)
  • Google Chrome Browser (49.0.2623.110 (64-bit))
  • Mac OS X El Capitain

Steps to reproduce

  • Android side
.....  
ParseACL acl = new ParseACL();
acl.setPublicReadAccess(false);
acl.setPublicWriteAccess(false);
user.setACL(acl);
user.signUp();

.....  
  • JS Side (from parse.com)
....
var acl = new Parse.ACL();
acl.setPublicReadAccess(false);
acl.setPublicWriteAccess(false);
user.setACL(acl);
user.save(); // or user.signUp();
....
Result :
  • Android
    acl column, master key only
  • JS (from parse.com)
    acl column, { user_object_id }
Expected :
  • same results. / parse.com or stand-alone

Logs/Trace

  • none

Please tell me what I missing. Thanks.

@ghost ghost changed the title Difference Setting ACL js and android. Difference Setting ACL js(parse.com) and android. Apr 6, 2016
@ghost ghost changed the title Difference Setting ACL js(parse.com) and android. Difference Setting ACL js(parse.com) and android(stand-alone). Apr 6, 2016
@ghost
Copy link
Author

ghost commented Apr 6, 2016

some screen shots are here : [LINK]

@ghost ghost changed the title Difference Setting ACL js(parse.com) and android(stand-alone). Difference Setting ACL js(parse.com) and android(hosted). Apr 6, 2016
@flovilmart
Copy link
Contributor

so the bug basically is locking the user out.

@flovilmart flovilmart added the type:bug Impaired feature or lacking behavior that is likely assumed label Apr 6, 2016
@ghost
Copy link
Author

ghost commented Apr 7, 2016

How long take for this?
+
I resolved temporary with cloud code.

Parse/User/afterSave
....

    var user = request.object;

    var acl = new Parse.ACL();
    acl.setPublicReadAccess(false);
    acl.setPublicWriteAccess(false);
    acl.setReadAccess(user, true);
    acl.setWriteAccess(user, true);
    user.setACL(acl);

    user.save(null, { useMasterKey: true })
....

@flovilmart
Copy link
Contributor

PRs are welcome, as you can see by the number of issues listed and the number of commits we merge every day, we do our best to accommodate everyone here.

@ghost
Copy link
Author

ghost commented Apr 8, 2016

Okay. I hope fix this soon. Thx reply. :D

@flovilmart
Copy link
Contributor

Quick question, in your case the ACL on the userId is read / write

@ghost
Copy link
Author

ghost commented Jun 2, 2016

2016-06-02 12 46 25

![2016-06-02 12 52 19](https://cloud.githubusercontent.com/assets/4546119/15733464/19e295d8-28c1-11e6-9af6-6fbaf9ac85b2.png)

I updated parse server to 2.2.10, but not changed yet. What should I do?

here are my codes and result.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Impaired feature or lacking behavior that is likely assumed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant