WALinuxAgentShim fails to handle escaped characters in dhclient.eth0.leases

Bug #1488891 reported by Dan Watkins on 2015-08-26
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
cloud-init
Medium
Dan Watkins

Bug Description

For example, a line of

  option unknown-245 "dH\"l";

in dhclient.eth0.leases should yield an IP address of 100.72.34.108 but instead causes an exception:

Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/cloudinit/sources/DataSourceAzure.py", line 249, in get_data
    fabric_data = metadata_func()
  File "/usr/lib/python3/dist-packages/cloudinit/sources/helpers/azure.py", line 289, in get_metadata_from_fabric
    shim = WALinuxAgentShim()
  File "/usr/lib/python3/dist-packages/cloudinit/sources/helpers/azure.py", line 210, in __init__
    self.endpoint = self.find_endpoint()
  File "/usr/lib/python3/dist-packages/cloudinit/sources/helpers/azure.py", line 237, in find_endpoint
    endpoint_ip_address = socket.inet_ntoa(value)
OSError: packed IP wrong length for inet_ntoa

Related branches

Changed in cloud-init:
assignee: nobody → Dan Watkins (daniel-thewatkins)
summary: - WALinuxAgentShim fails to handle escaped characters
+ WALinuxAgentShim fails to handle escaped characters in
+ dhclient.eth0.leases
Changed in cloud-init:
status: New → In Progress
Scott Moser (smoser) on 2015-09-24
Changed in cloud-init:
importance: Undecided → Medium
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers