Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Register
  • Sign in
  • L linux
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • Deployments
    • Deployments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • Kirill Smelkov
  • linux
  • Repository
  • linux
  • include
  • net
  • ip.h
Find file BlameHistoryPermalink
  • Shmulik Ladkani's avatar
    ipv4: Fix ip_skb_dst_mtu to use the sk passed by ip_finish_output · fedbb6b4
    Shmulik Ladkani authored Jun 29, 2016
    ip_skb_dst_mtu uses skb->sk, assuming it is an AF_INET socket (e.g. it
    calls ip_sk_use_pmtu which casts sk as an inet_sk).
    
    However, in the case of UDP tunneling, the skb->sk is not necessarily an
    inet socket (could be AF_PACKET socket, or AF_UNSPEC if arriving from
    tun/tap).
    
    OTOH, the sk passed as an argument throughout IP stack's output path is
    the one which is of PMTU interest:
     - In case of local sockets, sk is same as skb->sk;
     - In case of a udp tunnel, sk is the tunneling socket.
    
    Fix, by passing ip_finish_output's sk to ip_skb_dst_mtu.
    This augments 7026b1dd
    
     'netfilter: Pass socket pointer down through okfn().'
    
    Signed-off-by: default avatarShmulik Ladkani <shmulik.ladkani@gmail.com>
    Reviewed-by: default avatarHannes Frederic Sowa <hannes@stressinduktion.org>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    fedbb6b4
GitLab Nexedi Edition | About GitLab | About Nexedi | 沪ICP备2021021310号-2 | 沪ICP备2021021310号-7