2 Replies Latest reply on May 6, 2012 9:49 AM by romk55

    Encoding Error with psql


      I am just setting up my Metasploit, but i have a problem with the db_connect and psql.
      It sounds like following:

      msf > db_connect postgres:Test12345@

      [-] Error while running command db_connect: Failed to connect to the database: PGError: ERROR:  invalid byte sequence for encoding "UTF8": 0xc3c3

      HINT:  This error can also happen if the byte sequence does not match the encoding expected by the server, which is controlled by "client_encoding".

      : CREATE DATABASE "metasp´┐Ż´┐Żloit" ENCODING = 'utf8'


      Call stack:

      /opt/metasploit/msf3/lib/msf/ui/console/command_dispatcher/db.rb:1422:in `db_connect_postgresql'

      /opt/metasploit/msf3/lib/msf/ui/console/command_dispatcher/db.rb:1286:in `cmd_db_connect'

      /opt/metasploit/msf3/lib/rex/ui/text/dispatcher_shell.rb:380:in `run_command'

      /opt/metasploit/msf3/lib/rex/ui/text/dispatcher_shell.rb:342:in `block in run_single'

      /opt/metasploit/msf3/lib/rex/ui/text/dispatcher_shell.rb:336:in `each'

      /opt/metasploit/msf3/lib/rex/ui/text/dispatcher_shell.rb:336:in `run_single'

      /opt/metasploit/msf3/lib/rex/ui/text/shell.rb:199:in `run'

      /opt/metasploit/msf3/msfconsole:134:in `<main>'

      msf >


      Does someone know how to change encoding with "client_encoding" ?Thank you