-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
Cannot specify passwordPolicy.validatorPattern or passwordPolicy.validatorCallback in a configuration file #3302
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
Comments
@dkarviga @bhaskaryasa, the author of the password policy feature can answer your questions if this feature is not working even after upgrading to 2.2.25 or greater. |
@dkarviga - The configuration requires these settings to be of exact types. Can you please post the code snippet where ParseServer is being initialised with these settings? |
@bhaskaryasa There is a way to initialize parse-server using JSON file. parse-server =path to config file= The example of config file
I cannot specify objects and functions via JSON file, so it seems this functionality cannot be used with standalone apps. All I need is to add min-length validation for the password. Currently, as a workaround, I use beforeSave trigger, but in this case, no error message is displayed in the Password Reset form when the user enters an incorrect password. |
It would be great if validatorPattern can be casted from string to RegExp, for example |
@dkarviga - I understand it now. Will look at adding this option. Thanks for the feedback. |
@bhaskaryasa, could you say, when we can expect this working? |
@apekelnik - hoping I can push this change by next release. not sure about the release schedule though. |
@bhaskaryasa , thanks. We will be waiting. |
Closing, as #3331 was just merged. Release is coming soon. |
@dkarviga @apekelnik |
@bhaskaryasa thanks. |
Issue Description
I am using the standalone version of parse-server. It seems there is no way to specify passwordPolicy.validatorPattern and passwordPolicy.validatorCallback options via JSON configuration file because these options require being RegExp instance or a function.
I get following errors when I try to specify them:
Is there a way to do it?
Environment Setup
The text was updated successfully, but these errors were encountered: