{"id":2229749,"url":"http://patchwork.ozlabs.org/api/1.1/patches/2229749/?format=json","web_url":"http://patchwork.ozlabs.org/project/linux-cifs-client/patch/20260428155542.226234-2-henrique.carvalho@suse.com/","project":{"id":12,"url":"http://patchwork.ozlabs.org/api/1.1/projects/12/?format=json","name":"Linux CIFS Client","link_name":"linux-cifs-client","list_id":"linux-cifs.vger.kernel.org","list_email":"linux-cifs@vger.kernel.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20260428155542.226234-2-henrique.carvalho@suse.com>","date":"2026-04-28T15:55:39","name":"[v2,01/11] smb: common: add smb_tls struct shared by client and server","commit_ref":null,"pull_url":null,"state":"new","archived":false,"hash":"8a14f4999a494e7109c8c52c4072cdc6e695c313","submitter":{"id":89563,"url":"http://patchwork.ozlabs.org/api/1.1/people/89563/?format=json","name":"Henrique Carvalho","email":"henrique.carvalho@suse.com"},"delegate":null,"mbox":"http://patchwork.ozlabs.org/project/linux-cifs-client/patch/20260428155542.226234-2-henrique.carvalho@suse.com/mbox/","series":[{"id":501886,"url":"http://patchwork.ozlabs.org/api/1.1/series/501886/?format=json","web_url":"http://patchwork.ozlabs.org/project/linux-cifs-client/list/?series=501886","date":"2026-04-28T15:55:41","name":"smb: implement SMB over QUIC","version":2,"mbox":"http://patchwork.ozlabs.org/series/501886/mbox/"}],"comments":"http://patchwork.ozlabs.org/api/patches/2229749/comments/","check":"pending","checks":"http://patchwork.ozlabs.org/api/patches/2229749/checks/","tags":{},"headers":{"Return-Path":"\n <linux-cifs+bounces-11227-incoming=patchwork.ozlabs.org@vger.kernel.org>","X-Original-To":["incoming@patchwork.ozlabs.org","linux-cifs@vger.kernel.org"],"Delivered-To":"patchwork-incoming@legolas.ozlabs.org","Authentication-Results":["legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n unprotected) header.d=suse.com header.i=@suse.com header.a=rsa-sha256\n header.s=google header.b=Y3kmdTXR;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org\n (client-ip=104.64.211.4; helo=sin.lore.kernel.org;\n envelope-from=linux-cifs+bounces-11227-incoming=patchwork.ozlabs.org@vger.kernel.org;\n receiver=patchwork.ozlabs.org)","smtp.subspace.kernel.org;\n\tdkim=pass (2048-bit key) header.d=suse.com header.i=@suse.com\n header.b=\"Y3kmdTXR\"","smtp.subspace.kernel.org;\n arc=none smtp.client-ip=209.85.128.48","smtp.subspace.kernel.org;\n dmarc=pass (p=quarantine dis=none) header.from=suse.com","smtp.subspace.kernel.org;\n spf=pass smtp.mailfrom=suse.com"],"Received":["from sin.lore.kernel.org (sin.lore.kernel.org [104.64.211.4])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4g4n250nG7z1xrS\n\tfor <incoming@patchwork.ozlabs.org>; Wed, 29 Apr 2026 03:08:13 +1000 (AEST)","from smtp.subspace.kernel.org (conduit.subspace.kernel.org\n [100.90.174.1])\n\tby sin.lore.kernel.org (Postfix) with ESMTP id 5E5ED3051C6B\n\tfor <incoming@patchwork.ozlabs.org>; Tue, 28 Apr 2026 15:56:03 +0000 (UTC)","from localhost.localdomain (localhost.localdomain [127.0.0.1])\n\tby smtp.subspace.kernel.org (Postfix) with ESMTP id 3B6103B38A6;\n\tTue, 28 Apr 2026 15:56:01 +0000 (UTC)","from mail-wm1-f48.google.com (mail-wm1-f48.google.com\n [209.85.128.48])\n\t(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))\n\t(No client certificate requested)\n\tby smtp.subspace.kernel.org (Postfix) with ESMTPS id A9ADB35A384\n\tfor <linux-cifs@vger.kernel.org>; Tue, 28 Apr 2026 15:55:59 +0000 (UTC)","by mail-wm1-f48.google.com with SMTP id\n 5b1f17b1804b1-4838c15e3cbso107646305e9.3\n        for <linux-cifs@vger.kernel.org>;\n Tue, 28 Apr 2026 08:55:59 -0700 (PDT)","from precision ([2a01:4b00:c007:bb00:be9d:a3c4:18b1:4a25])\n        by smtp.gmail.com with ESMTPSA id\n 5b1f17b1804b1-48a775f56fcsm23475685e9.25.2026.04.28.08.55.57\n        (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n        Tue, 28 Apr 2026 08:55:57 -0700 (PDT)"],"ARC-Seal":"i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116;\n\tt=1777391761; cv=none;\n b=HlX3nPAaYHENAandpeK6ZD5AqO6sNH/nBqxo/6YgHTjUmduyKrukyYKtTa1sWGs1ALvXwmYhwx4mgbO3oKdyCFVdL41LugojZgOfgdcuf+Vc9VuJyT78iOZz9vJaXxhsFw2xFU7C4211BiMYTF8q9Nl3Qx8mv3W+kbOEc9OVNuE=","ARC-Message-Signature":"i=1; a=rsa-sha256; d=subspace.kernel.org;\n\ts=arc-20240116; t=1777391761; c=relaxed/simple;\n\tbh=o9AxzB6iTIxvV3zczxNnobMq6mUvwYWWzYA0xI/jRJc=;\n\th=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References:\n\t MIME-Version;\n b=ck2C3m8w6NCw2S+qhmpOkHB9/Jh6MuV66e0m1k0M8X3hAOv9kMMCcE09HUUlZeTCbKagNNcruvmvfVVjqsz6NJcEN3NwdXmlXpl7b/YjldDnfykAXhoOT6AQnjgmvG/Jbq6TgpUGbToNSSB0T4Hi/Yi1bBWl9rHRNbeA+CTf4oM=","ARC-Authentication-Results":"i=1; smtp.subspace.kernel.org;\n dmarc=pass (p=quarantine dis=none) header.from=suse.com;\n spf=pass smtp.mailfrom=suse.com;\n dkim=pass (2048-bit key) header.d=suse.com header.i=@suse.com\n header.b=Y3kmdTXR; arc=none smtp.client-ip=209.85.128.48","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n        d=suse.com; s=google; t=1777391758; x=1777996558;\n darn=vger.kernel.org;\n        h=content-transfer-encoding:mime-version:references:in-reply-to\n         :message-id:date:subject:cc:to:from:from:to:cc:subject:date\n         :message-id:reply-to;\n        bh=HaDqba+Z9YUDbJcQeyPUHQc2cEFoh6ewPsWR4yOwgNI=;\n        b=Y3kmdTXRWvhZo/uEnjuw9CS1lYvLVxiXO336zVicZBJIsYpzaWqCfAW2WhMeEd/y3J\n         RqE9rOCzpV3xpxmpZiG0zX14m0VVk/MAfWHu1O2YH/27p9e8ls3lFwi4GABfYPSJhIB4\n         Wjd40u/PPw2cXTwzTDcIfVLcmdiWMv/gXpoGlwdTNukXi0CaRbL45+as/5ApYM9S7x38\n         Szl/5W47kdXupxZYpXNsdrj4/1chfy9qBMaMidzbtmiebml2HnGbcAsnqjKgILwB6LVH\n         FmmEemy8bjCct9ed1ElcRuj5wweOmeqyWACymaOxSHiSVup1GW8BgDdpj1/C5TIetGNZ\n         FXsg==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n        d=1e100.net; s=20251104; t=1777391758; x=1777996558;\n        h=content-transfer-encoding:mime-version:references:in-reply-to\n         :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from\n         :to:cc:subject:date:message-id:reply-to;\n        bh=HaDqba+Z9YUDbJcQeyPUHQc2cEFoh6ewPsWR4yOwgNI=;\n        b=nGto9tQIae7HdVUpZTmwr7w+FZK0aoQA16Xl0SO8OR2T4/5uf+3YESbUl1r0K7UxIy\n         V2vM4/XFETL5WQOyFu+DPqIIuwlwvvje8AHoGWSL8jfJgSI77qVg77xZegrae0DrCfvU\n         0F7rqV5eJQq7LW/HFYN8G1Tp2wTEmTuboS9e2Nv1jwIQpGeQ31hmwKIMaKpyBbcfSn9P\n         HNZICafW59jIfv0ziVX85Jj4KgKBslXyZf3+D2qkFhwAZSczWuXXqej6gIA9IwmZNC9A\n         +MLYLEGkj/wgnQuQlpWAKDDBKAOWw/zkRqc107IlOAwRxe8yEHRLa5PcsotKunjZrEDe\n         POIQ==","X-Gm-Message-State":"AOJu0Yymy5XZbAWUhDaCwWM36HghlPtDSngDovx7gPDUCpfjygePRJSB\n\tLQLnJAW2wultUw4nXnydOUuppy/XkDPdA+Gh3nww30BeGDxJBJQ3Fyldgi+Ux8TyjOOAC9W82ez\n\t8pgLGVvwP6w==","X-Gm-Gg":"AeBDiesWhtzQCcKLgN3Prgyx05PdXo69wsjilxxLukD9+lje3MSbcMwSN7WElu2ysGk\n\tbG7Ws1EQuxpYvCHtp0xoFwk236lR+MzGtcHxyhElu0W1LGjDEYRsphFMsitU0eKSYm6ZZa1kdq7\n\tiZ49QNo9k/Zwb0fD5vvlONpbeCZZtBQ+o/gK3/q7sjff3we66hxNwTeRqysLMxPo9YPVcEFk8y+\n\tERXTrjE4Z1I/lQ704H9pUS5BzyhMHQE9PaXz8A6WEzk77EjrSKfJOsfD/UYkic218Ktvw3kIMR5\n\tGrg4pkYE3GXazwyLeTM11SK3jNfmVCMUECSUGjJP2PiAnH5yh2kQSCuRvECl2FftO1010ceYrDh\n\t0LZr5HFxXTrDYxz29xxusGcBkbPfTXDPka5uIpp4F/O8dsmczJ+HCn+XvjFJh4K8/lfkLNcBcqR\n\tzGyRJsS5WwpZpdBgn7qwZ4SAC4gl2dYc+JQ1hD5zwH/CKx","X-Received":"by 2002:a05:600c:c091:b0:48a:58ae:9938 with SMTP id\n 5b1f17b1804b1-48a77b19957mr42724765e9.19.1777391757646;\n        Tue, 28 Apr 2026 08:55:57 -0700 (PDT)","From":"Henrique Carvalho <henrique.carvalho@suse.com>","To":"linux-cifs@vger.kernel.org","Cc":"sfrench@samba.org,\n\tlinkinjeon@kernel.org,\n\tmetze@samba.org,\n\tpc@manguebit.com,\n\tronniesahlberg@gmail.com,\n\tsprasad@microsoft.com,\n\ttom@talpey.com,\n\tbharathsm@microsoft.com,\n\tematsumiya@suse.de,\n\tHenrique Carvalho <henrique.carvalho@suse.com>","Subject":"[PATCH v2 01/11] smb: common: add smb_tls struct shared by client and\n server","Date":"Tue, 28 Apr 2026 12:55:39 -0300","Message-ID":"<20260428155542.226234-2-henrique.carvalho@suse.com>","X-Mailer":"git-send-email 2.53.0","In-Reply-To":"<20260428155542.226234-1-henrique.carvalho@suse.com>","References":"<20260428155542.226234-1-henrique.carvalho@suse.com>","Precedence":"bulk","X-Mailing-List":"linux-cifs@vger.kernel.org","List-Id":"<linux-cifs.vger.kernel.org>","List-Subscribe":"<mailto:linux-cifs+subscribe@vger.kernel.org>","List-Unsubscribe":"<mailto:linux-cifs+unsubscribe@vger.kernel.org>","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit"},"content":"Both the SMB client (mount path) and ksmbd server (accept path) need\nto drive a TLS handshake over their accepted/connected QUIC socket\nvia the kernel handshake API.\n\nPull the small bit of state shared between the two callers - the\ncompletion, status and peerid populated by the handshake callback,\nand the tls_handshake_args structure passed to\ntls_{client,server}_hello_x509() - into one common header in\nfs/smb/common/smbglob.h.\n\nDefine SMB_TLS_TIMEOUT_MS (3000) here as well so client and server\nagree on the handshake timeout.\n\nSigned-off-by: Henrique Carvalho <henrique.carvalho@suse.com>\n---\n fs/smb/common/smbglob.h | 12 ++++++++++++\n 1 file changed, 12 insertions(+)","diff":"diff --git a/fs/smb/common/smbglob.h b/fs/smb/common/smbglob.h\nindex 4e33d91cdc9d..a08d804af0ed 100644\n--- a/fs/smb/common/smbglob.h\n+++ b/fs/smb/common/smbglob.h\n@@ -11,6 +11,9 @@\n #ifndef _COMMON_SMB_GLOB_H\n #define _COMMON_SMB_GLOB_H\n \n+#include <net/sock.h>\n+#include <net/handshake.h>\n+\n struct smb_version_values {\n \tchar\t\t*version_string;\n \t__u16\t\tprotocol_id;\n@@ -66,4 +69,13 @@ static inline void inc_rfc1001_len(void *buf, int count)\n \n #define MAX_CIFS_SMALL_BUFFER_SIZE 448 /* big enough for most */\n \n+struct smb_tls {\n+\tstruct completion handshake_done;\n+\tint status;\n+\tkey_serial_t peerid;\n+\tstruct tls_handshake_args args;\n+};\n+\n+#define SMB_TLS_TIMEOUT_MS 3000\n+\n #endif\t/* _COMMON_SMB_GLOB_H */\n","prefixes":["v2","01/11"]}