RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1670460 - fence_rhevm is limited to ASCII content only, throwing stack-trace on UTF-8 characters
Summary: fence_rhevm is limited to ASCII content only, throwing stack-trace on UTF-8 c...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: fence-agents
Version: 7.6
Hardware: x86_64
OS: Linux
unspecified
medium
Target Milestone: rc
: ---
Assignee: Oyvind Albrigtsen
QA Contact: cluster-qe@redhat.com
URL:
Whiteboard:
Depends On:
Blocks: 1712263 1716704
TreeView+ depends on / blocked
 
Reported: 2019-01-29 15:10 UTC by Andreas Bleischwitz
Modified: 2019-08-06 12:35 UTC (History)
8 users (show)

Fixed In Version: fence-agents-4.2.1-21.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1712263 (view as bug list)
Environment:
Last Closed: 2019-08-06 12:34:23 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Knowledge Base (Solution) 3869731 0 None None None 2019-01-29 15:15:31 UTC
Red Hat Product Errata RHSA-2019:2037 0 None None None 2019-08-06 12:35:15 UTC

Description Andreas Bleischwitz 2019-01-29 15:10:29 UTC
Description of problem:
When using "fence_rhevm" for fencing of virtual machines in RHV, neither the "Comment", nor the "Description" field of said vm must contain non ASCII-characters

Version-Release number of selected component (if applicable):
fence-agents-rhevm-4.2.1-11.el7_6.1.x86_64

How reproducible:
Always

Steps to Reproduce:
1. Create VM "test" in RHV, Comment = "ÄÖÜ"
2. Invoke fence_rhevm -o status ... test
3.

Actual results:
Stack-trace:
Traceback (most recent call last):
  File "/usr/sbin/fence_rhevm_old", line 200, in <module>
    main()
  File "/usr/sbin/fence_rhevm_old", line 195, in main
    result = fence_action(None, options, set_power_status, get_power_status, get_list)
  File "/usr/share/fence/fencing.py", line 884, in fence_action
    status = get_multi_power_fn(connection, options, get_power_fn)
  File "/usr/share/fence/fencing.py", line 752, in get_multi_power_fn
    plug_status = get_power_fn(connection, options)
  File "/usr/sbin/fence_rhevm_old", line 19, in get_power_status
    res = send_command(options, "vms/?search=name%3D" + options["--plug"])
  File "/usr/sbin/fence_rhevm_old", line 131, in send_command
    result = web_buffer.getvalue().decode()
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 2459: ordinal not in range(128)


Expected results:
Status: ON|OFF

Additional info:

Comment 2 Andreas Bleischwitz 2019-01-29 15:15:32 UTC
There is a pull request which at least solves the status issue, there still seem to be an issue when using "-v" and non ASCII-characters:

# fence_rhevm -o status -v --ssl --ssl-insecure -a <rhev-ip> --username <user@domain> --password=<password> --disable-http-filter --ipport 443 -n <vm-name>

2019-01-29 16:08:15,198 DEBUG: vms/?search=name%3Dtest

Traceback (most recent call last):
  File "/usr/sbin/fence_rhevm", line 202, in <module>
    main()
  File "/usr/sbin/fence_rhevm", line 197, in main
    result = fence_action(None, options, set_power_status, get_power_status, get_list)
  File "/usr/share/fence/fencing.py", line 884, in fence_action
    status = get_multi_power_fn(connection, options, get_power_fn)
  File "/usr/share/fence/fencing.py", line 752, in get_multi_power_fn
    plug_status = get_power_fn(connection, options)
  File "/usr/sbin/fence_rhevm", line 19, in get_power_status
    res = send_command(options, "vms/?search=name%3D" + options["--plug"])
  File "/usr/sbin/fence_rhevm", line 136, in send_command
    logging.debug("%s\n", result)
  File "/usr/lib64/python2.7/logging/__init__.py", line 1619, in debug
    root.debug(msg, *args, **kwargs)
  File "/usr/lib64/python2.7/logging/__init__.py", line 1137, in debug
    self._log(DEBUG, msg, args, **kwargs)
  File "/usr/lib64/python2.7/logging/__init__.py", line 1268, in _log
    self.handle(record)
  File "/usr/lib64/python2.7/logging/__init__.py", line 1278, in handle
    self.callHandlers(record)
  File "/usr/lib64/python2.7/logging/__init__.py", line 1318, in callHandlers
    hdlr.handle(record)
  File "/usr/lib64/python2.7/logging/__init__.py", line 749, in handle
    self.emit(record)
  File "/usr/share/fence/fencing.py", line 1074, in emit
    syslog.syslog(syslog_level, msg.replace("\x00", "\n"))
TypeError: [priority,] message string

Comment 3 Sandro 2019-01-30 08:57:47 UTC
Info: PR got merged

Comment 5 Sandro 2019-02-13 12:40:57 UTC
Is there a plan when this will get packaged and shipped to the rhn channels ?

Comment 6 Chris Feist 2019-02-13 20:50:54 UTC
Sandro,

Unfortunately we don't have an exact date as to when this will be available in Red Hat, however, if you contact your Red Hat support team they can escalate the request and help us to prioritize to get this fix out sooner.

Thanks,
Chris

Comment 21 Doran Moppert 2019-06-04 01:07:37 UTC
This issue was assigned CVE-2019-10153:  bug 1716286.

Comment 23 errata-xmlrpc 2019-08-06 12:34:23 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2019:2037


Note You need to log in before you can comment on or make changes to this bug.