On 01/04/2025 12:02, Sabrina Dubroca wrote:
2025-03-18, 02:40:46 +0100, Antonio Quartulli wrote:
+static void ovpn_tcp_rcv(struct strparser *strp, struct sk_buff *skb)
+{
[...]
+ /* we need the first byte of data to be accessible
nit: and "first byte" here too (that comment could maybe just be dropped?)
ACK.
Regards,
+ * to extract the opcode and the key ID later on
+ */
+ if (!pskb_may_pull(skb, OVPN_OPCODE_SIZE)) {
+ net_warn_ratelimited("%s: packet too small to fetch opcode for peer
%u\n",
+ netdev_name(peer->ovpn->dev), peer->id);
+ goto err;
+ }
--
Antonio Quartulli
OpenVPN Inc.