rnewson commented on PR #4814: URL: https://github.com/apache/couchdb/pull/4814#issuecomment-1790795555
sorry, I've modified this yet again. Notably I increase the default iterations to 50,000. I override this in a test to avoid adding a timer:sleep hack. I changed needs_upgrade to _not_ have defaults for password_scheme or iterations. Instead I use couch_util:get_value/2 and so we get `undefined` if these items are missing. If either are missing the function will return true and we'll then do the upgrade. Any document without these fields is broken and needs fixing (a user/admin that removed them by accident is the only path). I much prefer this to yet another place with a `sha` or `10` default. It is quite _wrong_ to put defaults there anyway. The default for scheme, prf, iterations only apply when _creating_ new password hashes. Existing hashes must have their actual parameters supplied (as fields for user docs and packed into the config value for admins). -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
