From 581d1a9ba70174bc63b03658d11ee95e4c8c4f41 Mon Sep 17 00:00:00 2001 From: Christophe Simonis Date: Thu, 29 Jan 2015 15:49:43 +0100 Subject: [PATCH] [FIX] base: ir_config_parameter increase database.secret entropy As this key is secret, does not leak half of it through `database.uuid` key (which is public) --- openerp/addons/base/ir/ir_config_parameter.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/openerp/addons/base/ir/ir_config_parameter.py b/openerp/addons/base/ir/ir_config_parameter.py index 95c1d0348e8..f02c30c8373 100644 --- a/openerp/addons/base/ir/ir_config_parameter.py +++ b/openerp/addons/base/ir/ir_config_parameter.py @@ -33,7 +33,7 @@ from openerp.tools import misc, config A dictionary holding some configuration parameters to be initialized when the database is created. """ _default_parameters = { - "database.secret": lambda: (str(uuid.uuid1()), ['base.group_erp_manager']), + "database.secret": lambda: (str(uuid.uuid4()), ['base.group_erp_manager']), "database.uuid": lambda: (str(uuid.uuid1()), []), "database.create_date": lambda: (datetime.datetime.now().strftime(misc.DEFAULT_SERVER_DATETIME_FORMAT), ['base.group_user']), "web.base.url": lambda: ("http://localhost:%s" % config.get('xmlrpc_port'), []),