lkml.org 
[lkml]   [2024]   [Dec]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH net-next v12 08/22] ovpn: implement basic RX path (UDP)
From
On 03/12/2024 15:34, Paolo Abeni wrote:
[...]
>> +static void ovpn_netdev_write(struct ovpn_peer *peer, struct sk_buff *skb)
>> +{
>> + unsigned int pkt_len;
>> + int ret;
>> +
>> + /* we can't guarantee the packet wasn't corrupted before entering the
>> + * VPN, therefore we give other layers a chance to check that
>> + */
>> + skb->ip_summed = CHECKSUM_NONE;
>> +
>> + /* skb hash for transport packet no longer valid after decapsulation */
>> + skb_clear_hash(skb);
>> +
>> + /* post-decrypt scrub -- prepare to inject encapsulated packet onto the
>> + * interface, based on __skb_tunnel_rx() in dst.h
>> + */
>> + skb->dev = peer->ovpn->dev;
>> + skb_set_queue_mapping(skb, 0);
>> + skb_scrub_packet(skb, true);
>> +
>> + skb_reset_network_header(skb);
>> + skb_reset_transport_header(skb);
>> + skb_probe_transport_header(skb);
>
> This is a no-op after the previous call. You should drop it.

Thanks Paolo, I'll drop it.

Regards,

--
Antonio Quartulli
OpenVPN Inc.


\
 
 \ /
  Last update: 2024-12-03 15:40    [from the cache]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and my Meterkast|Read the blog