-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
Fix error 206 for new Facebook user when verifyUserEmails is true #8352
Conversation
# [5.4.0-alpha.1](5.3.0...5.4.0-alpha.1) (2022-10-31) ### Bug Fixes * authentication adapter app ID validation may be circumvented; this fixes a vulnerability that affects configurations which allow users to authenticate using the Parse Server authentication adapter for *Facebook* or *Spotify* and where the server-side authentication adapter configuration `appIds` is set as a string (e.g. `abc`) instead of an array of strings (e.g. `["abc"]`) ([GHSA-r657-33vp-gp22](GHSA-r657-33vp-gp22)) [skip release] ([#8187](#8187)) ([8c8ec71](8c8ec71)) * brute force guessing of user sensitive data via search patterns (GHSA-2m6g-crv8-p3c6) ([#8146](#8146)) [skip release] ([4c0c7c7](4c0c7c7)) * certificate in Apple Game Center auth adapter not validated [skip release] ([#8058](#8058)) ([75af9a2](75af9a2)) * graphQL query ignores condition `equalTo` with value `false` ([#8032](#8032)) ([7f5a15d](7f5a15d)) * internal indices for classes `_Idempotency` and `_Role` are not protected in defined schema ([#8121](#8121)) ([c16f529](c16f529)) * invalid file request not properly handled [skip release] ([#8062](#8062)) ([4c9e956](4c9e956)) * liveQuery with `containedIn` not working when object field is an array ([#8128](#8128)) ([1d9605b](1d9605b)) * protected fields exposed via LiveQuery (GHSA-crrq-vr9j-fxxh) [skip release] ([#8076](#8076)) ([9fd4516](9fd4516)) * push notifications `badge` doesn't update with Installation beforeSave trigger ([#8162](#8162)) ([3c75c2b](3c75c2b)) * query aggregation pipeline cannot handle value of type `Date` when `directAccess: true` ([#8167](#8167)) ([e424137](e424137)) * relation constraints in compound queries `Parse.Query.or`, `Parse.Query.and` not working ([#8203](#8203)) ([28f0d26](28f0d26)) * security upgrade undici from 5.6.0 to 5.8.0 ([#8108](#8108)) ([4aa016b](4aa016b)) * server crashes when receiving file download request with invalid byte range; this fixes a security vulnerability that allows an attacker to impact the availability of the server instance; the fix improves parsing of the range parameter to properly handle invalid range requests ([GHSA-h423-w6qv-2wj3](GHSA-h423-w6qv-2wj3)) [skip release] ([#8238](#8238)) ([c03908f](c03908f)) * session object properties can be updated by foreign user; this fixes a security vulnerability in which a foreign user can write to the session object of another user if the session object ID is known; the fix prevents writing to foreign session objects ([GHSA-6w4q-23cf-j9jp](GHSA-6w4q-23cf-j9jp)) [skip release] ([#8180](#8180)) ([37fed30](37fed30)) * sorting by non-existing value throws `INVALID_SERVER_ERROR` on Postgres ([#8157](#8157)) ([3b775a1](3b775a1)) * updating object includes unchanged keys in client response for certain key types ([#8159](#8159)) ([37af1d7](37af1d7)) ### Features * add convenience access to Parse Server configuration in Cloud Code via `Parse.Server` ([#8244](#8244)) ([9f11115](9f11115)) * add option to change the default value of the `Parse.Query.limit()` constraint ([#8152](#8152)) ([0388956](0388956)) * add support for MongoDB 6 ([#8242](#8242)) ([aba0081](aba0081)) * add support for Postgres 15 ([#8215](#8215)) ([2feb6c4](2feb6c4)) * liveQuery support for unsorted distance queries ([#8221](#8221)) ([0f763da](0f763da))
…type pollution; fixes security vulnerability [GHSA-prm5-8g2m-24gg](GHSA-prm5-8g2m-24gg) (#8297)
…d via Cloud Code Webhooks or Triggers; fixes security vulnerability [GHSA-xprv-wvh7-qqqx](GHSA-xprv-wvh7-qqqx) (#8304)
BREAKING CHANGE: This release removes Node 12 and Node 17 support
…r authentication (MFA), authentication challenges, and provide a more powerful interface for writing custom authentication adapters (#8156)
# [6.0.0-alpha.2](6.0.0-alpha.1...6.0.0-alpha.2) (2022-11-10) ### Features * Improve authentication adapter interface to support multi-factor authentication (MFA), authentication challenges, and provide a more powerful interface for writing custom authentication adapters ([#8156](#8156)) ([5bbf9ca](5bbf9ca))
… request `Parse.Cloud.httpRequest` (#8287) BREAKING CHANGE: The convenience method for HTTP requests `Parse.Cloud.httpRequest` is removed; use your preferred 3rd party library for making HTTP requests
# [6.0.0-alpha.3](6.0.0-alpha.2...6.0.0-alpha.3) (2022-11-10) ### Features * Remove deprecation `DEPPS4`: Remove convenience method for http request `Parse.Cloud.httpRequest` ([#8287](#8287)) ([2d79c08](2d79c08)) ### BREAKING CHANGES * The convenience method for HTTP requests `Parse.Cloud.httpRequest` is removed; use your preferred 3rd party library for making HTTP requests ([2d79c08](2d79c08))
…lts to true (#8284) BREAKING CHANGE: Config option `directAccess` defaults to true; set this to `false` in environments where multiple Parse Server instances run behind a load balancer and Parse requests within the current Node.js environment should be routed via the load balancer and distributed as HTTP requests among all instances via the `serverURL`.
# [6.0.0-alpha.4](6.0.0-alpha.3...6.0.0-alpha.4) (2022-11-10) ### Features * Remove deprecation `DEPPS2`: Config option `directAccess` defaults to true ([#8284](#8284)) ([f535ee6](f535ee6)) ### BREAKING CHANGES * Config option `directAccess` defaults to true; set this to `false` in environments where multiple Parse Server instances run behind a load balancer and Parse requests within the current Node.js environment should be routed via the load balancer and distributed as HTTP requests among all instances via the `serverURL`. ([f535ee6](f535ee6))
…` crashes server (#8280) BREAKING CHANGE: Throwing an error in Cloud Code Triggers `afterLogin`, `afterLogout` returns a rejected promise; in previous releases it crashed the server if you did not handle the error on the Node.js process level; consider adapting your code if your app currently handles these errors on the Node.js process level with `process.on('unhandledRejection', ...)`
# [6.0.0-alpha.5](6.0.0-alpha.4...6.0.0-alpha.5) (2022-11-10) ### Bug Fixes * Throwing error in Cloud Code Triggers `afterLogin`, `afterLogout` crashes server ([#8280](#8280)) ([130d290](130d290)) ### BREAKING CHANGES * Throwing an error in Cloud Code Triggers `afterLogin`, `afterLogout` returns a rejected promise; in previous releases it crashed the server if you did not handle the error on the Node.js process level; consider adapting your code if your app currently handles these errors on the Node.js process level with `process.on('unhandledRejection', ...)` ([130d290](130d290))
BREAKING CHANGE: This release removes support for MongoDB 4.0; the new minimum supported MongoDB version is 4.2. which also removes support for the deprecated MongoDB MMAPv1 storage engine
# [6.0.0-alpha.6](6.0.0-alpha.5...6.0.0-alpha.6) (2022-11-10) ### Features * Remove support for MongoDB 4.0 ([#8292](#8292)) ([37245f6](37245f6)) ### BREAKING CHANGES * This release removes support for MongoDB 4.0; the new minimum supported MongoDB version is 4.2. which also removes support for the deprecated MongoDB MMAPv1 storage engine ([37245f6](37245f6))
BREAKING CHANGE: This release upgrades to Redis 4; if you are using the Redis cache adapter with Parse Server then this is a breaking change as the Redis client options have changed; see the [Redis migration guide](https://github.com/redis/node-redis/blob/redis%404.0.0/docs/v3-to-v4.md) for more details (#8293)
# [6.0.0-alpha.7](6.0.0-alpha.6...6.0.0-alpha.7) (2022-11-11) ### Features * Upgrade Redis 3 to 4 ([#8293](#8293)) ([7d622f0](7d622f0)) ### BREAKING CHANGES * This release upgrades to Redis 4; if you are using the Redis cache adapter with Parse Server then this is a breaking change as the Redis client options have changed; see the [Redis migration guide](https://github.com/redis/node-redis/blob/redis%404.0.0/docs/v3-to-v4.md) for more details (#8293) ([7d622f0](7d622f0))
BREAKING CHANGE: This release restricts the use of `masterKey` to localhost by default; if you are using Parse Dashboard on a different server to connect to Parse Server you need to add the IP address of the server that hosts Parse Dashboard to this option (#8281)
# [6.0.0-alpha.8](6.0.0-alpha.7...6.0.0-alpha.8) (2022-11-11) ### Features * Restrict use of `masterKey` to localhost by default ([#8281](#8281)) ([6c16021](6c16021)) ### BREAKING CHANGES * This release restricts the use of `masterKey` to localhost by default; if you are using Parse Dashboard on a different server to connect to Parse Server you need to add the IP address of the server that hosts Parse Dashboard to this option (#8281) ([6c16021](6c16021))
# [6.0.0-alpha.9](6.0.0-alpha.8...6.0.0-alpha.9) (2022-11-16) ### Features * Remove deprecation `DEPPS3`: Config option `enforcePrivateUsers` defaults to `true` ([#8283](#8283)) ([ed499e3](ed499e3)) ### BREAKING CHANGES * The Parse Server option `enforcePrivateUsers` is set to `true` by default; in previous releases this option defaults to `false`; this change improves the default security configuration of Parse Server (#8283) ([ed499e3](ed499e3))
# [6.0.0-alpha.10](6.0.0-alpha.9...6.0.0-alpha.10) (2022-11-19) ### Bug Fixes * Cloud Code trigger `beforeSave` does not work with `Parse.Role` ([#8320](#8320)) ([f29d972](f29d972))
… default for IPv6 (#8322)
# [6.0.0-alpha.11](6.0.0-alpha.10...6.0.0-alpha.11) (2022-11-25) ### Bug Fixes * Parse Server option `masterKeyIps` does not include localhost by default for IPv6 ([#8322](#8322)) ([ab82635](ab82635))
# [6.0.0-alpha.12](6.0.0-alpha.11...6.0.0-alpha.12) (2022-11-26) ### Features * Upgrade Redis 3 to 4 for LiveQuery ([#8333](#8333)) ([b2761fb](b2761fb))
# [6.0.0-alpha.13](6.0.0-alpha.12...6.0.0-alpha.13) (2022-12-07) ### Features * Add option to change the log level of the logs emitted by triggers ([#8328](#8328)) ([8f3b694](8f3b694))
…side of `masterKeyIps` (#8350)
# [6.0.0-alpha.14](6.0.0-alpha.13...6.0.0-alpha.14) (2022-12-16) ### Features * Write log entry when request with master key is rejected as outside of `masterKeyIps` ([#8350](#8350)) ([e22b73d](e22b73d))
The branch Pull requests are usually opened against the default branch |
Thanks for opening this pull request!
|
Codecov ReportBase: 94.12% // Head: 94.24% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## release #8352 +/- ##
===========================================
+ Coverage 94.12% 94.24% +0.11%
===========================================
Files 182 180 -2
Lines 13775 13987 +212
===========================================
+ Hits 12966 13182 +216
+ Misses 809 805 -4
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. |
New Pull Request Checklist
Issue Description
When verifyUserEmails is true, if a new Facebook user tries to login then gets error 206 wherein PFUser project fails to get saved.
Closes: #6511
Approach
In current implementation of
RestWrite.prototype.handleAuthData
, storage['authProvider'] is not set when user with authData does not exist.storage['authProvider']
needs to be set before evaluating whether users withauthData
exists or not.TODOs before merging