From owner-svn-src-all@freebsd.org Tue Aug 20 00:50:18 2019 Return-Path: Delivered-To: svn-src-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 3956FD6782; Tue, 20 Aug 2019 00:50:18 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 46CBzG0ZCDz4f6R; Tue, 20 Aug 2019 00:50:18 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id E4FA22303A; Tue, 20 Aug 2019 00:50:17 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id x7K0oHJD055832; Tue, 20 Aug 2019 00:50:17 GMT (envelope-from jhb@FreeBSD.org) Received: (from jhb@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id x7K0oH4v055829; Tue, 20 Aug 2019 00:50:17 GMT (envelope-from jhb@FreeBSD.org) Message-Id: <201908200050.x7K0oH4v055829@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhb set sender to jhb@FreeBSD.org using -f From: John Baldwin Date: Tue, 20 Aug 2019 00:50:17 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-12@freebsd.org Subject: svn commit: r351243 - in stable: 11/sys/kgssapi/krb5 12/sys/kgssapi/krb5 X-SVN-Group: stable-12 X-SVN-Commit-Author: jhb X-SVN-Commit-Paths: in stable: 11/sys/kgssapi/krb5 12/sys/kgssapi/krb5 X-SVN-Commit-Revision: 351243 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 20 Aug 2019 00:50:18 -0000 Author: jhb Date: Tue Aug 20 00:50:17 2019 New Revision: 351243 URL: https://svnweb.freebsd.org/changeset/base/351243 Log: MFC 348875: Add warnings for Kerberos GSS algorithms deprecated in RFCs 6649 and 8429. All of these algorithms are explicitly marked SHOULD NOT in one of these RFCs. Specifically, RFC 6649 deprecates all algorithms using DES as well as the "export-friendly" variant of RC4. RFC 8429 deprecates Triple DES and the remaining RC4 algorithms. Relnotes: yes Modified: stable/12/sys/kgssapi/krb5/kcrypto_arcfour.c stable/12/sys/kgssapi/krb5/kcrypto_des.c stable/12/sys/kgssapi/krb5/kcrypto_des3.c Directory Properties: stable/12/ (props changed) Changes in other areas also in this revision: Modified: stable/11/sys/kgssapi/krb5/kcrypto_arcfour.c stable/11/sys/kgssapi/krb5/kcrypto_des.c stable/11/sys/kgssapi/krb5/kcrypto_des3.c Directory Properties: stable/11/ (props changed) Modified: stable/12/sys/kgssapi/krb5/kcrypto_arcfour.c ============================================================================== --- stable/12/sys/kgssapi/krb5/kcrypto_arcfour.c Mon Aug 19 23:57:37 2019 (r351242) +++ stable/12/sys/kgssapi/krb5/kcrypto_arcfour.c Tue Aug 20 00:50:17 2019 (r351243) @@ -46,8 +46,12 @@ __FBSDID("$FreeBSD$"); static void arcfour_init(struct krb5_key_state *ks) { + static struct timeval lastwarn; + static struct timeval warninterval = { .tv_sec = 3600, .tv_usec = 0 }; ks->ks_priv = NULL; + if (ratecheck(&lastwarn, &warninterval)) + gone_in(13, "RC4 cipher for Kerberos GSS"); } static void Modified: stable/12/sys/kgssapi/krb5/kcrypto_des.c ============================================================================== --- stable/12/sys/kgssapi/krb5/kcrypto_des.c Mon Aug 19 23:57:37 2019 (r351242) +++ stable/12/sys/kgssapi/krb5/kcrypto_des.c Tue Aug 20 00:50:17 2019 (r351243) @@ -53,11 +53,15 @@ struct des1_state { static void des1_init(struct krb5_key_state *ks) { + static struct timeval lastwarn; + static struct timeval warninterval = { .tv_sec = 3600, .tv_usec = 0 }; struct des1_state *ds; ds = malloc(sizeof(struct des1_state), M_GSSAPI, M_WAITOK|M_ZERO); mtx_init(&ds->ds_lock, "gss des lock", NULL, MTX_DEF); ks->ks_priv = ds; + if (ratecheck(&lastwarn, &warninterval)) + gone_in(13, "DES cipher for Kerberos GSS"); } static void Modified: stable/12/sys/kgssapi/krb5/kcrypto_des3.c ============================================================================== --- stable/12/sys/kgssapi/krb5/kcrypto_des3.c Mon Aug 19 23:57:37 2019 (r351242) +++ stable/12/sys/kgssapi/krb5/kcrypto_des3.c Tue Aug 20 00:50:17 2019 (r351243) @@ -54,11 +54,15 @@ struct des3_state { static void des3_init(struct krb5_key_state *ks) { + static struct timeval lastwarn; + static struct timeval warninterval = { .tv_sec = 3600, .tv_usec = 0 }; struct des3_state *ds; ds = malloc(sizeof(struct des3_state), M_GSSAPI, M_WAITOK|M_ZERO); mtx_init(&ds->ds_lock, "gss des3 lock", NULL, MTX_DEF); ks->ks_priv = ds; + if (ratecheck(&lastwarn, &warninterval)) + gone_in(13, "DES3 cipher for Kerberos GSS"); } static void