Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

netgraph: Fix CHERI tag violations due to tight subobject bounds in sockaddr_* structs #2280

Merged
merged 1 commit into from
Dec 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion sys/netgraph/bluetooth/include/ng_btsocket.h
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
struct sockaddr_hci {
u_char hci_len; /* total length */
u_char hci_family; /* address family */
char hci_node[32]; /* address (size == NG_NODESIZ ) */
char hci_node[32] __subobject_variable_length_maxsize(32); /* address (size == NG_NODESIZ ) */

Check warning on line 54 in sys/netgraph/bluetooth/include/ng_btsocket.h

View workflow job for this annotation

GitHub Actions / Style Checker

line over 80 characters

Check warning on line 54 in sys/netgraph/bluetooth/include/ng_btsocket.h

View workflow job for this annotation

GitHub Actions / Style Checker

line over 80 characters
};

/* Raw HCI socket options */
Expand Down
2 changes: 1 addition & 1 deletion sys/netgraph/ng_socket.h
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
struct sockaddr_ng {
unsigned char sg_len; /* total length */
sa_family_t sg_family; /* address family */
char sg_data[32]; /* see NG_NODESIZ in ng_message.h */
char sg_data[32] __subobject_variable_length_maxsize(32); /* see NG_NODESIZ in ng_message.h */

Check warning on line 63 in sys/netgraph/ng_socket.h

View workflow job for this annotation

GitHub Actions / Style Checker

line over 80 characters

Check warning on line 63 in sys/netgraph/ng_socket.h

View workflow job for this annotation

GitHub Actions / Style Checker

line over 80 characters
};

#endif /* _NETGRAPH_NG_SOCKET_H_ */

Check warning on line 66 in sys/netgraph/ng_socket.h

View workflow job for this annotation

GitHub Actions / Style Checker

Missing Signed-off-by: line

Check warning on line 66 in sys/netgraph/ng_socket.h

View workflow job for this annotation

GitHub Actions / Style Checker

Missing Signed-off-by: line
Loading