🇰🇷 한글 설명
Linux 커널의 usbnet 드라이버가 probe 과정에서 driver_info로 전달받은 bulk 엔드포인트 주소의 존재 여부, 타입, 방향을 검증하지 않아 잘못된 USB URB 전송 시 커널 경고(WARNING)가 발생하는 문제입니다. 수정은 엔드포인트 검사를 추가하는 것입니다.
💡 쉬운 설명
USB 네트워크 장치를 연결할 때 리눅스가 장치의 통신 채널이 올바른지 확인하지 않아 생기는 결함입니다. 잘못된 장치나 조작된 장치가 연결되면 커널에서 경고가 발생할 수 있습니다.
🇺🇸 원문 (English)
In the Linux kernel, the following vulnerability has been resolved:
net: usbnet: Fix WARNING in usbnet_start_xmit/usb_submit_urb
The syzbot fuzzer identified a problem in the usbnet driver:
usb 1-1: BOGUS urb xfer, pipe 3 != type 1
WARNING: CPU: 0 PID: 754 at drivers/usb/core/urb.c:504 usb_submit_urb+0xed6/0x1880 drivers/usb/core/urb.c:504
Modules linked in:
CPU: 0 PID: 754 Comm: kworker/0:2 Not tainted 6.4.0-rc7-syzkaller-00014-g692b7dc87ca6 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/27/2023
Workqueue: mld mld_ifc_work
RIP: 0010:usb_submit_urb+0xed6/0x1880 drivers/usb/core/urb.c:504
Code: 7c 24 18 e8 2c b4 5b fb 48 8b 7c 24 18 e8 42 07 f0 fe 41 89 d8 44 89 e1 4c 89 ea 48 89 c6 48 c7 c7 a0 c9 fc 8a e8 5a 6f 23 fb <0f> 0b e9 58 f8 ff ff e8 fe b3 5b fb 48 81 c5 c0 05 00 00 e9 84 f7
RSP: 0018:ffffc9000463f568 EFLAGS: 00010086
RAX: 0000000000000000 RBX: 0000000000000001 RCX: 0000000000000000
RDX: ffff88801eb28000 RSI: ffffffff814c03b7 RDI: 0000000000000001
RBP: ffff8881443b7190 R08: 0000000000000001 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000001 R12: 0000000000000003
R13: ffff88802a77cb18 R14: 0000000000000003 R15: ffff888018262500
FS: 0000000000000000(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000556a99c15a18 CR3: 0000000028c71000 CR4: 0000000000350ef0
Call Trace:
<TASK>
usbnet_start_xmit+0xfe5/0x2190 drivers/net/usb/usbnet.c:1453
__netdev_start_xmit include/linux/netdevice.h:4918 [inline]
netdev_start_xmit include/linux/netdevice.h:4932 [inline]
xmit_one net/core/dev.c:3578 [inline]
dev_hard_start_xmit+0x187/0x700 net/core/dev.c:3594
...
This bug is caused by the fact that usbnet trusts the bulk endpoint
addresses its probe routine receives in the driver_info structure, and
it does not check to see that these endpoints actually exist and have
the expected type and directions.
The fix is simply to add such a check.
📍 영향받는 시스템
수정 이전의 Linux 커널 (usbnet 드라이버를 사용하는 USB 네트워크 장치 지원 버전)
⚔️ 공격 벡터
물리적으로 USB 네트워크 장치를 연결하거나 악성 USB 장치를 이용해 잘못된 엔드포인트 구성을 가진 장치를 연결하는 방식
🛡️ 대응 방법
배포판에서 제공하는 최신 Linux 커널 보안 업데이트를 설치하고 재부팅합니다.
🔧 검증 코드
출력된 커널 버전을 배포판 보안 공지에서 제공하는 수정된 패키지 버전과 비교하여, 수정 이전 버전이면 업데이트가 필요하고 수정된 버전 이상이면 패치가 적용된 것입니다.