0001-cwd-db_config.patch 686 B

123456789101112131415161718192021
  1. Do not access DB_CONFIG when db_home is not set
  2. Fixes CVE-2017-10140:
  3. https://bugzilla.redhat.com/show_bug.cgi?id=1464032#c9
  4. Downloaded from
  5. http://pkgs.fedoraproject.org/cgit/rpms/libdb.git/commit/?id=8047fa8580659fcae740c25e91b490539b8453eb
  6. Signed-off-by: Bernd Kuhls <bernd.kuhls@t-online.de>
  7. --- db-5.3.28/src/env/env_open.c.old 2017-06-26 10:32:11.011419981 +0200
  8. +++ db-5.3.28/src/env/env_open.c 2017-06-26 10:32:46.893721233 +0200
  9. @@ -473,7 +473,7 @@
  10. env->db_mode = mode == 0 ? DB_MODE_660 : mode;
  11. /* Read the DB_CONFIG file. */
  12. - if ((ret = __env_read_db_config(env)) != 0)
  13. + if (env->db_home != NULL && (ret = __env_read_db_config(env)) != 0)
  14. return (ret);
  15. /*