-
Notifications
You must be signed in to change notification settings - Fork 236
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
controller: fix possible unaligned accesses in DHCPv6 code
According to RFC8415 [0], section 8 "Client/Server Message Formats": "Options are stored serially in the "options" field, with no padding between the options. Options are byte-aligned but are not aligned in any other way (such as on 2-byte or 4-byte boundaries)." Fix possible unaligned accesses in DHCPv6 code reading/writing getting rid of dhcp_opt6_header structure that trigger undefined behaviour issues reported by ubsan sanitizer and relying on dhcpv6_opt_header that is defined as packed. [0] https://www.rfc-editor.org/rfc/rfc8415.html Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi@redhat.com> Acked-by: Mark Michelson <mmichels@redhat.com> Signed-off-by: Numan Siddique <numans@ovn.org> (cherry picked from commit 8298eac)
- Loading branch information
1 parent
8b7d92c
commit 57c788a
Showing
3 changed files
with
8 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters