From ba3fe6dff1d2dbf1cb4d3c383acad57e40f79367 Mon Sep 17 00:00:00 2001
Message-Id: <ba3fe6dff1d2dbf1cb4d3c383acad57e40f79367.1668793140.git.peter@polidoro.io>
From: Peter Polidoro <peter@polidoro.io>
Date: Fri, 18 Nov 2022 12:38:06 -0500
Subject: [PATCH] gnu: Add cyrus-sasl-xoauth2.
* gnu/packages/cyrus-sasl.scm (cyrus-sasl-xoauth2): New variable.
---
gnu/packages/cyrus-sasl.scm | 30 ++++++++++++++++++++++++++++++
1 file changed, 30 insertions(+)
@@ -3,6 +3,7 @@
;;; Copyright © 2013 Andreas Enge <andreas@enge.fr>
;;; Copyright © 2016 Leo Famulari <leo@famulari.name>
;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com>
+;;; Copyright © 2022 Peter Polidoro <peter@polidoro.io>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -28,6 +29,7 @@ (define-module (gnu packages cyrus-sasl)
#:use-module ((guix licenses) #:prefix license:)
#:use-module (guix packages)
#:use-module (guix download)
+ #:use-module (guix git-download)
#:use-module (guix build-system gnu))
(define-public cyrus-sasl
@@ -78,3 +80,31 @@ (define-public cyrus-sasl
(license (license:non-copyleft "file://COPYING"
"See COPYING in the distribution."))
(home-page "https://cyrusimap.org/sasl/")))
+
+(define-public cyrus-sasl-xoauth2
+ (package
+ (name "cyrus-sasl-xoauth2")
+ (version "0.2")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/moriyoshi/cyrus-sasl-xoauth2")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1py9f1mn5k5xihrk0lfrwr6723c22gjb7lmgya83ibvislm2x3wl"))))
+ (build-system gnu-build-system)
+ (arguments
+ '(#:configure-flags (list (string-append "--with-cyrus-sasl="
+ (assoc-ref %outputs "out")))))
+ (native-inputs (list autoconf automake libtool))
+ (inputs (list cyrus-sasl))
+ (home-page "https://github.com/moriyoshi/cyrus-sasl-xoauth2")
+ (synopsis "XOAUTH2 mechanism plugin for cyrus-sasl")
+ (description "This package adds the Open Authorization standard, OAuth2,
+authentication mechanism to cyrus-sasl as a plugin. OAuth is an open standard
+for access delegation, commonly used as a way for internet users to grant
+websites or applications access to their information on other websites but
+without giving them the passwords.")
+ (license (list license:expat license:expat))))
--
2.38.1