From patchwork Mon Mar 11 11:59:52 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Carlo Zancanaro X-Patchwork-Id: 61666 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 7916227BBE9; Mon, 11 Mar 2024 12:01:10 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 50DC427BBE2 for ; Mon, 11 Mar 2024 12:01:09 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rjeKU-0002S1-Rs; Mon, 11 Mar 2024 08:00:30 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rjeKS-0002Lw-Hv for guix-patches@gnu.org; Mon, 11 Mar 2024 08:00:28 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rjeKS-0004a2-54 for guix-patches@gnu.org; Mon, 11 Mar 2024 08:00:28 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rjeKz-000724-Pz for guix-patches@gnu.org; Mon, 11 Mar 2024 08:01:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#69731] [PATCH 1/2] gnu: services: Add insecure-sasl-mechanisms to prosody configuration. Resent-From: Carlo Zancanaro Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 11 Mar 2024 12:01:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 69731 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 69731@debbugs.gnu.org Cc: Liliana Marie Prikler Received: via spool by 69731-submit@debbugs.gnu.org id=B69731.171015844326976 (code B ref 69731); Mon, 11 Mar 2024 12:01:01 +0000 Received: (at 69731) by debbugs.gnu.org; 11 Mar 2024 12:00:43 +0000 Received: from localhost ([127.0.0.1]:39168 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rjeKg-00070z-Hu for submit@debbugs.gnu.org; Mon, 11 Mar 2024 08:00:43 -0400 Received: from voltorb.zancanaro.id.au ([45.77.50.64]:37114) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rjeKc-00070b-Hn for 69731@debbugs.gnu.org; Mon, 11 Mar 2024 08:00:40 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; s=k1; bh=Q/yxkhDSUQ8FV4E W6ofqdgAYDCVSaFYlLB7/Po8a3FQ=; h=references:in-reply-to:date:subject: cc:to:from; d=zancanaro.id.au; b=e/nojJSl0+MmGMn4B7EtlPQ9m96Qjx+7U0UxN gTVT71mEBUk+yJUOB+0OGVhpUVjrlNJXldcj/Gq5V7DWNc/Praw9R/gNEbuQzVzBLxDCyZ dsoynLfObmMQTi8bOuOnFljnApb4gyEZ34Ab7syUztE4Ghc6w/LSJn2ZyDGm197o= Received: by voltorb.zancanaro.id.au (OpenSMTPD) with ESMTPSA id f7fdbd10 (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO); Mon, 11 Mar 2024 11:59:53 +0000 (UTC) From: Carlo Zancanaro Date: Mon, 11 Mar 2024 22:59:52 +1100 Message-ID: <2f7f7780814bd69a270087f0edf0071f453bdc5d.1710157873.git.carlo@zancanaro.id.au> X-Mailer: git-send-email 2.41.0 In-Reply-To: References: MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * gnu/services/messaging.scm (prosody-configuration): Add insecure-sasl-mechanisms configuration option. * doc/guix.texi (Messaging Services): Document it. Change-Id: I8d9e42476ea8ad2f89b143ed4a66b4798e418586 --- doc/guix.texi | 12 +++++++++--- gnu/services/messaging.scm | 6 ++++++ 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/doc/guix.texi b/doc/guix.texi index 858d5751bf..d9b55b3c1f 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -28551,6 +28551,12 @@ Messaging Services Defaults to @samp{'("DIGEST-MD5")}. @end deftypevr +@deftypevr {@code{prosody-configuration} parameter} string-list insecure-sasl-mechanisms +Set of mechanisms that will not be offered on unencrypted connections. +See @url{https://prosody.im/doc/modules/mod_saslauth}. +Defaults to @samp{'("PLAIN" "LOGIN")}. +@end deftypevr + @deftypevr {@code{prosody-configuration} parameter} boolean s2s-require-encryption? Whether to force all server-to-server connections to be encrypted or not. See @url{https://prosody.im/doc/modules/mod_tls}. @@ -28630,7 +28636,7 @@ Messaging Services Available @code{virtualhost-configuration} fields are: -all these @code{prosody-configuration} fields: @code{admins}, @code{use-libevent?}, @code{modules-enabled}, @code{modules-disabled}, @code{groups-file}, @code{allow-registration?}, @code{ssl}, @code{c2s-require-encryption?}, @code{disable-sasl-mechanisms}, @code{s2s-require-encryption?}, @code{s2s-secure-auth?}, @code{s2s-insecure-domains}, @code{s2s-secure-domains}, @code{authentication}, @code{log}, @code{http-max-content-size}, @code{http-external-url}, @code{raw-content}, plus: +all these @code{prosody-configuration} fields: @code{admins}, @code{use-libevent?}, @code{modules-enabled}, @code{modules-disabled}, @code{groups-file}, @code{allow-registration?}, @code{ssl}, @code{c2s-require-encryption?}, @code{disable-sasl-mechanisms}, @code{insecure-sasl-mechanisms}, @code{s2s-require-encryption?}, @code{s2s-secure-auth?}, @code{s2s-insecure-domains}, @code{s2s-secure-domains}, @code{authentication}, @code{log}, @code{http-max-content-size}, @code{http-external-url}, @code{raw-content}, plus: @deftypevr {@code{virtualhost-configuration} parameter} string domain Domain you wish Prosody to serve. @end deftypevr @@ -28652,7 +28658,7 @@ Messaging Services Available @code{int-component-configuration} fields are: -all these @code{prosody-configuration} fields: @code{admins}, @code{use-libevent?}, @code{modules-enabled}, @code{modules-disabled}, @code{groups-file}, @code{allow-registration?}, @code{ssl}, @code{c2s-require-encryption?}, @code{disable-sasl-mechanisms}, @code{s2s-require-encryption?}, @code{s2s-secure-auth?}, @code{s2s-insecure-domains}, @code{s2s-secure-domains}, @code{authentication}, @code{log}, @code{http-max-content-size}, @code{http-external-url}, @code{raw-content}, plus: +all these @code{prosody-configuration} fields: @code{admins}, @code{use-libevent?}, @code{modules-enabled}, @code{modules-disabled}, @code{groups-file}, @code{allow-registration?}, @code{ssl}, @code{c2s-require-encryption?}, @code{disable-sasl-mechanisms}, @code{insecure-sasl-mechanisms}, @code{s2s-require-encryption?}, @code{s2s-secure-auth?}, @code{s2s-insecure-domains}, @code{s2s-secure-domains}, @code{authentication}, @code{log}, @code{http-max-content-size}, @code{http-external-url}, @code{raw-content}, plus: @deftypevr {@code{int-component-configuration} parameter} string hostname Hostname of the component. @end deftypevr @@ -28705,7 +28711,7 @@ Messaging Services Available @code{ext-component-configuration} fields are: -all these @code{prosody-configuration} fields: @code{admins}, @code{use-libevent?}, @code{modules-enabled}, @code{modules-disabled}, @code{groups-file}, @code{allow-registration?}, @code{ssl}, @code{c2s-require-encryption?}, @code{disable-sasl-mechanisms}, @code{s2s-require-encryption?}, @code{s2s-secure-auth?}, @code{s2s-insecure-domains}, @code{s2s-secure-domains}, @code{authentication}, @code{log}, @code{http-max-content-size}, @code{http-external-url}, @code{raw-content}, plus: +all these @code{prosody-configuration} fields: @code{admins}, @code{use-libevent?}, @code{modules-enabled}, @code{modules-disabled}, @code{groups-file}, @code{allow-registration?}, @code{ssl}, @code{c2s-require-encryption?}, @code{disable-sasl-mechanisms}, @code{insecure-sasl-mechanisms}, @code{s2s-require-encryption?}, @code{s2s-secure-auth?}, @code{s2s-insecure-domains}, @code{s2s-secure-domains}, @code{authentication}, @code{log}, @code{http-max-content-size}, @code{http-external-url}, @code{raw-content}, plus: @deftypevr {@code{ext-component-configuration} parameter} string component-secret Password which the component will use to log in. @end deftypevr diff --git a/gnu/services/messaging.scm b/gnu/services/messaging.scm index 9702170b3e..a914d0f89e 100644 --- a/gnu/services/messaging.scm +++ b/gnu/services/messaging.scm @@ -427,6 +427,12 @@ (define %default-modules-enabled @url{https://prosody.im/doc/modules/mod_saslauth}." common) + (insecure-sasl-mechanisms + (string-list '("PLAIN" "LOGIN")) + "Set of mechanisms that will not be offered on unencrypted connections. +See @url{https://prosody.im/doc/modules/mod_saslauth}." + common) + (s2s-require-encryption? (boolean #f) "Whether to force all server-to-server connections to be encrypted or not. From patchwork Mon Mar 11 11:59:53 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Carlo Zancanaro X-Patchwork-Id: 61665 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 3AD6C27BBE9; Mon, 11 Mar 2024 12:01:09 +0000 (GMT) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id F314C27BBE2 for ; Mon, 11 Mar 2024 12:01:06 +0000 (GMT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rjeKY-0002VN-3u; Mon, 11 Mar 2024 08:00:34 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rjeKS-0002M8-Pw for guix-patches@gnu.org; Mon, 11 Mar 2024 08:00:28 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rjeKS-0004aD-FF for guix-patches@gnu.org; Mon, 11 Mar 2024 08:00:28 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rjeL0-00072C-8X for guix-patches@gnu.org; Mon, 11 Mar 2024 08:01:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#69731] [PATCH 2/2] gnu: tests: Fix prosody system test. Resent-From: Carlo Zancanaro Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Mon, 11 Mar 2024 12:01:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 69731 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 69731@debbugs.gnu.org Cc: Liliana Marie Prikler Received: via spool by 69731-submit@debbugs.gnu.org id=B69731.171015844426984 (code B ref 69731); Mon, 11 Mar 2024 12:01:02 +0000 Received: (at 69731) by debbugs.gnu.org; 11 Mar 2024 12:00:44 +0000 Received: from localhost ([127.0.0.1]:39170 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rjeKi-00071A-Bq for submit@debbugs.gnu.org; Mon, 11 Mar 2024 08:00:44 -0400 Received: from voltorb.zancanaro.id.au ([45.77.50.64]:37114) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rjeKf-00070b-9q for 69731@debbugs.gnu.org; Mon, 11 Mar 2024 08:00:42 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; s=k1; bh=Y04ZFme1CscrwLc 6OXwnTfmq3wtmqpkc3QYx4EJ14KI=; h=references:in-reply-to:date:subject: cc:to:from; d=zancanaro.id.au; b=HQGaug4cB+6sNtDmprfDFOD87ZmpTMqdxEYNp CjMkJdE5jIhKDdLojEseTH2jT9HGuxlPp5lT85asZ6kakXJ4I6X4SqTFt6HyDZyB6O7K5T EWYlhbQmtGDg1fkXkPuo9Zr1v7L+cs8lituZe4Yuv11ePP6I8vOv9bQQGgQpJEnQ= Received: by voltorb.zancanaro.id.au (OpenSMTPD) with ESMTPSA id 16f52c4b (TLSv1.3:TLS_AES_256_GCM_SHA384:256:NO); Mon, 11 Mar 2024 11:59:53 +0000 (UTC) From: Carlo Zancanaro Date: Mon, 11 Mar 2024 22:59:53 +1100 Message-ID: X-Mailer: git-send-email 2.41.0 In-Reply-To: References: MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches The test was failing because the sasl module no longer accepts PLAIN auth on insecure connections. * gnu/tests/messaging.scm (%test-prosody): Configure test prosody to allow all auth types on insecure connections. Change-Id: I142f3b6ccbdde4bdde86ce0698fea7d5509fc200 --- gnu/tests/messaging.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gnu/tests/messaging.scm b/gnu/tests/messaging.scm index 1e26c0ddea..dfcc92f7ed 100644 --- a/gnu/tests/messaging.scm +++ b/gnu/tests/messaging.scm @@ -145,7 +145,7 @@ (define %create-prosody-account (define %test-prosody (let* ((config (prosody-configuration - (disable-sasl-mechanisms '()) + (insecure-sasl-mechanisms '()) (virtualhosts (list (virtualhost-configuration