From nobody Sun Feb 05 15:01:37 2023 X-Original-To: wireless@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4P8szj5BB1z3ndMf for ; Sun, 5 Feb 2023 15:01:37 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4P8szj0S3lz41fS for ; Sun, 5 Feb 2023 15:01:37 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1675609297; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tqWaCipIIT9CIgkfpKgBxjz3evXij84y/3ys1TkNe20=; b=jgOSm/sMBHXGWB6Rd+aFOHLiIOtiwKO0bHQ22F/djE9zl9CSoiLtnjrbGuNEZIxFmr0qn5 lRkYwKXdZUtENa9juH/jEAtL0RPGNIb3h/SY17mSFUBBIsS4ChGmSilscKbe4JpwjLuyVm zNHo/9NwRhlLc57ZrPp87tLyEkhaAGHNu7AYwPlb01aey+ouoMx/tW8mjshDZlE1w7z5GH iKStDedFHP7t4FZJaSlMT46NjyNkEHKwBq9VKXTAoCc637Xt7mPmRNE3yB9QrOaJ3xmf81 nNOAGeFRCy9On+si2AtK6CYgMm1ehxMM1FLOkWmjPE5BBIQ6elHJMKz8G8xpag== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1675609297; a=rsa-sha256; cv=none; b=bfBrjvfJoYvdQz5mjBDhTlrDa6hRnL6WeIIy1TZuC17Vavy2iNMWfdSVGjoRDu6LvVbiKy R7BH1v7HcIaJWK9nmkr4yHoD/HG1DYioViSGLrSibI7qulHrWKi6QGoO+dtQ6Ht0ZWZdYS 0vTqgG4WXjOgVFe7NCxUNm25mU/ZtLa3jR4purr5EPFzNu9bZBdXy/KiQfWQXDJfhPd46C f8iseW+Pr83r6TZuY5qDxEZAAJhPgVGhR4k+NKFxVoDWSIXvRk+gxQqQPKdIQJhJmX13OX SIgcinjPG51aqick5vX+pr6s8Idnns9eb8evacDDhIbNaoEB1woXlcFA3/QMEQ== Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4P8szh6fTpzyRT for ; Sun, 5 Feb 2023 15:01:36 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 315F1a23098932 for ; Sun, 5 Feb 2023 15:01:36 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 315F1a0G098931 for wireless@FreeBSD.org; Sun, 5 Feb 2023 15:01:36 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: wireless@FreeBSD.org Subject: [Bug 269339] 802.11 mesh peer can trigger panic with PREP/PREQ/RANN action with broadcast Date: Sun, 05 Feb 2023 15:01:37 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: wireless X-Bugzilla-Version: CURRENT X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Some People X-Bugzilla-Who: rtm@lcs.mit.edu X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: wireless@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter attachments.mimetype attachments.created Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Discussions List-Archive: https://lists.freebsd.org/archives/freebsd-wireless List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-wireless@freebsd.org X-BeenThere: freebsd-wireless@freebsd.org MIME-Version: 1.0 X-ThisMailContainsUnwantedMimeParts: N https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D269339 Bug ID: 269339 Summary: 802.11 mesh peer can trigger panic with PREP/PREQ/RANN action with broadcast Product: Base System Version: CURRENT Hardware: Any OS: Any Status: New Severity: Affects Some People Priority: --- Component: wireless Assignee: wireless@FreeBSD.org Reporter: rtm@lcs.mit.edu Attachment #239919 text/plain mime type: Created attachment 239919 --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D239919&action= =3Dedit produce a panic with a bad PREQ 802.11 mesh action frame If an 802.11 mesh peer sends a PREQ action frame with broadcast preq_orgaddr, hwmp_recv_preq() will call ieee80211_mesh_rt_add() with that address, and mesh_rt_add_locked() will panic. Similar problems exist with calls to ieee80211_mesh_rt_add() for PREP and RANN frames. I've attached a demo: # cc wtap19a.c # ./a.out wlan0: received action from 00:98:9a:98:96:98 rssi 128 wlan0: [00:98:9a:98:96:98] received PREQ, orig ff:ff:ff:ff:ff:ff, targ(0) ff:ff:ff:ff:ff:ff panic: mesh_rt_add_locked: adding broadcast to the routing table panic() at panic+0x2a mesh_rt_add_locked() at mesh_rt_add_locked+0x11a ieee80211_mesh_rt_add() at ieee80211_mesh_rt_add+0x60 hwmp_recv_preq() at hwmp_recv_preq+0xac4 hwmp_recv_action_meshpath() at hwmp_recv_action_meshpath+0x29a ieee80211_recv_action() at ieee80211_recv_action+0x13c mesh_recv_mgmt() at mesh_recv_mgmt+0x202 wtap_recv_mgmt() at wtap_recv_mgmt+0x28 mesh_input() at mesh_input+0x512 .LBB2_17() at .LBB2_17+0x34 taskqueue_run_locked() at taskqueue_run_locked+0x96 taskqueue_thread_loop() at taskqueue_thread_loop+0x62 fork_exit() at fork_exit+0x80 fork_trampoline() at fork_trampoline+0xa --=20 You are receiving this mail because: You are the assignee for the bug.=