From 198aea9faca3560a9a87e507179c9ad0ba5f6330 Mon Sep 17 00:00:00 2001 From: Eric Burel Date: Tue, 30 Nov 2021 13:50:21 +0100 Subject: [PATCH] Update README.md --- README.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 40c69ba..368ab7d 100644 --- a/README.md +++ b/README.md @@ -87,10 +87,13 @@ To update password: - You need to split this value like this: 22 characters after the 3rd $ is the `salt`. The rest is the `hash`. You can ignore the beginning. Example: `$2b$10$abcdefghijklmnopqrstuvWXYZ123456789` => `salt` is `abcdefghijklmnopqrstuv` and `hash` is `WXYZ12345678` - Store the `hash` in `hash` and `salt` in `salt` in the user document. + + If it doesn't work, simply alter Vulcan Next password check method so it fall back to `services.password.bcrypt` to find the hashed password, see https://willvincent.com/2018/08/09/replicating-meteors-password-hashing-implementation/ - You can use both Next's GraphQL API and Meteor's GraphQL API using the [Connect to multiple graphql API in the frontend pattern described here](https://github.com/VulcanJS/vulcan-next/blob/demo/with-meteor-backend/src/content/docs/recipes.md) -- TODO: See https://github.com/VulcanJS/vulcan-npm/issues/63. Meteor uses string `_id` as a default, while Mongo uses `ObjectId` type, so you need to do `ObjectId.str` to get the actual id or use a method like `isEqual` from lodash. **This means that objects created using Next backend might create bugs in the Meteor backend**. You need to avoid that, by doing creation operations only in Meteor, or to clearly separate things you manage in Next and things you manage in Meteor until you have fully transitionned. +- TODO: See https://github.com/VulcanJS/vulcan-npm/issues/63. +Meteor uses string `_id` as a default, while Mongo uses `ObjectId` type, so you need to do `ObjectId.str` to get the actual id or use a method like `isEqual` from lodash. **This means that objects created using Next backend might create bugs in the Meteor backend**. You need to avoid that, by doing creation operations only in Meteor, or to clearly separate things you manage in Next and things you manage in Meteor until you have fully transitionned. - If you plan to reuse your existing Meteor database in Next, this means you might need to parse all documents and change the "string" `_id` to an `ObjectId`, see https://forums.meteor.com/t/convert-meteor-mongo-string--id-into-objectid/19782. You can change the `_id` generation scheme (see https://docs.meteor.com/api/collections.html) to ObjectId in the Meteor app if you need a progressive transition. @@ -98,7 +101,6 @@ TODO: We still have an issue with `function convertIdAndTransformToJSON` **Current workaround:**: clone users mnually in Compass, it will recreate an id as an ObjectID https://docs.mongodb.com/compass/current/documents/clone/ -If you reuse your Mongo database within Vulcan Meteor, you might ## Caveats - Check Vulcan NPM migration documentation to see the difference between Vulcan Meteor and Vulcan Next: https://github.com/VulcanJS/vulcan-npm/blob/devel/MIGRATING.md