Skip to content
Snippets Groups Projects
  1. Jul 07, 2022
    • Duoming Zhou's avatar
      net: rose: fix UAF bug caused by rose_t0timer_expiry · 148ca045
      Duoming Zhou authored
      
      There are UAF bugs caused by rose_t0timer_expiry(). The
      root cause is that del_timer() could not stop the timer
      handler that is running and there is no synchronization.
      One of the race conditions is shown below:
      
          (thread 1)             |        (thread 2)
                                 | rose_device_event
                                 |   rose_rt_device_down
                                 |     rose_remove_neigh
      rose_t0timer_expiry        |       rose_stop_t0timer(rose_neigh)
        ...                      |         del_timer(&neigh->t0timer)
                                 |         kfree(rose_neigh) //[1]FREE
        neigh->dce_mode //[2]USE |
      
      The rose_neigh is deallocated in position [1] and use in
      position [2].
      
      The crash trace triggered by POC is like below:
      
      BUG: KASAN: use-after-free in expire_timers+0x144/0x320
      Write of size 8 at addr ffff888009b19658 by task swapper/0/0
      ...
      Call Trace:
       <IRQ>
       dump_stack_lvl+0xbf/0xee
       print_address_description+0x7b/0x440
       print_report+0x101/0x230
       ? expire_timers+0x144/0x320
       kasan_report+0xed/0x120
       ? expire_timers+0x144/0x320
       expire_timers+0x144/0x320
       __run_timers+0x3ff/0x4d0
       run_timer_softirq+0x41/0x80
       __do_softirq+0x233/0x544
       ...
      
      This patch changes rose_stop_ftimer() and rose_stop_t0timer()
      in rose_remove_neigh() to del_timer_sync() in order that the
      timer handler could be finished before the resources such as
      rose_neigh and so on are deallocated. As a result, the UAF
      bugs could be mitigated.
      
      Fixes: 1da177e4 ("Linux-2.6.12-rc2")
      Signed-off-by: default avatarDuoming Zhou <duoming@zju.edu.cn>
      Link: https://lore.kernel.org/r/20220705125610.77971-1-duoming@zju.edu.cn
      
      
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      148ca045
  2. Jul 06, 2022
  3. Jul 05, 2022
  4. Jul 04, 2022
    • Oliver Hartkopp's avatar
      can: bcm: use call_rcu() instead of costly synchronize_rcu() · f1b4e32a
      Oliver Hartkopp authored
      In commit d5f9023f ("can: bcm: delay release of struct bcm_op
      after synchronize_rcu()") Thadeu Lima de Souza Cascardo introduced two
      synchronize_rcu() calls in bcm_release() (only once at socket close)
      and in bcm_delete_rx_op() (called on removal of each single bcm_op).
      
      Unfortunately this slow removal of the bcm_op's affects user space
      applications like cansniffer where the modification of a filter
      removes 2048 bcm_op's which blocks the cansniffer application for
      40(!) seconds.
      
      In commit 181d4447 ("can: gw: use call_rcu() instead of costly
      synchronize_rcu()") Eric Dumazet replaced the synchronize_rcu() calls
      with several call_rcu()'s to safely remove the data structures after
      the removal of CAN ID subscriptions with can_rx_unregister() calls.
      
      This patch adopts Erics approach for the can-bcm which should be
      applicable since the removal of tasklet_kill() in bcm_remove_op() and
      the introduction of the HRTIMER_MODE_SOFT timer handling in Linux 5.4.
      
      Fixes: d5f9023f ("can: bcm: delay release of struct bcm_op after synchronize_rcu()") # >= 5.4
      Link: https://lore.kernel.org/all/20220520183239.19111-1-socketcan@hartkopp.net
      
      
      Cc: stable@vger.kernel.org
      Cc: Eric Dumazet <edumazet@google.com>
      Cc: Norbert Slusarek <nslusarek@gmx.net>
      Cc: Thadeu Lima de Souza Cascardo <cascardo@canonical.com>
      Signed-off-by: default avatarOliver Hartkopp <socketcan@hartkopp.net>
      Signed-off-by: default avatarMarc Kleine-Budde <mkl@pengutronix.de>
      f1b4e32a
  5. Jul 02, 2022
    • Pablo Neira Ayuso's avatar
      netfilter: nft_set_pipapo: release elements in clone from abort path · 9827a0e6
      Pablo Neira Ayuso authored
      
      New elements that reside in the clone are not released in case that the
      transaction is aborted.
      
      [16302.231754] ------------[ cut here ]------------
      [16302.231756] WARNING: CPU: 0 PID: 100509 at net/netfilter/nf_tables_api.c:1864 nf_tables_chain_destroy+0x26/0x127 [nf_tables]
      [...]
      [16302.231882] CPU: 0 PID: 100509 Comm: nft Tainted: G        W         5.19.0-rc3+ #155
      [...]
      [16302.231887] RIP: 0010:nf_tables_chain_destroy+0x26/0x127 [nf_tables]
      [16302.231899] Code: f3 fe ff ff 41 55 41 54 55 53 48 8b 6f 10 48 89 fb 48 c7 c7 82 96 d9 a0 8b 55 50 48 8b 75 58 e8 de f5 92 e0 83 7d 50 00 74 09 <0f> 0b 5b 5d 41 5c 41 5d c3 4c 8b 65 00 48 8b 7d 08 49 39 fc 74 05
      [...]
      [16302.231917] Call Trace:
      [16302.231919]  <TASK>
      [16302.231921]  __nf_tables_abort.cold+0x23/0x28 [nf_tables]
      [16302.231934]  nf_tables_abort+0x30/0x50 [nf_tables]
      [16302.231946]  nfnetlink_rcv_batch+0x41a/0x840 [nfnetlink]
      [16302.231952]  ? __nla_validate_parse+0x48/0x190
      [16302.231959]  nfnetlink_rcv+0x110/0x129 [nfnetlink]
      [16302.231963]  netlink_unicast+0x211/0x340
      [16302.231969]  netlink_sendmsg+0x21e/0x460
      
      Add nft_set_pipapo_match_destroy() helper function to release the
      elements in the lookup tables.
      
      Stefano Brivio says: "We additionally look for elements pointers in the
      cloned matching data if priv->dirty is set, because that means that
      cloned data might point to additional elements we did not commit to the
      working copy yet (such as the abort path case, but perhaps not limited
      to it)."
      
      Fixes: 3c4287f6 ("nf_tables: Add set type for arbitrary concatenation of ranges")
      Reviewed-by: default avatarStefano Brivio <sbrivio@redhat.com>
      Signed-off-by: default avatarPablo Neira Ayuso <pablo@netfilter.org>
      9827a0e6
    • Pablo Neira Ayuso's avatar
      netfilter: nf_tables: stricter validation of element data · 7e6bc1f6
      Pablo Neira Ayuso authored
      
      Make sure element data type and length do not mismatch the one specified
      by the set declaration.
      
      Fixes: 7d740264 ("netfilter: nf_tables: variable sized set element keys / data")
      Reported-by: default avatarHugues ANGUELKOV <hanguelkov@randorisec.fr>
      Signed-off-by: default avatarPablo Neira Ayuso <pablo@netfilter.org>
      7e6bc1f6
  6. Jun 30, 2022
    • Chuck Lever's avatar
      SUNRPC: Fix READ_PLUS crasher · a23dd544
      Chuck Lever authored
      
      Looks like there are still cases when "space_left - frag1bytes" can
      legitimately exceed PAGE_SIZE. Ensure that xdr->end always remains
      within the current encode buffer.
      
      Reported-by: default avatarBruce Fields <bfields@fieldses.org>
      Reported-by: default avatarZorro Lang <zlang@redhat.com>
      Link: https://bugzilla.kernel.org/show_bug.cgi?id=216151
      
      
      Fixes: 6c254bf3 ("SUNRPC: Fix the calculation of xdr->end in xdr_get_next_encode_buffer()")
      Signed-off-by: default avatarChuck Lever <chuck.lever@oracle.com>
      a23dd544
    • Duoming Zhou's avatar
      net: rose: fix UAF bugs caused by timer handler · 9cc02ede
      Duoming Zhou authored and Paolo Abeni's avatar Paolo Abeni committed
      
      There are UAF bugs in rose_heartbeat_expiry(), rose_timer_expiry()
      and rose_idletimer_expiry(). The root cause is that del_timer()
      could not stop the timer handler that is running and the refcount
      of sock is not managed properly.
      
      One of the UAF bugs is shown below:
      
          (thread 1)          |        (thread 2)
                              |  rose_bind
                              |  rose_connect
                              |    rose_start_heartbeat
      rose_release            |    (wait a time)
        case ROSE_STATE_0     |
        rose_destroy_socket   |  rose_heartbeat_expiry
          rose_stop_heartbeat |
          sock_put(sk)        |    ...
        sock_put(sk) // FREE  |
                              |    bh_lock_sock(sk) // USE
      
      The sock is deallocated by sock_put() in rose_release() and
      then used by bh_lock_sock() in rose_heartbeat_expiry().
      
      Although rose_destroy_socket() calls rose_stop_heartbeat(),
      it could not stop the timer that is running.
      
      The KASAN report triggered by POC is shown below:
      
      BUG: KASAN: use-after-free in _raw_spin_lock+0x5a/0x110
      Write of size 4 at addr ffff88800ae59098 by task swapper/3/0
      ...
      Call Trace:
       <IRQ>
       dump_stack_lvl+0xbf/0xee
       print_address_description+0x7b/0x440
       print_report+0x101/0x230
       ? irq_work_single+0xbb/0x140
       ? _raw_spin_lock+0x5a/0x110
       kasan_report+0xed/0x120
       ? _raw_spin_lock+0x5a/0x110
       kasan_check_range+0x2bd/0x2e0
       _raw_spin_lock+0x5a/0x110
       rose_heartbeat_expiry+0x39/0x370
       ? rose_start_heartbeat+0xb0/0xb0
       call_timer_fn+0x2d/0x1c0
       ? rose_start_heartbeat+0xb0/0xb0
       expire_timers+0x1f3/0x320
       __run_timers+0x3ff/0x4d0
       run_timer_softirq+0x41/0x80
       __do_softirq+0x233/0x544
       irq_exit_rcu+0x41/0xa0
       sysvec_apic_timer_interrupt+0x8c/0xb0
       </IRQ>
       <TASK>
       asm_sysvec_apic_timer_interrupt+0x1b/0x20
      RIP: 0010:default_idle+0xb/0x10
      RSP: 0018:ffffc9000012fea0 EFLAGS: 00000202
      RAX: 000000000000bcae RBX: ffff888006660f00 RCX: 000000000000bcae
      RDX: 0000000000000001 RSI: ffffffff843a11c0 RDI: ffffffff843a1180
      RBP: dffffc0000000000 R08: dffffc0000000000 R09: ffffed100da36d46
      R10: dfffe9100da36d47 R11: ffffffff83cf0950 R12: 0000000000000000
      R13: 1ffff11000ccc1e0 R14: ffffffff8542af28 R15: dffffc0000000000
      ...
      Allocated by task 146:
       __kasan_kmalloc+0xc4/0xf0
       sk_prot_alloc+0xdd/0x1a0
       sk_alloc+0x2d/0x4e0
       rose_create+0x7b/0x330
       __sock_create+0x2dd/0x640
       __sys_socket+0xc7/0x270
       __x64_sys_socket+0x71/0x80
       do_syscall_64+0x43/0x90
       entry_SYSCALL_64_after_hwframe+0x46/0xb0
      
      Freed by task 152:
       kasan_set_track+0x4c/0x70
       kasan_set_free_info+0x1f/0x40
       ____kasan_slab_free+0x124/0x190
       kfree+0xd3/0x270
       __sk_destruct+0x314/0x460
       rose_release+0x2fa/0x3b0
       sock_close+0xcb/0x230
       __fput+0x2d9/0x650
       task_work_run+0xd6/0x160
       exit_to_user_mode_loop+0xc7/0xd0
       exit_to_user_mode_prepare+0x4e/0x80
       syscall_exit_to_user_mode+0x20/0x40
       do_syscall_64+0x4f/0x90
       entry_SYSCALL_64_after_hwframe+0x46/0xb0
      
      This patch adds refcount of sock when we use functions
      such as rose_start_heartbeat() and so on to start timer,
      and decreases the refcount of sock when timer is finished
      or deleted by functions such as rose_stop_heartbeat()
      and so on. As a result, the UAF bugs could be mitigated.
      
      Fixes: 1da177e4 ("Linux-2.6.12-rc2")
      Signed-off-by: default avatarDuoming Zhou <duoming@zju.edu.cn>
      Tested-by: default avatarDuoming Zhou <duoming@zju.edu.cn>
      Link: https://lore.kernel.org/r/20220629002640.5693-1-duoming@zju.edu.cn
      
      
      Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
      9cc02ede
    • Eric Dumazet's avatar
      ipv6: fix lockdep splat in in6_dump_addrs() · 4e43e64d
      Eric Dumazet authored
      
      As reported by syzbot, we should not use rcu_dereference()
      when rcu_read_lock() is not held.
      
      WARNING: suspicious RCU usage
      5.19.0-rc2-syzkaller #0 Not tainted
      
      net/ipv6/addrconf.c:5175 suspicious rcu_dereference_check() usage!
      
      other info that might help us debug this:
      
      rcu_scheduler_active = 2, debug_locks = 1
      1 lock held by syz-executor326/3617:
       #0: ffffffff8d5848e8 (rtnl_mutex){+.+.}-{3:3}, at: netlink_dump+0xae/0xc20 net/netlink/af_netlink.c:2223
      
      stack backtrace:
      CPU: 0 PID: 3617 Comm: syz-executor326 Not tainted 5.19.0-rc2-syzkaller #0
      Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
      Call Trace:
       <TASK>
       __dump_stack lib/dump_stack.c:88 [inline]
       dump_stack_lvl+0xcd/0x134 lib/dump_stack.c:106
       in6_dump_addrs+0x12d1/0x1790 net/ipv6/addrconf.c:5175
       inet6_dump_addr+0x9c1/0xb50 net/ipv6/addrconf.c:5300
       netlink_dump+0x541/0xc20 net/netlink/af_netlink.c:2275
       __netlink_dump_start+0x647/0x900 net/netlink/af_netlink.c:2380
       netlink_dump_start include/linux/netlink.h:245 [inline]
       rtnetlink_rcv_msg+0x73e/0xc90 net/core/rtnetlink.c:6046
       netlink_rcv_skb+0x153/0x420 net/netlink/af_netlink.c:2501
       netlink_unicast_kernel net/netlink/af_netlink.c:1319 [inline]
       netlink_unicast+0x543/0x7f0 net/netlink/af_netlink.c:1345
       netlink_sendmsg+0x917/0xe10 net/netlink/af_netlink.c:1921
       sock_sendmsg_nosec net/socket.c:714 [inline]
       sock_sendmsg+0xcf/0x120 net/socket.c:734
       ____sys_sendmsg+0x6eb/0x810 net/socket.c:2492
       ___sys_sendmsg+0xf3/0x170 net/socket.c:2546
       __sys_sendmsg net/socket.c:2575 [inline]
       __do_sys_sendmsg net/socket.c:2584 [inline]
       __se_sys_sendmsg net/socket.c:2582 [inline]
       __x64_sys_sendmsg+0x132/0x220 net/socket.c:2582
       do_syscall_x64 arch/x86/entry/common.c:50 [inline]
       do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80
       entry_SYSCALL_64_after_hwframe+0x46/0xb0
      
      Fixes: 88e2ca30 ("mld: convert ifmcaddr6 to RCU")
      Reported-by: default avatarsyzbot <syzkaller@googlegroups.com>
      Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
      Cc: Taehee Yoo <ap420073@gmail.com>
      Link: https://lore.kernel.org/r/20220628121248.858695-1-edumazet@google.com
      
      
      Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
      4e43e64d
  7. Jun 29, 2022
  8. Jun 28, 2022
  9. Jun 27, 2022
    • Florian Westphal's avatar
      netfilter: br_netfilter: do not skip all hooks with 0 priority · c2577862
      Florian Westphal authored
      
      When br_netfilter module is loaded, skbs may be diverted to the
      ipv4/ipv6 hooks, just like as if we were routing.
      
      Unfortunately, bridge filter hooks with priority 0 may be skipped
      in this case.
      
      Example:
      1. an nftables bridge ruleset is loaded, with a prerouting
         hook that has priority 0.
      2. interface is added to the bridge.
      3. no tcp packet is ever seen by the bridge prerouting hook.
      4. flush the ruleset
      5. load the bridge ruleset again.
      6. tcp packets are processed as expected.
      
      After 1) the only registered hook is the bridge prerouting hook, but its
      not called yet because the bridge hasn't been brought up yet.
      
      After 2), hook order is:
         0 br_nf_pre_routing // br_netfilter internal hook
         0 chain bridge f prerouting // nftables bridge ruleset
      
      The packet is diverted to br_nf_pre_routing.
      If call-iptables is off, the nftables bridge ruleset is called as expected.
      
      But if its enabled, br_nf_hook_thresh() will skip it because it assumes
      that all 0-priority hooks had been called previously in bridge context.
      
      To avoid this, check for the br_nf_pre_routing hook itself, we need to
      resume directly after it, even if this hook has a priority of 0.
      
      Unfortunately, this still results in different packet flow.
      With this fix, the eval order after in 3) is:
      1. br_nf_pre_routing
      2. ip(6)tables (if enabled)
      3. nftables bridge
      
      but after 5 its the much saner:
      1. nftables bridge
      2. br_nf_pre_routing
      3. ip(6)tables (if enabled)
      
      Unfortunately I don't see a solution here:
      It would be possible to move br_nf_pre_routing to a higher priority
      so that it will be called later in the pipeline, but this also impacts
      ebtables evaluation order, and would still result in this very ordering
      problem for all nftables-bridge hooks with the same priority as the
      br_nf_pre_routing one.
      
      Searching back through the git history I don't think this has
      ever behaved in any other way, hence, no fixes-tag.
      
      Reported-by: default avatarRadim Hrazdil <rhrazdil@redhat.com>
      Signed-off-by: default avatarFlorian Westphal <fw@strlen.de>
      Signed-off-by: default avatarPablo Neira Ayuso <pablo@netfilter.org>
      c2577862
    • Florian Westphal's avatar
      netfilter: nf_tables: avoid skb access on nf_stolen · e34b9ed9
      Florian Westphal authored
      
      When verdict is NF_STOLEN, the skb might have been freed.
      
      When tracing is enabled, this can result in a use-after-free:
      1. access to skb->nf_trace
      2. access to skb->mark
      3. computation of trace id
      4. dump of packet payload
      
      To avoid 1, keep a cached copy of skb->nf_trace in the
      trace state struct.
      Refresh this copy whenever verdict is != STOLEN.
      
      Avoid 2 by skipping skb->mark access if verdict is STOLEN.
      
      3 is avoided by precomputing the trace id.
      
      Only dump the packet when verdict is not "STOLEN".
      
      Reported-by: default avatarPablo Neira Ayuso <pablo@netfilter.org>
      Signed-off-by: default avatarFlorian Westphal <fw@strlen.de>
      Signed-off-by: default avatarPablo Neira Ayuso <pablo@netfilter.org>
      e34b9ed9
    • Pablo Neira Ayuso's avatar
      netfilter: nft_dynset: restore set element counter when failing to update · 05907f10
      Pablo Neira Ayuso authored
      
      This patch fixes a race condition.
      
      nft_rhash_update() might fail for two reasons:
      
      - Element already exists in the hashtable.
      - Another packet won race to insert an entry in the hashtable.
      
      In both cases, new() has already bumped the counter via atomic_add_unless(),
      therefore, decrement the set element counter.
      
      Fixes: 22fe54d5 ("netfilter: nf_tables: add support for dynamic set updates")
      Signed-off-by: default avatarPablo Neira Ayuso <pablo@netfilter.org>
      05907f10
    • Xin Long's avatar
      tipc: move bc link creation back to tipc_node_create · cb8092d7
      Xin Long authored
      
      Shuang Li reported a NULL pointer dereference crash:
      
        [] BUG: kernel NULL pointer dereference, address: 0000000000000068
        [] RIP: 0010:tipc_link_is_up+0x5/0x10 [tipc]
        [] Call Trace:
        []  <IRQ>
        []  tipc_bcast_rcv+0xa2/0x190 [tipc]
        []  tipc_node_bc_rcv+0x8b/0x200 [tipc]
        []  tipc_rcv+0x3af/0x5b0 [tipc]
        []  tipc_udp_recv+0xc7/0x1e0 [tipc]
      
      It was caused by the 'l' passed into tipc_bcast_rcv() is NULL. When it
      creates a node in tipc_node_check_dest(), after inserting the new node
      into hashtable in tipc_node_create(), it creates the bc link. However,
      there is a gap between this insert and bc link creation, a bc packet
      may come in and get the node from the hashtable then try to dereference
      its bc link, which is NULL.
      
      This patch is to fix it by moving the bc link creation before inserting
      into the hashtable.
      
      Note that for a preliminary node becoming "real", the bc link creation
      should also be called before it's rehashed, as we don't create it for
      preliminary nodes.
      
      Fixes: 4cbf8ac2 ("tipc: enable creating a "preliminary" node")
      Reported-by: default avatarShuang Li <shuali@redhat.com>
      Signed-off-by: default avatarXin Long <lucien.xin@gmail.com>
      Acked-by: default avatarJon Maloy <jmaloy@redhat.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      cb8092d7
    • Eric Dumazet's avatar
      tunnels: do not assume mac header is set in skb_tunnel_check_pmtu() · 853a7614
      Eric Dumazet authored
      
      Recently added debug in commit f9aefd6b ("net: warn if mac header
      was not set") caught a bug in skb_tunnel_check_pmtu(), as shown
      in this syzbot report [1].
      
      In ndo_start_xmit() paths, there is really no need to use skb->mac_header,
      because skb->data is supposed to point at it.
      
      [1] WARNING: CPU: 1 PID: 8604 at include/linux/skbuff.h:2784 skb_mac_header_len include/linux/skbuff.h:2784 [inline]
      WARNING: CPU: 1 PID: 8604 at include/linux/skbuff.h:2784 skb_tunnel_check_pmtu+0x5de/0x2f90 net/ipv4/ip_tunnel_core.c:413
      Modules linked in:
      CPU: 1 PID: 8604 Comm: syz-executor.3 Not tainted 5.19.0-rc2-syzkaller-00443-g8720bd951b8e #0
      Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
      RIP: 0010:skb_mac_header_len include/linux/skbuff.h:2784 [inline]
      RIP: 0010:skb_tunnel_check_pmtu+0x5de/0x2f90 net/ipv4/ip_tunnel_core.c:413
      Code: 00 00 00 00 fc ff df 4c 89 fa 48 c1 ea 03 80 3c 02 00 0f 84 b9 fe ff ff 4c 89 ff e8 7c 0f d7 f9 e9 ac fe ff ff e8 c2 13 8a f9 <0f> 0b e9 28 fc ff ff e8 b6 13 8a f9 48 8b 54 24 70 48 b8 00 00 00
      RSP: 0018:ffffc90002e4f520 EFLAGS: 00010212
      RAX: 0000000000000324 RBX: ffff88804d5fd500 RCX: ffffc90005b52000
      RDX: 0000000000040000 RSI: ffffffff87f05e3e RDI: 0000000000000003
      RBP: ffffc90002e4f650 R08: 0000000000000003 R09: 000000000000ffff
      R10: 000000000000ffff R11: 0000000000000000 R12: 000000000000ffff
      R13: 0000000000000000 R14: 000000000000ffcd R15: 000000000000001f
      FS: 00007f3babba9700(0000) GS:ffff8880b9b00000(0000) knlGS:0000000000000000
      CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
      CR2: 0000000020000080 CR3: 0000000075319000 CR4: 00000000003506e0
      DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
      DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
      Call Trace:
      <TASK>
      geneve_xmit_skb drivers/net/geneve.c:927 [inline]
      geneve_xmit+0xcf8/0x35d0 drivers/net/geneve.c:1107
      __netdev_start_xmit include/linux/netdevice.h:4805 [inline]
      netdev_start_xmit include/linux/netdevice.h:4819 [inline]
      __dev_direct_xmit+0x500/0x730 net/core/dev.c:4309
      dev_direct_xmit include/linux/netdevice.h:3007 [inline]
      packet_direct_xmit+0x1b8/0x2c0 net/packet/af_packet.c:282
      packet_snd net/packet/af_packet.c:3073 [inline]
      packet_sendmsg+0x21f4/0x55d0 net/packet/af_packet.c:3104
      sock_sendmsg_nosec net/socket.c:714 [inline]
      sock_sendmsg+0xcf/0x120 net/socket.c:734
      ____sys_sendmsg+0x6eb/0x810 net/socket.c:2489
      ___sys_sendmsg+0xf3/0x170 net/socket.c:2543
      __sys_sendmsg net/socket.c:2572 [inline]
      __do_sys_sendmsg net/socket.c:2581 [inline]
      __se_sys_sendmsg net/socket.c:2579 [inline]
      __x64_sys_sendmsg+0x132/0x220 net/socket.c:2579
      do_syscall_x64 arch/x86/entry/common.c:50 [inline]
      do_syscall_64+0x35/0xb0 arch/x86/entry/common.c:80
      entry_SYSCALL_64_after_hwframe+0x46/0xb0
      RIP: 0033:0x7f3baaa89109
      Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b8 ff ff ff f7 d8 64 89 01 48
      RSP: 002b:00007f3babba9168 EFLAGS: 00000246 ORIG_RAX: 000000000000002e
      RAX: ffffffffffffffda RBX: 00007f3baab9bf60 RCX: 00007f3baaa89109
      RDX: 0000000000000000 RSI: 0000000020000a00 RDI: 0000000000000003
      RBP: 00007f3baaae305d R08: 0000000000000000 R09: 0000000000000000
      R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
      R13: 00007ffe74f2543f R14: 00007f3babba9300 R15: 0000000000022000
      </TASK>
      
      Fixes: 4cb47a86 ("tunnels: PMTU discovery support for directly bridged IP packets")
      Reported-by: default avatarsyzbot <syzkaller@googlegroups.com>
      Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
      Cc: Stefano Brivio <sbrivio@redhat.com>
      Reviewed-by: default avatarStefano Brivio <sbrivio@redhat.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      853a7614
  10. Jun 24, 2022
  11. Jun 23, 2022
  12. Jun 21, 2022
Loading