Browse Source

[SEC] fetchmail_attach_from_folder: fix unsafe eval

pull/363/head
Alexandre Fayolle 8 years ago
parent
commit
ab77974d8c
  1. 2
      fetchmail_attach_from_folder/__openerp__.py
  2. 2
      fetchmail_attach_from_folder/model/fetchmail_server.py

2
fetchmail_attach_from_folder/__openerp__.py

@ -23,7 +23,7 @@
{
'name': 'Email gateway - folders',
'summary': 'Attach mails in an IMAP folder to existing objects',
'version': '8.0.1.0.0',
'version': '8.0.1.0.1',
'author': "Therp BV,Odoo Community Association (OCA)",
'website': 'http://www.therp.nl',
'license': 'AGPL-3',

2
fetchmail_attach_from_folder/model/fetchmail_server.py

@ -264,7 +264,7 @@ class fetchmail_server(models.Model):
if field.tag == 'field' and field.get('name') in modifiers:
field.set('modifiers', simplejson.dumps(
dict(
eval(field.attrib['modifiers'],
safe_eval(field.attrib['modifiers'],
UnquoteEvalContext({})),
**modifiers[field.attrib['name']])))
if (field.tag == 'field' and

Loading…
Cancel
Save