Skip to content

[IDA Plugin] UnicodeEncodeError + edited config should be validated #109

@DarkaMaul

Description

@DarkaMaul

Hello,

When launching an analysis/saving a config on a file which path contains non-ascii characters, the plugin crash with the following stacktrace:

Traceback (most recent call last):
  File "[...]/idabincat/gui.py", line 798, in launch_analysis
    self._save_config("(last used)")
  File "[...]/idabincat/gui.py", line 937, in _save_config
    self.s.configurations[config_name] = self.s.edit_config
  File "[...]/idabincat/analyzer_conf.py", line 882, in wrap
    f(self, *args, **kwargs)
  File "[...]/idabincat/analyzer_conf.py", line 929, in __setitem__
    self._configs[name] = str(config)
  File "[...]/idabincat/analyzer_conf.py", line 691, in __str__
    self._config.write(sio)
  File "/usr/lib/python2.7/ConfigParser.py", line 412, in write
    key = " = ".join((key, str(value).replace('\n', '\n\t')))
UnicodeEncodeError: 'ascii' codec can't encode character u'\xe9' in position 15: ordinal not in range(128)

Steps to reproduce

  1. Launch IDA with a file in a directory with non ascii characters (e.g ~/Téléchargements/prog)
  2. Launch BinCat plugin
  3. Go to configuration panel and try to save the config

Using last stable version of the plugin (1.1)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions