FreeBSD/contrib/subversion/subversion/svnserve/serve.c
/* If CFG specifies a path to the password DB, read that DB through
 * CONFIG_POOL and store it in REPOSITORY->PWDB.
 */
If CFG specifies a path to the password DB, read that DB through
CONFIG_POOL and store it in REPOSITORY->PWDB.
If CFG specifies a path to the password DB read that DB through CONFIG_POOL and store it in REPOSITORY - > PWDB .
static svn_error_t *
load_pwdb_config(repository_t *repository,
                 svn_config_t *cfg,
                 svn_repos__config_pool_t *config_pool,
                 apr_pool_t *pool)
{
  const char *pwdb_path;
  svn_error_t *err;
  svn_config_get(cfg, &pwdb_path,
                 SVN_CONFIG_SECTION_GENERAL,
                 SVN_CONFIG_OPTION_PASSWORD_DB, NULL);
  repository->pwdb = NULL;
  if (pwdb_path)
    {
      pwdb_path = svn_dirent_internal_style(pwdb_path, pool);
      pwdb_path = svn_dirent_join(repository->base, pwdb_path, pool);
      err = svn_repos__config_pool_get(&repository->pwdb, NULL, config_pool,
                                       pwdb_path, TRUE, FALSE,
                                       repository->repos, pool);
      if (err)
        {
          if (err->apr_err != SVN_ERR_BAD_FILENAME
              && ! APR_STATUS_IS_EACCES(err->apr_err))
            {
              return svn_error_create(SVN_ERR_AUTHN_FAILED, err, NULL);
            }
          else
            svn_error_clear(err);
        }
    }
  return SVN_NO_ERROR;
}
static svn_error_t * load_pwdb_config ( repository_t * repository , svn_config_t * cfg , svn_repos__config_pool_t * config_pool , apr_pool_t * pool ) { const char * pwdb_path ; svn_error_t * err ; svn_config_get ( cfg , & pwdb_path , SVN_CONFIG_SECTION_GENERAL , SVN_CONFIG_OPTION_PASSWORD_DB , NULL ) ; repository -> pwdb = NULL ; if ( pwdb_path ) { pwdb_path = svn_dirent_internal_style ( pwdb_path , pool ) ; pwdb_path = svn_dirent_join ( repository -> base , pwdb_path , pool ) ; err = svn_repos__config_pool_get ( & repository -> pwdb , NULL , config_pool , pwdb_path , TRUE , FALSE , repository -> repos , pool ) ; if ( err ) { if ( err -> apr_err != SVN_ERR_BAD_FILENAME && ! APR_STATUS_IS_EACCES ( err -> apr_err ) ) { return svn_error_create ( SVN_ERR_AUTHN_FAILED , err , NULL ) ; } else svn_error_clear ( err ) ; } } return SVN_NO_ERROR ; }
If CFG specifies a path to the password DB, read that DB through
 CONFIG_POOL and store it in REPOSITORY->PWDB.
If CFG specifies a path to the password DB read that DB through CONFIG_POOL and store it in REPOSITORY - > PWDB .
/* Because it may be possible to read the pwdb file with some
             access methods and not others, ignore errors reading the pwdb
             file and just don't present password authentication as an
             option.  Also, some authentications (e.g. --tunnel) can
             proceed without it anyway.

             ### Not entirely sure why SVN_ERR_BAD_FILENAME is checked
             ### for here.  That seems to have been introduced in r856914,
             ### and only in r870942 was the APR_EACCES check introduced. */ /* Ignore SVN_ERR_BAD_FILENAME and APR_EACCES and proceed. */