From nobody Mon Dec 15 14:50:38 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) client-ip=8.43.85.245; envelope-from=devel-bounces@lists.libvirt.org; helo=lists.libvirt.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) smtp.mailfrom=devel-bounces@lists.libvirt.org; dmarc=pass(p=reject dis=none) header.from=lists.libvirt.org ARC-Seal: i=1; a=rsa-sha256; t=1742210614; cv=none; d=zohomail.com; s=zohoarc; b=DUn46pfk446h+jVib+Dpvc5WqzJvW7SPSnY93CCvTjY5Xop7KrdZukmtCE9fydtbypqXhP63+OdrU5BM4E7j+IOsWUgeXqHjmjMw3PqE//Xw0r3G02pEJ6uXeGO49usz627STNrBVh50Y3HoqDX7hFybx4cJLt505Dy1gcvMr+A= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1742210614; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:Reply-To:Subject:Subject:To:To:Message-Id; bh=Um7M7b0qhK75TbywPL1/VLNEE1Hl721qEGufU+zJhUA=; b=nOnSgWfbF5u7hwajAby3BHE9NYWUpoQ0YPviSs7AGQK83x00/OGHHwLlu+z1Qvw4tJGTFF42AKojCMpwhURaM8dwBLMD2skeCut7pxfIh41GLJBR0lHbAZNIXowtBoTHE82FRVKocUWwlBeM3RIMa/V4rXSCr+QW5LXGqXo1CnA= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of lists.libvirt.org designates 8.43.85.245 as permitted sender) smtp.mailfrom=devel-bounces@lists.libvirt.org; dmarc=pass header.from= (p=reject dis=none) Return-Path: Received: from lists.libvirt.org (lists.libvirt.org [8.43.85.245]) by mx.zohomail.com with SMTPS id 1742210614255385.05959065493664; Mon, 17 Mar 2025 04:23:34 -0700 (PDT) Received: by lists.libvirt.org (Postfix, from userid 996) id 313CE2341; Mon, 17 Mar 2025 07:23:33 -0400 (EDT) Received: from lists.libvirt.org (localhost [IPv6:::1]) by lists.libvirt.org (Postfix) with ESMTP id 992D72328; Mon, 17 Mar 2025 07:23:09 -0400 (EDT) Received: by lists.libvirt.org (Postfix, from userid 996) id 6ED7F2315; Mon, 17 Mar 2025 07:23:07 -0400 (EDT) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.libvirt.org (Postfix) with ESMTPS id CA10C231C for ; Mon, 17 Mar 2025 07:23:05 -0400 (EDT) Received: from mx-prod-mc-01.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-148-eUUZeiqYPn-K0mbaUmMlFA-1; Mon, 17 Mar 2025 07:23:04 -0400 Received: from mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-01.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id 3B00819560BD for ; Mon, 17 Mar 2025 11:23:03 +0000 (UTC) Received: from toolbx.redhat.com (unknown [10.42.28.27]) by mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id D05613001D12; Mon, 17 Mar 2025 11:23:01 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on lists.libvirt.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2, RCVD_IN_VALIDITY_RPBL_BLOCKED,RCVD_IN_VALIDITY_SAFE_BLOCKED, SPF_HELO_NONE autolearn=unavailable autolearn_force=no version=3.4.4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1742210585; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=6vC90XoL9jaOXC6hv7zA1sHZEY/CSfj/iJKAI7L6SGg=; b=gQOR0rrFOfztJ7QLj3GwlEG3XuYAgrwcoRnEcO8KfeIDUxzsPuI1qbONA2KPtfO3KMXY/z a+7q55WtzAF8TgLsFAqtueTV53D0qf+F2Ygkvv0sS45uW1IsU0qEBbDIyW2aYE6ASXflKn vD2BSaZjWxWIWifRPI9bc1aSs9Fs3bA= X-MC-Unique: eUUZeiqYPn-K0mbaUmMlFA-1 X-Mimecast-MFC-AGG-ID: eUUZeiqYPn-K0mbaUmMlFA_1742210583 To: devel@lists.libvirt.org Cc: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= Subject: [PATCH] docs: document workaround for DMARC countermeasures Date: Mon, 17 Mar 2025 11:23:00 +0000 Message-ID: <20250317112300.41440-1-berrange@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.30.177.4 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: 7X1dfVCYhWtTEMQfmrpjMHdXjpur36z7r0RWqmObY7U_1742210583 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable Message-ID-Hash: P46YITNEHTBZ4CGNY5IYCJXJAROG5AE3 X-Message-ID-Hash: P46YITNEHTBZ4CGNY5IYCJXJAROG5AE3 X-MailFrom: berrange@redhat.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-config-1; header-match-config-2; header-match-config-3; header-match-devel.lists.libvirt.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header X-Mailman-Version: 3.2.2 Precedence: list List-Id: Development discussions about the libvirt library & tools Archived-At: List-Archive: List-Help: List-Post: List-Subscribe: List-Unsubscribe: From: =?utf-8?q?Daniel_P=2E_Berrang=C3=A9_via_Devel?= Reply-To: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZM-MESSAGEID: 1742210617694019100 Content-Type: text/plain; charset="utf-8" From: Daniel P. Berrang=C3=A9 If a contributor's email domain has a DMARC policy of 'p=3Dquarantine' or 'p=3Dreject', mailman will apply DMARC countermeasures on all mails sent to lists.libvirt.org rewriting the "From" header to remove the sender's email address. e.g. From: Your Name via If these countermeasures were not applied, affected mail would either have gon directly to SPAM, or have been entirely rejected. Mailman3 is unable to be configured to guarantee no mangling of the mail body so these countermeasures are unavoidable for lists.libvirt.org. Amongst the various downsides, the From address rewriting has the bad effect of mangling git commit author attribution. To avoid this it is required to add two additional git config settings: $ git config --global format.from "Your Name " $ git config --global format.forceInBodyFrom true Note, *both* are required, even if your ``format.from`` matches your existing git identity, because the latter only takes effect once the former is set. Signed-off-by: Daniel P. Berrang=C3=A9 Reviewed-by: Jiri Denemark Reviewed-by: Laine Stump via Devel --- docs/submitting-patches.rst | 66 ++++++++++++++++++++++++++++--------- 1 file changed, 51 insertions(+), 15 deletions(-) diff --git a/docs/submitting-patches.rst b/docs/submitting-patches.rst index a5e108550a..b22e4e03b4 100644 --- a/docs/submitting-patches.rst +++ b/docs/submitting-patches.rst @@ -43,21 +43,7 @@ series of two or more patches needs a cover letter. Note that the ``git send-email`` subcommand may not be in the main git package and using it may require installation of a separate package, for example the "git-email" package in Fedora -and Debian. If this is your first time using -``git send-email``, you might need to configure it to point it -to your SMTP server with something like: - -:: - - $ git config --global sendemail.smtpServer stmp.youremailprovider.net - -If you get tired of typing ``--to=3Ddevel@lists.libvirt.org`` all -the time, you can configure that to be automatically handled as -well: - -:: - - $ git config sendemail.to devel@lists.libvirt.org +and Debian. =20 Avoid using mail clients for sending patches, as most of them will mangle the messages in some way, making them unusable for @@ -88,6 +74,56 @@ Moreover, such patch needs to be prefixed correctly with ``git send-email`` (substitute ``v2`` with the correct version if needed though). =20 +Git Configuration +----------------- + +If this is your first time using ``git send-email``, you will probably +need to setup your global git configuration, to point to your outgoing +SMTP server with something like: + +:: + + $ git config --global sendemail.smtpServer stmp.youremailprovider.net + +If your email provider (often your employer) has configured a DMARC +policy for their domain, there are some additional settings that will +be required. Before doing this, check the DMARC policy with + +:: + + $ host -t txt _dmarc.$YOURDOMAIN.COM + +If this returns no output, or contains ``p=3Dnone`` then no configuration +is required. If it reports ``p=3Dquarantine`` or ``p=3Dreject``, then the +libvirt lists will apply DMARC countermeasures to your email. To ensure +that git authorship is preserved add + +:: + + $ git config --global format.from "Your Name " + $ git config --global format.forceInBodyFrom true + +This will force git to always add an additional line + +:: + + From: Your Name + +in the body of the patch, guaranteeing correct author records even +when the main ``From`` header is rewritten by mailman. + +If you get tired of typing ``--to=3Ddevel@lists.libvirt.org`` all +the time, you can configure that to be automatically handled by +adding a local repository setting: + +:: + + $ git config sendemail.to devel@lists.libvirt.org + +This last setting is not required if using ``git-publish`` to send +patches, as that auto-identifies the mailing list address from its +config file stored in git. + Review process -------------- =20 --=20 2.48.1