Opened 7 years ago

Closed 6 years ago

#3177 closed defect (fixed)

Kea6 realy agent - incorrect port number

Reported by: wlodekwencel Owned by: tomek
Priority: medium Milestone: Sprint-DHCP-20131016
Component: dhcp6 Version:
Keywords: relay 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

Kea6 uses incorrect port number for sending relay-reply msg.

Uses 546 instead 547 (according to RFC 3315)

attached wireshark capture.

Subtickets

Attachments (1)

relay-port-number (36.2 KB) - added by wlodekwencel 7 years ago.

Download all attachments as: .zip

Change History (9)

Changed 7 years ago by wlodekwencel

comment:1 Changed 7 years ago by tomek

  • Milestone changed from DHCP-QA Defects to Sprint-DHCP-20130918
  • Owner changed from wlodekwencel to tomek
  • Status changed from new to accepted

comment:2 Changed 6 years ago by tomek

  • Owner changed from tomek to UnAssigned
  • Status changed from accepted to reviewing

This ticket is ready for review. Please note that during unit-test development, it was discovered that the Kea code is not able to handle traffic from cable modems. A separate ticket (#3180) was created for it and the unit-test was disabled.

I have created a separate wireshark.cc file that is supposed to store traffic captures imported from Wireshark. Right now it is small, but I hope that library of packets will grow larger over time.

comment:3 Changed 6 years ago by tomek

  • Milestone changed from Sprint-DHCP-20130918 to Sprint-DHCP-20131016

comment:4 Changed 6 years ago by stephen

  • Owner changed from UnAssigned to stephen

comment:5 follow-up: Changed 6 years ago by stephen

  • Owner changed from stephen to tomek

Reviewed commit 23c944640d1b697af40582f7999b40b05b17a44a

src/bin/dhcp6/tests/wireshark.cc
Unless we're keeping the pcap files somewhere, a reference in a comment to a particular pcap file is meaningless.

The setting of the local and remote address and port, and the setting of index and interface is identical in each of the functions (albeit with a variation of the address). This should be put in a common function (with parameters such as address etc, passed as parameters if required).

Comments should not that the caller must delete the returned pointer. (Alternatively, return the data via a Pkt6Ptr - it is safer.)

comment:6 in reply to: ↑ 5 Changed 6 years ago by tomek

  • Owner changed from tomek to stephen

Replying to stephen:

Reviewed commit 23c944640d1b697af40582f7999b40b05b17a44a

src/bin/dhcp6/tests/wireshark.cc
Unless we're keeping the pcap files somewhere, a reference in a comment to a particular pcap file is meaningless.

Just added the file to dhcp-val. However, since the file may contain sensitive info, removed the reference to it. It should be safe as the dhcp-val is not available publicly. Anyway, removed the filename from wireshark.cc.

My plan/hope is that some day we will develop a test that will read all pcap files from specified directory and try to process all DHCP packets in them through Kea. That would be a very flexible and extensible approach. To add a new test case, we'd have to only add new pcap file. The pcap collection could be confidential and stored separately. But it's a far way for now.

The setting of the local and remote address and port, and the setting of index and interface is identical in each of the functions (albeit with a variation of the address). This should be put in a common function (with parameters such as address etc, passed as parameters if required).

Added new method.

Comments should not that the caller must delete the returned pointer. (Alternatively, return the data via a Pkt6Ptr - it is safer.)

Done.

Unless you have any other comments, I think this ticket is ready to merge. Thanks for fast review.

comment:7 follow-up: Changed 6 years ago by stephen

  • Owner changed from stephen to tomek

My plan/hope is that some day we will develop a test that will read all pcap files from specified directory and try to process all DHCP packets in them through Kea. That would be a very flexible and extensible approach. To add a new test case, we'd have to only add new pcap file. The pcap collection could be confidential and stored separately. But it's a far way for now.

Could you open a ticket for that? I think it would be an excellent feature, and one that could be extended into DNS as well.

src/bin/dhcp6/tests/wireshark.cc
In captureSimpleSolicit(), "pkt" could be declared and initialized at the same time instead of declaring it and calling reset().

I don't need to see this again, ready to merge.

comment:8 in reply to: ↑ 7 Changed 6 years ago by tomek

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

Replying to stephen:

Could you open a ticket for that? I think it would be an excellent feature, and one that could be extended into DNS as well.

Created #3185.

src/bin/dhcp6/tests/wireshark.cc
In captureSimpleSolicit(), "pkt" could be declared and initialized at the same time instead of declaring it and calling reset().

Done.

I don't need to see this again, ready to merge.

Merged. Thanks again.

Note: See TracTickets for help on using tickets.