linux-usb.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* malicious devices causing unaligned accesses
@ 2022-02-17  8:39 Oliver Neukum
  0 siblings, 0 replies; only message in thread
From: Oliver Neukum @ 2022-02-17  8:39 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: stern, USB list, netdev, Giuliano Belinassi, Bjørn Mork

Hi,

going through the USB network drivers looking for ways
a malicious device could do us harm I found drivers taking
the alignment coming from the device for granted.

An example can be seen in qmi_wwan:

while (offset + qmimux_hdr_sz < skb->len) { hdr = (struct qmimux_hdr
*)(skb->data + offset); len = be16_to_cpu(hdr->pkt_len); As you can see
the driver accesses stuff coming from the device with the expectation
that it keep to natural alignment. On some architectures that is a way a
device could use to do bad things to a host. What is to be done about
that? Regards Oliver


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-02-17  8:39 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-02-17  8:39 malicious devices causing unaligned accesses Oliver Neukum

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).