Skip to content

refactor: Deprecate enableAnonymousUsers #7924

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

Open
wants to merge 3 commits into
base: alpha
Choose a base branch
from

Conversation

dblythy
Copy link
Member

@dblythy dblythy commented Apr 5, 2022

New Pull Request Checklist

Issue Description

enableAnonymousUsers should default to false.

Related issue: #7923

Approach

Adds planned depreciation

TODOs before merging

  • A changelog entry is created automatically using the pull request title (do not manually add a changelog entry)

@parse-github-assistant
Copy link

parse-github-assistant bot commented Apr 5, 2022

Thanks for opening this pull request!

  • ❌ Please link an issue that describes the reason for this pull request, otherwise your pull request will be closed. Make sure to write it as Closes: #123 in the PR description, so I can recognize it.

@codecov
Copy link

codecov bot commented Apr 5, 2022

Codecov Report

Base: 94.11% // Head: 94.11% // Increases project coverage by +0.00% 🎉

Coverage data is based on head (6d6acb2) compared to base (b10182f).
Patch coverage: 100.00% of modified lines in pull request are covered.

Additional details and impacted files
@@           Coverage Diff           @@
##            alpha    #7924   +/-   ##
=======================================
  Coverage   94.11%   94.11%           
=======================================
  Files         182      182           
  Lines       13621    13623    +2     
=======================================
+ Hits        12819    12821    +2     
  Misses        802      802           
Impacted Files Coverage Δ
src/Security/CheckGroups/CheckGroupServerConfig.js 96.00% <100.00%> (+0.34%) ⬆️
src/RestWrite.js 94.30% <0.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@mtrezza mtrezza force-pushed the alpha branch 2 times, most recently from 59215e6 to e6d7d8f Compare May 1, 2022 02:29
@dblythy dblythy force-pushed the depreciate-client-class-creation branch from c368a05 to 5ac3bf2 Compare May 16, 2022 00:48
@dblythy dblythy requested a review from a team May 16, 2022 00:50
Copy link
Contributor

@rhuanbarreto rhuanbarreto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great security improvement!

@@ -72,6 +72,16 @@ class CheckGroupServerConfig extends CheckGroup {
}
},
}),
new Check({
title: 'Anonymous Users disabled',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Curious about your thought process for adding a security warning.

I'm thinking that if someone has an application in which anonymous users are part of their use case, they will always get this warning, even though they may have restricted the permissions of anonymous users accordingly. After all, anonymous users is a regular feature of Parse Server:

Being able to associate data and objects with individual users is highly valuable, but sometimes you want to be able to do this without forcing a user to specify a username and password.

An anonymous user is a user that can be created without a username and password but still has all of the same capabilities as any other PFUser. After logging out, an anonymous user is abandoned, and its data is no longer accessible.

I understand that we disable them by default, as enabling them requires taking security implications into account, but I'm not sure it should be a permanent warning. What do you think?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reading this again, maybe it actually makes sense to add that warning until we change the default in 2024, that's still a long time away. Once the deprecation ended, we could remove the warning.

To my previous comment, I think one should always be able to get down to 0 warnings by improving the configuration. Since anonymous user is a regular feature, any app that uses this would never be able to get to 0 warnings, always indicating that there was a potential security issue, which there is not if classes are properly secured. Or the warning could have additional conditions, e.g. anonymous users enabled + file upload enabled for anonymous user = real vulnerability that warrants a warning.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dblythy what do you think?

@mtrezza mtrezza changed the title fix: depreciate enableAnonymousUsers refactor: deprecate enableAnonymousUsers Jun 17, 2022
@dblythy dblythy closed this Dec 15, 2022
@dblythy dblythy reopened this Dec 20, 2022
@parse-github-assistant
Copy link

I will reformat the title to use the proper commit message syntax.

@parse-github-assistant parse-github-assistant bot changed the title refactor: deprecate enableAnonymousUsers refactor: Deprecate enableAnonymousUsers Dec 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants