#5620 closed defect (fixed)

HTTP client doesn't understand URL syntax including IPv6 address

Reported by: marcin Owned by: marcin
Priority: high Milestone: Kea1.4
Component: http Version: git
Keywords: Cc:
CVSS Scoring: Parent Tickets:
Sensitive: no Defect Severity: N/A
Sub-Project: DHCP Feature Depending on Ticket:
Estimated Difficulty: 0 Add Hours to Ticket: 0
Total Hours: 0 Internal?: no

Description

The HTTP client uses !Url object to specify the destination that the client should communicate with. The Url class can parse addresses using the following notation:

http://[2001:db8:1::1]:8080/

however, it doesn't provide any methods to retrieve hostname stripped from [ ]. The HttpClient uses the unstripped hostname to create an endpoint instance, but an attempt to pass:

[2001:db8:1::1]

to the IOAddress constructor will result in an exception. It seems that the best way to deal with this would be to add new method to the Url class which can return unstripped hostname.

Subtickets

Change History (3)

comment:1 Changed 11 months ago by marcin

  • Milestone changed from Kea-proposed to Kea1.4
  • Owner set to tomek
  • Status changed from new to reviewing

comment:2 Changed 11 months ago by tomek

  • Owner changed from tomek to marcin

I have reviewed those changes. They are good to go.

Please include ChangeLog? entry, something like this text will do:

139X.	[bug]		marcin
	A bug in http client library was fixed. The IPv6 address specified
	in brackets is now supported properly.
	(Trac #5620, git tbd)
Version 0, edited 11 months ago by tomek (next)

comment:3 Changed 11 months ago by marcin

  • Resolution set to fixed
  • Status changed from reviewing to closed

Merged with commit fe38c4368853e47bc993d6c3844cdddba5effde5

Note: See TracTickets for help on using tickets.