;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020 Ludovic Courtès ;;; Copyright © 2014, 2015, 2017, 2020 Mark H Weaver ;;; Copyright © 2014 Ian Denhardt ;;; Copyright © 2014 Sou Bunnbu ;;; Copyright © 2014, 2019 Julien Lepiller ;;; Copyright © 2015 Taylan Ulrich Bayırlı/Kammer ;;; Copyright © 2015 Paul van der Walt ;;; Copyright © 2015, 2016, 2018 Eric Bavier ;;; Copyright © 2015 Andreas Enge ;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Efraim Flashner ;;; Copyright © 2016 Christopher Allan Webber ;;; Copyright © 2016 Al McElrath ;;; Copyright © 2016 Leo Famulari ;;; Copyright © 2016 Lukas Gradl ;;; Copyright © 2016 Alex Kost ;;; Copyright © 2016, 2017 Troy Sankey ;;; Copyright © 2016, 2017, 2018 Nikita ;;; Copyright © 2016 Clément Lassieur ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Arun Isaac ;;; Copyright © 2016 John Darrington ;;; Copyright © 2016, 2018 Marius Bakke ;;; Copyright © 2017 Thomas Danckaert ;;; Copyright © 2017 Kyle Meyer ;;; Copyright © 2017–2021 Tobias Geerinckx-Rice ;;; Copyright © 2017, 2018, 2020 Rene Saavedra ;;; Copyright © 2018, 2019, 2020, 2021 Pierre Langlois ;;; Copyright © 2018 Alex Vong ;;; Copyright © 2018 Gábor Boskovits ;;; Copyright © 2018, 2019, 2020 Ricardo Wurmus ;;; Copyright © 2019, 2020 Ta
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2015 Paul van der Walt <paul@denknerd.org>
;;; Copyright © 2015, 2016, 2017, 2018 Ricardo Wurmus <rekado@elephly.net>
;;; Copyright © 2015 Federico Beffa <beffa@fbengineering.ch>
;;; Copyright © 2016 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2017 rsiddharth <s@ricketyspace.net>
;;; Copyright © 2017 Tobias Geerinckx-Rice <me@tobias.gr>
;;; Copyright © 2019 Robert Vollmert <rob@vllmrt.net>
;;; Copyright © 2019 John Soo <jsoo1@asu.edu>
;;; Copyright © 2020 Alexandru-Sergiu Marton <brown121407@gmail.com>
;;; Copyright © 2020 Marius Bakke <marius@gnu.org>
;;; Copyright © 2020, 2022 Kyle Meyer <kyle@kyleam.com>
;;; Copyright © 2020 Alexandru-Sergiu Marton <brown121407@member.fsf.org>
;;; Copyright © 2020 Giacomo Leidi <goodoldpaul@autistici.org>
;;; Copyright © 2022 Alice Brenon <alice.brenon@ens-lyon.fr>
;;;
;;; This file is part of GNU Guix.
;;;
;;; GNU Guix is free software; you can redistribute it and/or modify it
;;; under the terms of the GNU General Public License as published by
;;; the Free Software Foundation; either version 3 of the License, or (at
;;; your option) any later version.
;;;
;;; GNU Guix is distributed in the hope that it will be useful, but
;;; WITHOUT ANY WARRANTY; without even the implied warranty of
;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
;;; GNU General Public License for more details.
;;;
;;; You should have received a copy of the GNU General Public License
;;; along with GNU Guix.  If not, see <http://www.gnu.org/licenses/>.

(define-module (gnu packages haskell-web)
  #:use-module (gnu packages)
  #:use-module (gnu packages curl)
  #:use-module (gnu packages haskell)
  #:use-module (gnu packages haskell-check)
  #:use-module (gnu packages haskell-crypto)
  #:use-module (gnu packages haskell-xyz)
  #:use-module (guix build-system haskell)
  #:use-module (guix download)
  #:use-module ((guix licenses) #:prefix license:)
  #:use-module (guix packages)
  #:use-module (guix utils))

(define-public ghc-tagsoup
  (package
    (name "ghc-tagsoup")
    (version "0.14.8")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "tagsoup" version))
       (sha256
        (base32
         "1m9sx6gr9y9yxvkmcap8xsks8cnhznvma1mrfl39zljkv005azms"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "tagsoup")))
    (native-inputs
     (list ghc-quickcheck))
    (home-page "https://github.com/ndmitchell/tagsoup")
    (synopsis
     "Parsing and extracting information from (possibly malformed) HTML/XML
documents")
    (description
     "TagSoup is a library for parsing HTML/XML.  It supports the HTML 5
specification, and can be used to parse either well-formed XML, or
unstructured and malformed HTML from the web.  The library also provides
useful functions to extract information from an HTML document, making it ideal
for screen-scraping.")
    (license license:bsd-3)))

(define-public ghc-cookie
  (package
    (name "ghc-cookie")
    (version "0.4.6")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "cookie" version))
       (sha256
        (base32 "1ajbcsk4k0jc6v2fqn36scs6l8wa6fq46gd54pak75rbqdbajhcc"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "cookie")))
    (inputs (list ghc-data-default-class))
    (native-inputs (list ghc-hunit ghc-quickcheck ghc-tasty ghc-tasty-hunit
                         ghc-tasty-quickcheck))
    (home-page "https://github.com/snoyberg/cookie")
    (synopsis "HTTP cookie parsing and rendering")
    (description "HTTP cookie parsing and rendering library for Haskell.")
    (license license:expat)))

(define-public ghc-crypton-connection
  (package
    (name "ghc-crypton-connection")
    (version "0.3.2")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "crypton-connection" version))
       (sha256
        (base32 "07lrkv6lwphsyp4797yp8ywnndzd270bk58r8gwyby0hr4xy52r0"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "crypton-connection")))
    (inputs (list ghc-basement
                  ghc-data-default-class
                  ghc-network
                  ghc-tls-1.9
                  ghc-socks
                  ghc-crypton-x509
                  ghc-crypton-x509-store
                  ghc-crypton-x509-system
                  ghc-crypton-x509-validation))
    (home-page "https://github.com/kazu-yamamoto/crypton-connection")
    (synopsis "Simple and easy network connections API")
    (description
     "This package provides a simple network library for all your connection
needs.  Features: Really simple to use, SSL/TLS, SOCKS.  This library provides
a very simple API to create sockets to a destination with the choice of
SSL/TLS, and SOCKS.")
    (license license:bsd-3)))

(define-public ghc-curl
  (package
    (name "ghc-curl")
    (version "1.3.8")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "curl" version))
              (sha256
               (base32
                "0vj4hpaa30jz7c702xpsfvqaqdxz28zslsqnsfx6bf6dpwvck1wh"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "curl")))
    (inputs
     (list curl))
    (home-page "https://hackage.haskell.org/package/curl")
    (synopsis "Haskell bindings for libcurl")
    (description
     "@code{libcurl} is a versatile client-side URL transfer library.
This package provides a Haskell binding to libcurl.")
    (license license:bsd-3)))

(define-public ghc-httpd-shed
  (package
    (name "ghc-httpd-shed")
    (version "0.4.1.1")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "httpd-shed" version))
       (sha256
        (base32
         "19dgdimpzr7pxk7pqvyin6j87gmvnf0rm35gzhmna8qr835wy3sr"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "httpd-shed")))
    (inputs
     (list ghc-network-bsd ghc-network-uri ghc-network))
    (home-page "https://hackage.haskell.org/package/httpd-shed")
    (synopsis "Simple web-server with an interact style API")
    (description
     "This web server promotes a function from @code{Request} to @code{IO
Response} into a local web server.  The user can decide how to interpret the
requests, and the library is intended for implementing Ajax APIs.")
    (license license:bsd-3)))

(define-public ghc-http-types
  (package
    (name "ghc-http-types")
    (version "0.12.3")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "http-types" version))
       (sha256
        (base32
         "05j00b9nqmwh9zaq9y9x50k81v2pd3j7a71kd91zlnbl8xk4m2jf"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "http-types")))
    (native-inputs
     (list ghc-doctest ghc-hspec ghc-quickcheck ghc-quickcheck-instances
           hspec-discover))
    (inputs
     (list ghc-case-insensitive))
    (home-page "https://github.com/aristidb/http-types")
    (synopsis "Generic HTTP types for Haskell")
    (description "This package provides generic HTTP types for Haskell (for
both client and server code).")
    (license license:bsd-3)))

(define-public ghc-http
  (package
    (name "ghc-http")
    (version "4000.4.1")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "HTTP" version))
              (sha256
               (base32
                "0lyl5lpkk51xn3dfndh8ksgvwcdsviyigmsnp3d28lbpxkpxhcfz"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "HTTP")))
    (inputs (list ghc-network ghc-network-uri))
    (native-inputs (list ghc-httpd-shed
                         ghc-hunit
                         ghc-puremd5
                         ghc-split
                         ghc-test-framework
                         ghc-test-framework-hunit))
    (arguments
     `(#:tests? #f ; Tests fail due to missing /etc/protocols?
       #:cabal-revision ("1"
                         "04y04vbxbnblpmqqmpl8km4bkcjaj96nbxkssdr1zgbhqisxay5q")))
    (home-page "https://github.com/haskell/HTTP")
    (synopsis "Library for client-side HTTP")
    (description
     "The HTTP package supports client-side web programming in Haskell.  It
lets you set up HTTP connections, transmitting requests and processing the
responses coming back.")
    (license license:bsd-3)))

(define-public ghc-http-client
  (package
    (name "ghc-http-client")
    (version "0.7.13.1")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "http-client" version))
              (sha256
               (base32
                "09qfmakjk285jz2rnb53c1m9c764fg8vngfq43ipga1g72h8d3n9"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "http-client")))
    (inputs (list ghc-http-types
                  ghc-blaze-builder
                  ghc-network
                  ghc-streaming-commons
                  ghc-case-insensitive
                  ghc-base64-bytestring
                  ghc-cookie
                  ghc-random
                  ghc-mime-types
                  ghc-iproute
                  ghc-async
                  ghc-network-uri))
    (native-inputs (list ghc-hspec
                         ghc-monad-control
                         ghc-zlib
                         ghc-hspec
                         ghc-monad-control
                         ghc-zlib
                         hspec-discover))
    (arguments (list #:tests? #f)) ; Tests try to access httpbin.org.
    (home-page "https://github.com/snoyberg/http-client")
    (synopsis "HTTP client engine")
    (description
     "This package provides an HTTP client engine, intended as a base layer
for more user-friendly packages.")
    (license license:expat)))

(define-public ghc-http-client-tls
  (package
    (name "ghc-http-client-tls")
    (version "0.3.6.1")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "http-client-tls" version))
              (sha256
               (base32
                "03f8p9gxdzl6slyw1r6vpv2dqhsyjvbaawbjv75kaq0vlj3gz7xi"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "http-client-tls")))
    ;; Tests require Internet access
    (arguments `(#:tests? #f))
    (inputs
     (list ghc-data-default-class
           ghc-http-client
           ghc-connection
           ghc-network
           ghc-tls
           ghc-http-types))
    (native-inputs
     (list ghc-hspec))
    (home-page "https://github.com/snoyberg/http-client")
    (synopsis "Backend for http-client using the TLS library")
    (description
     "This package provides a backend for the http-client package using the
connection and TLS libraries.  It is intended for use by higher-level
libraries, such as http-conduit.")
    (license license:expat)))

(define-public ghc-http-client-restricted
  (package
    (name "ghc-http-client-restricted")
    (version "0.0.5")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "http-client-restricted" version))
       (sha256
        (base32 "1vfm9qc3zr0rmq2ddgyg13i67020cdk8xqhyzfc2zcn1km2p6r85"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "http-client-restricted")))
    (inputs
     (list ghc-http-client
           ghc-http-client-tls
           ghc-connection
           ghc-data-default
           ghc-network
           ghc-network-bsd
           ghc-utf8-string))
    (home-page "https://hackage.haskell.org/package/http-client-restricted")
    (synopsis "Restrict the servers used by http-client")
    (description
     "This library makes it possible to restrict the HTTP servers that can be
used by the @code{http-client} and @code{http-client-tls} libraries.  This is
useful when a security policy needs to, e.g., prevent connections to HTTP
servers on localhost or only allow connections to a specific server.")
    (license license:expat)))

(define-public ghc-http-date
  (package
    (name "ghc-http-date")
    (version "0.0.11")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "http-date" version))
       (sha256
        (base32
         "1lzlrj2flcnz3k5kfhf11nk5n8m6kcya0lkwrsnzxgfr3an27y9j"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "http-date")))
    (inputs
     (list ghc-attoparsec))
    (native-inputs
     (list ghc-doctest ghc-hspec hspec-discover ghc-old-locale))
    (home-page "https://github.com/kazu-yamamoto/http-date")
    (synopsis "HTTP Date parser/formatter")
    (description "Library for Parsing and formatting HTTP
Date in Haskell.")
    (license license:bsd-3)))

(define-public ghc-http2
  (package
    (name "ghc-http2")
    (version "3.0.3")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "http2" version))
              (sha256
               (base32
                "1kv99i3pnnx31xndlkaczrpd2j5mvzbqlfz1kaw6cwlwkdnl5bhv"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "http2")))
    (inputs (list ghc-async
                  ghc-case-insensitive
                  ghc-http-types
                  ghc-network
                  ghc-network-byte-order
                  ghc-psqueues
                  ghc-time-manager
                  ghc-unix-time
                  ghc-network-run
                  ghc-cryptonite
                  ghc-aeson
                  ghc-aeson-pretty
                  ghc-base16-bytestring
                  ghc-unordered-containers
                  ghc-vector
                  ghc-word8))
    (native-inputs (list ghc-doctest
                         ghc-hspec
                         ghc-typed-process
                         ghc-hspec
                         ghc-typed-process
                         ghc-hspec
                         ghc-glob
                         ghc-hspec
                         hspec-discover))
    (home-page "https://github.com/kazu-yamamoto/http2")
    (synopsis "HTTP/2 library including frames, priority queues and HPACK")
    (description
     "This package provides a HTTP/2.0 library including frames
and HPACK.  Currently HTTP/2 16 framing and HPACK 10 is supported.")
    (license license:bsd-3)))

(define-public ghc-http-conduit
  (package
    (name "ghc-http-conduit")
    (version "2.3.8.1")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "http-conduit" version))
       (sha256
        (base32 "11zf4hyw8f1gpj0w1cmgc9g62xwy2v4hhzqazdsla4q49iqbzxgd"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "http-conduit")))
    (inputs (list ghc-attoparsec
                  ghc-resourcet
                  ghc-conduit
                  ghc-conduit-extra
                  ghc-http-types
                  ghc-http-client
                  ghc-http-client-tls
                  ghc-unliftio-core
                  ghc-aeson))
    (native-inputs (list ghc-hunit
                         ghc-hspec
                         ghc-data-default-class
                         ghc-warp-tls
                         ghc-tls
                         ghc-blaze-builder
                         ghc-utf8-string
                         ghc-case-insensitive
                         ghc-unliftio
                         ghc-wai
                         ghc-warp
                         ghc-wai-conduit
                         ghc-cookie
                         ghc-streaming-commons
                         ghc-temporary
                         ghc-network))
    (arguments
     `(#:cabal-revision ("1"
                         "1wvr0v948s5fmlf47r4pqjan355x6v65rm7dz7y65ngj10xwk5f9")
       #:phases
       (modify-phases %standard-phases
         (add-before 'configure 'update-constraints
           (lambda _
             (substitute* "http-conduit.cabal"
               ((", network") ", network\n                 , connection\n")))))))
    (home-page "https://github.com/snoyberg/http-client")
    (synopsis "HTTP/HTTPS client with conduit interface")
    (description
     "This library uses attoparsec for parsing the actual
contents of the HTTP connection.  It also provides higher-level functions
which allow you to avoid direct usage of conduits.")
    (license license:bsd-3)))

(define-public ghc-http-reverse-proxy
  (package
    (name "ghc-http-reverse-proxy")
    (version "0.6.0.1")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "http-reverse-proxy" version))
              (sha256
               (base32
                "0a0fc9rqr1crbb1sbq3gzbkwjcfff662d4bgmy3vzspk7ky697ld"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "http-reverse-proxy")))
    (inputs (list ghc-case-insensitive
                  ghc-http-types
                  ghc-word8
                  ghc-blaze-builder
                  ghc-http-client
                  ghc-wai
                  ghc-network
                  ghc-conduit
                  ghc-conduit-extra
                  ghc-wai-logger
                  ghc-resourcet
                  ghc-unliftio
                  ghc-streaming-commons))
    (native-inputs (list ghc-hspec ghc-warp ghc-http-conduit))
    (home-page "https://github.com/fpco/http-reverse-proxy")
    (synopsis
     "Reverse proxy HTTP requests, either over raw sockets or with WAI")
    (description
     "Provides a simple means of reverse-proxying HTTP requests.  The raw
approach uses the same technique as leveraged by keter, whereas the WAI
approach performs full request/response parsing via WAI and http-conduit.")
    (license license:bsd-3)))

(define-public ghc-wai
  (package
    (name "ghc-wai")
    (version "3.2.3")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "wai" version))
       (sha256
        (base32
         "1y19h9v0cq1fl17ywcyyvd6419fhgyw2s0yk0ki8z60021adcx2m"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "wai")))
    (inputs
     (list ghc-bytestring-builder
           ghc-unix-compat
           ghc-vault
           ghc-blaze-builder
           ghc-network
           ghc-http-types))
    (native-inputs
     (list hspec-discover ghc-quickcheck ghc-hunit ghc-hspec))
    (home-page "https://hackage.haskell.org/package/wai")
    (synopsis "Web application interface for Haskell")
    (description "This package provides a Web Application Interface (WAI)
library for the Haskell language.  It defines a common protocol for
communication between web applications and web servers.")
    (license license:bsd-3)))

(define-public ghc-wai-logger
  (package
    (name "ghc-wai-logger")
    (version "2.4.0")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "wai-logger" version))
       (sha256
        (base32
         "02i9jsy5gdglqwwk5gcvax8y498lz9flrfp4v9nrv8rmrmd66zh5"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "wai-logger")))
    (arguments `(#:tests? #f)) ; FIXME: Tests cannot find libraries exported
                               ; by propagated-inputs.
    (inputs
     (list ghc-auto-update
           ghc-byteorder
           ghc-easy-file
           ghc-unix-time
           ghc-blaze-builder
           ghc-case-insensitive
           ghc-fast-logger
           ghc-http-types
           ghc-network
           ghc-wai))
    (home-page "https://hackage.haskell.org/package/wai-logger")
    (synopsis "Logging system for WAI")
    (description "This package provides the logging system for WAI.")
    (license license:bsd-3)))

(define-public ghc-wai-extra
  (package
    (name "ghc-wai-extra")
    (version "3.1.13.0")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "wai-extra" version))
              (sha256
               (base32
                "1h4cqd5akrq0vhv3l0fzryy7qw0c2jb58lngx7x8ij63bckjs3fz"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "wai-extra")))
    (inputs (list ghc-aeson
                  ghc-ansi-terminal
                  ghc-base64-bytestring
                  ghc-call-stack
                  ghc-case-insensitive
                  ghc-cookie
                  ghc-data-default-class
                  ghc-fast-logger
                  ghc-http-types
                  ghc-hunit
                  ghc-iproute
                  ghc-network
                  ghc-resourcet
                  ghc-streaming-commons
                  ghc-vault
                  ghc-wai
                  ghc-wai-logger
                  ghc-warp
                  ghc-word8))
    (native-inputs (list ghc-hspec ghc-temporary ghc-zlib hspec-discover))
    (arguments
     `(#:cabal-revision ("1"
                         "0dyvg2bb37im790757khncxpnf45451dd8575p736ry4g8rpqgpw")))
    (home-page "http://github.com/yesodweb/wai")
    (synopsis "Some basic WAI handlers and middleware")
    (description "This library provides basic WAI handlers and middleware
functionality.")
    (license license:expat)))

(define-public ghc-wai-conduit
  (package
    (name "ghc-wai-conduit")
    (version "3.0.0.4")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "wai-conduit" version))
       (sha256
        (base32
         "07yn41rn2skd5p3wqqa09wa761vj7ibl8l19gh4bi4i8slxhk417"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "wai-conduit")))
    (inputs
     (list ghc-conduit ghc-http-types ghc-wai ghc-blaze-builder))
    (home-page "https://github.com/yesodweb/wai")
    (synopsis "Conduit wrappers for Haskell's WAI")
    (description "This package provides data streaming abstraction for
Haskell's Web Application Interface (WAI).")
    (license license:expat)))

(define-public ghc-bsb-http-chunked
  (package
    (name "ghc-bsb-http-chunked")
    (version "0.0.0.4")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "bsb-http-chunked" version))
       (sha256
        (base32
         "0z0f18yc6zlwh29c6175ivfcin325lvi4irpvv0n3cmq7vi0k0ql"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "bsb-http-chunked")))
    (arguments
     `(#:tests? #f ; Tests fail: Variable not in scope.
       #:cabal-revision
       ("3" "15hg352id2f4x0dnvv47bdiz6gv5hp5a2mki9yzmhc7ajpk31mdd")))
    (native-inputs
     (list ghc-attoparsec
           ghc-blaze-builder
           ghc-hedgehog
           ghc-tasty
           ghc-tasty-hedgehog
           ghc-tasty-hunit
           ghc-doctest))
    (home-page "https://github.com/sjakobi/bsb-http-chunked")
    (synopsis "Chunked HTTP transfer encoding for bytestring builders")
    (description "This Haskell library contains functions for encoding
bytestring builders for chunked Hypertext Transfer Protocol (HTTP) 1.1
transfers.")
    (license license:bsd-3)))

(define-public ghc-warp
  (package
    (name "ghc-warp")
    (version "3.3.23")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "warp" version))
       (sha256
        (base32 "0y1r7czq5zrgklqrx1b9pmxn5lhmf7zpqdjz7hfmnzsmr3vndmms"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "warp")))
    (inputs
     (list ghc-async
           ghc-auto-update
           ghc-bsb-http-chunked
           ghc-case-insensitive
           ghc-hashable
           ghc-http-types
           ghc-iproute
           ghc-network
           ghc-streaming-commons
           ghc-time-manager
           ghc-unix-compat
           ghc-vault
           ghc-wai
           ghc-word8
           ghc-http-date
           ghc-simple-sendfile
           ghc-unliftio
           ghc-x509
           ghc-http2
           ghc-recv))
    (native-inputs
     (list curl
           ghc-silently
           ghc-hspec
           ghc-doctest
           ghc-lifted-base
           ghc-quickcheck
           ghc-hunit
           ghc-http-client
           hspec-discover))
    (home-page "https://github.com/yesodweb/wai")
    (synopsis "HTTP server library for Haskell's WAI")
    (description "Warp is a server library for HTTP/1.x and HTTP/2
based WAI (Web Application Interface in Haskell).")
    (license license:expat)))

(define-public ghc-tls-session-manager
  (package
  (name "ghc-tls-session-manager")
  (version "0.0.4")
  (source
    (origin
      (method url-fetch)
      (uri (hackage-uri "tls-session-manager" version))
      (sha256
        (base32
          "134kb5nz668f4xrr5g98g7fc1bwb3ri6q433a1i6asjkniwpy85s"))))
  (build-system haskell-build-system)
  (properties '((upstream-name . "tls-session-manager")))
  (inputs
    (list ghc-auto-update ghc-clock ghc-psqueues ghc-tls))
  (home-page "https://hackage.haskell.org/package/tls-session-manager")
  (synopsis "In-memory TLS session manager")
  (description "This Haskell library provides a TLS session manager with
limitation, automatic pruning, energy saving and replay resistance.")
  (license license:bsd-3)))

(define-public ghc-warp-tls
  (package
    (name "ghc-warp-tls")
    (version "3.3.4")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "warp-tls" version))
              (sha256
               (base32
                "00vgs9v7k0fapl05knqii9g47svf4lapb7ixkll7xr4zvmkk0r0m"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "warp-tls")))
    (inputs (list ghc-wai
                  ghc-warp
                  ghc-data-default-class
                  ghc-tls
                  ghc-cryptonite
                  ghc-network
                  ghc-streaming-commons
                  ghc-tls-session-manager
                  ghc-unliftio))
    (home-page "http://github.com/yesodweb/wai")
    (synopsis "SSL/TLS support for Warp")
    (description "This package provides SSL/TLS support for Warp,
a WAI handler, via the native Haskell TLS implementation.")
    (license license:expat)))

(define-public ghc-websockets
  (package
    (name "ghc-websockets")
    (version "0.12.7.3")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "websockets" version))
              (sha256
               (base32
                "0g3z0n4irf3gvbdf9p97jq05ybdg0gwjy5bj4nfc7ivsvyhaic6k"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "websockets")))
    (inputs (list ghc-async
                  ghc-attoparsec
                  ghc-base64-bytestring
                  ghc-bytestring-builder
                  ghc-case-insensitive
                  ghc-clock
                  ghc-network
                  ghc-random
                  ghc-sha
                  ghc-streaming-commons
                  ghc-entropy))
    (native-inputs (list ghc-hunit ghc-quickcheck ghc-test-framework
                         ghc-test-framework-hunit
                         ghc-test-framework-quickcheck2))
    (arguments
     `(#:cabal-revision ("1"
                         "1yx97y6jl74vy200y43vjxfyzx338kh10dx8vxkjhr0mfh36wldq")))
    (home-page "http://jaspervdj.be/websockets")
    (synopsis "Write WebSocket-capable servers in Haskell")
    (description
     "This library allows you to write WebSocket-capable servers.

An example server:
@url{https://github.com/jaspervdj/websockets/blob/master/example/server.lhs}
An example client:
@url{https://github.com/jaspervdj/websockets/blob/master/example/client.hs}

See also:
@itemize
@item The specification of the WebSocket protocol:
@url{http://www.whatwg.org/specs/web-socket-protocol/}
@item The JavaScript API for dealing with WebSockets:
@url{http://www.w3.org/TR/websockets/}
@end itemize")
    (license license:bsd-3)))

(define-public ghc-wai-websockets
  (package
    (name "ghc-wai-websockets")
    (version "3.0.1.2")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "wai-websockets" version))
       (sha256
        (base32
         "0b2xmdsrsqpssyib53wbr6r8hf75789ndyyanv37sv99iyqcwz4i"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "wai-websockets")))
    (inputs
     (list ghc-wai ghc-case-insensitive ghc-network ghc-websockets
           ghc-http-types))
    (arguments
     `(#:configure-flags '("--flags=-example")))
    (home-page "https://github.com/yesodweb/wai")
    (synopsis
     "Provide a bridge between WAI and the websockets package")
    (description
     "Use websockets with WAI applications, primarily those hosted via Warp.")
    (license license:expat)))

(define-public ghc-xss-sanitize
  (package
    (name "ghc-xss-sanitize")
    (version "0.3.7.2")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "xss-sanitize" version))
       (sha256
        (base32 "0in9kn51i2ddh5c8scyf9l8zi6zxidwznn34qwj02nglw5dpzfqv"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "xss-sanitize")))
    (inputs (list ghc-attoparsec ghc-css-text ghc-network-uri ghc-tagsoup
                  ghc-utf8-string))
    (native-inputs (list ghc-hunit ghc-hspec))
    (arguments
     `(#:cabal-revision ("1"
                         "1l8y52nja9a2iyxawm3vp23jcs46ziwx0yj2w46drb7knaa306d0")))
    (home-page "https://github.com/yesodweb/haskell-xss-sanitize#readme")
    (synopsis "Sanitize untrusted HTML to prevent XSS attacks")
    (description
     "This library provides @code{sanitizeXSS}.  Run untrusted
HTML through @code{Text.HTML.SanitizeXSS.sanitizeXSS} to prevent XSS
attacks.")
    (license license:bsd-2)))

(define-public ghc-css-text
  (package
    (name "ghc-css-text")
    (version "0.1.3.0")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "css-text" version))
       (sha256
        (base32
         "0ynd9f4hn2sfwqzbsa0y7phmxq8za7jiblpjwx0ry8b372zhgxaz"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "css-text")))
    (inputs
     (list ghc-attoparsec ghc-hspec ghc-quickcheck))
    (home-page "https://www.yesodweb.com/")
    (synopsis "CSS parser and renderer")
    (description "This package provides a CSS parser and renderer for
Haskell.")
    (license license:bsd-3)))

(define-public ghc-mattermost-api
  (package
    (name "ghc-mattermost-api")
    (version "90000.0.0")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "mattermost-api" version))
       (sha256
        (base32 "1ka3r4bnfwlbjnkws8vkg8i9gj8wzsyss137p7hxrx4sr75s6iyv"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "mattermost-api")))
    (inputs (list ghc-websockets
                  ghc-aeson
                  ghc-crypton-connection
                  ghc-memory
                  ghc-resource-pool
                  ghc-http
                  ghc-http-media
                  ghc-network-uri
                  ghc-modern-uri
                  ghc-unordered-containers
                  ghc-hashable
                  ghc-gitrev
                  ghc-microlens
                  ghc-microlens-th
                  ghc-pretty-show
                  ghc-split
                  ghc-connection))
    (native-inputs (list ghc-tasty ghc-tasty-hunit ghc-hunit))
    (arguments
     (list #:tests? #f)) ;tests require networking and Mattermost Docker image
    (home-page "https://hackage.haskell.org/package/mattermost-api")
    (synopsis "Client API for Mattermost chat system")
    (description
     "This package implements the client API for the Mattermost chat system.
Mattermost is a flexible messaging platform.  This library provides network
API interaction with the Mattermost server.")
    (license license:bsd-3)))

(define-public ghc-mattermost-api-qc
  (package
    (name "ghc-mattermost-api-qc")
    (version "90000.0.0")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "mattermost-api-qc" version))
       (sha256
        (base32 "0lrb8l8nbrdp4y2ala8hchr8ikv5hqw710ffiiw1sz6z2dqiqbxm"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "mattermost-api-qc")))
    (inputs (list ghc-mattermost-api ghc-quickcheck))
    (home-page "https://github.com/matterhorn-chat/mattermost-api-qc")
    (synopsis "QuickCheck instances for the Mattermost client API library")
    (description
     "This package provides a library providing @code{QuickCheck} for the
mattermost-api library to allow testing.  This is provided as a separate
library to allow use of the API library without testing dependencies.")
    (license license:isc)))

(define-public ghc-mime-types
  (package
    (name "ghc-mime-types")
    (version "0.1.0.9")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "mime-types" version))
              (sha256
               (base32
                "1lkipa4v73z3l5lqs6sdhl898iq41kyxv2jb9agsajzgd58l6cha"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "mime-types")))
    (home-page "https://github.com/yesodweb/wai")
    (synopsis "Basic MIME type handling types and functions")
    (description
     "This library provides basic MIME type handling types and functions.")
    (license license:expat)))

(define-public ghc-modern-uri
  (package
    (name "ghc-modern-uri")
    (version "0.3.6.1")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "modern-uri" version))
       (sha256
        (base32 "1sag8l91qd7xs56rlx8r6dz9zxxmqsnfw0v47az7l8nirv7zjih2"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "modern-uri")))
    (inputs (list ghc-quickcheck
                  ghc-hashable
                  ghc-megaparsec
                  ghc-profunctors
                  ghc-reflection
                  ghc-tagged))
    (native-inputs (list ghc-hspec
                         ghc-hspec-megaparsec
                         ghc-hspec-discover))
    (arguments
     `(#:cabal-revision ("1"
                         "0c0mr8aqs963nmy7i8yfih24snaijgwkxim2q2khw12capshac0q")))
    (home-page "https://github.com/mrkkrp/modern-uri")
    (synopsis "Library for working with URIs")
    (description "This is a library for working with URIs in Haskell as
per RFC 3986.")
    (license license:bsd-3)))

(define-public ghc-html
  (package
    (name "ghc-html")
    (version "1.0.1.2")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "html" version))
       (sha256
        (base32
         "0q9hmfii62kc82ijlg238fxrzxhsivn42x5wd6ffcr9xldg4jd8c"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "html")))
    (home-page
     "https://hackage.haskell.org/package/html")
    (synopsis "HTML combinator library")
    (description
     "This package contains a combinator library for constructing HTML
documents.")
    (license license:bsd-3)))

(define-public ghc-html-conduit
  (package
    (name "ghc-html-conduit")
    (version "1.3.2.2")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "html-conduit" version))
       (sha256
        (base32
         "09bwrdam3y47kqllgg6w098ghqb8jb10dp4wxirsvx5ddpx9zpi6"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "html-conduit")))
    (inputs
     (list ghc-resourcet
           ghc-conduit
           ghc-xml-conduit
           ghc-xml-types
           ghc-attoparsec
           ghc-conduit-extra))
    (native-inputs
     (list ghc-hspec ghc-hunit))
    (home-page "https://github.com/snoyberg/xml")
    (synopsis "Parse HTML documents using xml-conduit datatypes")
    (description
     "This package provides a parser for HTML documents that uses
tagstream-conduit.  It automatically balances mismatched tags, so that
there shouldn't be any parse failures.  It does not handle a full HTML
document rendering, such as adding missing html and head tags.  Note that,
since version 1.3.1, it uses an inlined copy of tagstream-conduit with
entity decoding bugfixes applied.")
    (license license:expat)))

(define-public ghc-blaze-html
  (package
    (name "ghc-blaze-html")
    (version "0.9.1.2")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "blaze-html" version))
       (sha256
        (base32
         "0k1r1hddjgqighazcazxrx6xfhvy2gm8il8l82ainv3cai13yl30"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "blaze-html")))
    (arguments
     `(#:tests? #f ; TODO: Depends on quickcheck<2.14
       #:cabal-revision
       ("1" "0wvlfb3rd9cm3p894p5rl9kggrsr5da3n8x9ydrbagx91yvkxns9")))
    (inputs
     (list ghc-blaze-builder ghc-blaze-markup))
    (native-inputs
     (list ghc-hunit ghc-quickcheck ghc-test-framework
           ghc-test-framework-hunit ghc-test-framework-quickcheck2))
    (home-page "https://jaspervdj.be/blaze")
    (synopsis "Fast HTML combinator library")
    (description "This library provides HTML combinators for Haskell.")
    (license license:bsd-3)))

(define-public ghc-aeson
  (package
    (name "ghc-aeson")
    (version "2.0.3.0")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "aeson" version))
              (sha256
               (base32
                "09dk0j33n262dm75vff3y3i9fm6lh06dyqswwv7a6kvnhhmhlxhr"))
              (patches (search-patches "ghc-aeson-encodeDouble.patch"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "aeson")))
    (inputs (list ghc-base-compat-batteries
                  ghc-time-compat
                  ghc-attoparsec
                  ghc-data-fix
                  ghc-dlist
                  ghc-hashable
                  ghc-indexed-traversable
                  ghc-onetuple
                  ghc-primitive
                  ghc-quickcheck
                  ghc-scientific
                  ghc-semialign
                  ghc-strict
                  ghc-tagged
                  ghc-text-short
                  ghc-th-abstraction
                  ghc-these
                  ghc-unordered-containers
                  ghc-uuid-types
                  ghc-vector
                  ghc-witherable))
    (native-inputs (list ghc-base-compat
                         ghc-base-orphans
                         ghc-base16-bytestring
                         ghc-diff
                         ghc-generic-deriving
                         ghc-integer-logarithms
                         ghc-quickcheck-instances
                         ghc-tasty
                         ghc-tasty-golden
                         ghc-tasty-hunit
                         ghc-tasty-quickcheck))
    (arguments
     `(#:cabal-revision ("1"
                         "1zrgn63jzrpk3n3vd44zkzgw7kb5qxlvhx4nk6g3sswwrsz5j32i")))
    (home-page "https://github.com/haskell/aeson")
    (synopsis "Fast JSON parsing and encoding")
    (description
     "This package provides a JSON parsing and encoding library
for Haskell, optimized for ease of use and high performance.  (A note on
naming: in Greek mythology, Aeson was the father of Jason.)")
    (license license:bsd-3)))

(define-public ghc-aeson-pretty
  (package
    (name "ghc-aeson-pretty")
    (version "0.8.9")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "aeson-pretty" version))
              (sha256
               (base32
                "021az9az6xik9c9s3rnar5fr1lgy2h3igibf5ixnc7ps3m2lzg2x"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "aeson-pretty")))
    (inputs
     (list ghc-aeson
           ghc-base-compat
           ghc-scientific
           ghc-vector
           ghc-unordered-containers
           ghc-attoparsec
           ghc-cmdargs))
    (home-page "https://github.com/informatikr/aeson-pretty")
    (synopsis "JSON pretty-printing library and command-line tool")
    (description
     "This package provides a JSON pretty-printing library compatible with aeson
as well as a command-line tool to improve readability of streams of JSON data.
The library provides the function @code{encodePretty}.  It is a drop-in
replacement for aeson's @code{encode} function, producing JSON-ByteStrings for
human readers.  The command-line tool reads JSON from stdin and writes
prettified JSON to stdout.  It also offers a complementary \"compact\"-mode,
essentially the opposite of pretty-printing.")
    (license license:bsd-3)))

(define-public ghc-aeson-qq
  (package
    (name "ghc-aeson-qq")
    (version "0.8.4")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "aeson-qq" version))
              (sha256
               (base32
                "0dpklq2xdhrkg1rdc7zfdjnzm6c3qxx2i1xskrqdxpqi84ffnlyh"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "aeson-qq")))
    (inputs
     (list ghc-base-compat
           ghc-attoparsec
           ghc-scientific
           ghc-vector
           ghc-aeson
           ghc-haskell-src-meta))
    (native-inputs
     (list ghc-hspec hspec-discover))
    (home-page "https://github.com/zalora/aeson-qq")
    (synopsis "JSON quasiquoter for Haskell")
    (description
     "aeson-qq provides a JSON quasiquoter for Haskell.  This package exposes
the function @code{aesonQQ} that compile-time converts a string representation
of a JSON value into a @code{Data.Aeson.Value}.")
    (license license:expat)))

(define-public ghc-aeson-better-errors
  (package
    (name "ghc-aeson-better-errors")
    (version "0.9.1.1")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "aeson-better-errors" version))
              (sha256
               (base32
                "05yibq9kqbjb8rh84n12sbax05amvd8jccpja0hyadz58pjy4jnk"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "aeson-better-errors")))
    (inputs (list ghc-aeson
                  ghc-unordered-containers
                  ghc-dlist
                  ghc-scientific
                  ghc-vector
                  ghc-transformers-compat
                  ghc-void))
    (arguments
     `(#:cabal-revision ("1"
                         "0wzvrmhn5q2x1mcv43cyxhlck815ldkhx7c7gz5ijjyva1iicgn2")))
    (home-page "https://github.com/hdgarrood/aeson-better-errors")
    (synopsis "Better error messages when decoding JSON values in Haskell")
    (description
     "Gives you the tools to build parsers to decode JSON values, and gives
good error messages when parsing fails.  See also
@url{http://harry.garrood.me/blog/aeson-better-errors/}.")
    (license license:expat)))

(define-public ghc-multipart
  (package
    (name "ghc-multipart")
    (version "0.2.1")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "multipart" version))
       (sha256
        (base32
         "0p6n4knxpjv70nbl6cmd6x7gkdjsjqp4ya7fz00bfrqp7jvhlivn"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "multipart")))
    (inputs
     (list ghc-stringsearch))
    (arguments
     `(#:cabal-revision ("1"
                         "03gaapwnvn843hpm5qwdci9df1wf383msd42p8w9ghilpfjj4qy9")))
    (home-page
     "http://www.github.com/silkapp/multipart")
    (synopsis
     "HTTP multipart library")
    (description
     "HTTP multipart split out of the cgi package, for Haskell.")
    (license license:bsd-3)))

(define-public ghc-uri-encode
  (package
    (name "ghc-uri-encode")
    (version "1.5.0.7")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "uri-encode" version))
       (sha256
        (base32
         "0lj2h701af12539p957rw24bxr07mfqd5r4h52i42f43ax165767"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "uri-encode")))
    (inputs
     (list ghc-utf8-string ghc-network-uri))
    (arguments
     `(#:cabal-revision ("2"
                         "03pmvbi56gmg1z2wr3glncc7dbyh666bqp565inh31qzsp9zwmgj")))
    (home-page "https://hackage.haskell.org/package/uri-encode")
    (synopsis "Unicode aware uri-encoding")
    (description "Unicode aware uri-encoding for Haskell.")
    (license license:bsd-3)))

(define-public ghc-path-pieces
  (package
    (name "ghc-path-pieces")
    (version "0.2.1")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "path-pieces" version))
       (sha256
        (base32
         "0vx3sivcsld76058925hym2j6hm3g71f0qjr7v59f1g2afgx82q8"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "path-pieces")))
    (native-inputs (list ghc-hunit ghc-hspec ghc-quickcheck))
    (home-page "https://github.com/yesodweb/path-pieces")
    (synopsis "Used in Yesod to automatically marshall data in the request path")
    (description  "This Haskell package provides two typeclasses for converting
Haskell data types to and from route pieces.")
    (license license:bsd-3)))

(define-public ghc-skein
  (package
    (name "ghc-skein")
    (version "1.0.9.4")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "skein" version))
       (sha256
        (base32
         "1jdqdk0rz2wnvw735clnj8jh0a9rkrbqjg7vk3w6wczdql6cm0pq"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "skein")))
    (inputs (list ghc-cereal ghc-tagged ghc-crypto-api))
    (native-inputs (list ghc-hspec))
    (home-page "https://github.com/yesodweb/path-pieces")
    (synopsis "Skein family of cryptographic hash functions for Haskell")
    (description "@uref{(http://www.skein-hash.info, Skein} is a family of
fast secure cryptographic hash functions designed by Niels Ferguson, Stefan
Lucks, Bruce Schneier, Doug Whiting, Mihir Bellare, Tadayoshi Kohno, Jon
Callas and Jesse Walker.

This Haskell package uses bindings to the optimized C implementation of Skein.")
    (license license:bsd-3)))

(define-public ghc-clientsession
  (package
    (name "ghc-clientsession")
    (version "0.9.1.2")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "clientsession" version))
       (sha256
        (base32
         "0s6h4ykj16mpf7nlw2iqn2ji0p8g1fn5ni0s7yqaili6vv2as5ar"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "clientsession")))
    (inputs (list ghc-cereal
                  ghc-tagged
                  ghc-crypto-api
                  ghc-skein
                  ghc-base64-bytestring
                  ghc-entropy
                  ghc-cprng-aes
                  ghc-cipher-aes
                  ghc-crypto-random
                  ghc-setenv))
    (native-inputs (list ghc-hunit ghc-hspec ghc-quickcheck))
    (home-page "https://github.com/yesodweb/clientsession/tree/master")
    (synopsis "Haskell library for securely store session data in a
client-side cookie")
    (description "This Haskell package achieves security through AES-CTR
encryption and Skein-MAC-512-256 authentication.  Uses Base64 encoding to
avoid any issues with characters.")
    (license license:expat)))

(define-public ghc-yesod-core
  (package
    (name "ghc-yesod-core")
    (version "1.6.24.2")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "yesod-core" version))
       (sha256
        (base32 "0cql4gk83ya0lyv0nyrp387nljpab4dwwy288rzp8klq9z5r2a7j"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "yesod-core")))
    (inputs (list ghc-aeson
                  ghc-auto-update
                  ghc-blaze-html
                  ghc-blaze-markup
                  ghc-case-insensitive
                  ghc-cereal
                  ghc-clientsession
                  ghc-conduit
                  ghc-conduit-extra
                  ghc-cookie
                  ghc-entropy
                  ghc-fast-logger
                  ghc-http-types
                  ghc-memory
                  ghc-monad-logger
                  ghc-path-pieces
                  ghc-primitive
                  ghc-random
                  ghc-resourcet
                  ghc-shakespeare
                  ghc-unix-compat
                  ghc-unliftio
                  ghc-unordered-containers
                  ghc-vector
                  ghc-wai
                  ghc-wai-extra
                  ghc-wai-logger
                  ghc-warp
                  ghc-word8))
    (native-inputs (list ghc-hspec
                         ghc-hunit
                         ghc-async
                         ghc-hspec
                         ghc-hspec-expectations
                         ghc-network
                         ghc-streaming-commons))
    (home-page "http://www.yesodweb.com/")
    (synopsis "Core package for the Yesod web framework")
    (description
     "This Haskell package provides all core functionality, for
Yesod, on which other packages can be built.  It provides dispatch, handler
functions, widgets, etc.")
    (license license:expat)))

(define-public ghc-yesod-persistent
  (package
    (name "ghc-yesod-persistent")
    (version "1.6.0.8")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "yesod-persistent" version))
              (sha256
               (base32
                "02vm0qm0yxqn6x61iir81wf6ibwnf8gkia8lw71fgpxgav154ig6"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "yesod-persistent")))
    (inputs (list ghc-yesod-core
                  ghc-persistent
                  ghc-persistent-template
                  ghc-blaze-builder
                  ghc-conduit
                  ghc-resourcet
                  ghc-resource-pool))
    (native-inputs (list ghc-hspec ghc-wai-extra ghc-persistent-sqlite
                         hspec-discover))
    (home-page "http://www.yesodweb.com/")
    (synopsis "Helpers for using Persistent from Yesod")
    (description "This Haskell package provides helpers for using Persistent
from Yesod.")
    (license license:expat)))

(define-public ghc-yesod-form
    (package
      (name "ghc-yesod-form")
      (version "1.7.4")
      (source
       (origin
         (method url-fetch)
         (uri (hackage-uri "yesod-form" version))
         (sha256
          (base32 "012w6pq0zznwqn19nx5h30rmd7dazcd0d75a6426d7brxvf9vn98"))))
      (build-system haskell-build-system)
      (properties '((upstream-name . "yesod-form")))
      (inputs (list ghc-aeson
                    ghc-attoparsec
                    ghc-blaze-builder
                    ghc-blaze-html
                    ghc-blaze-markup
                    ghc-byteable
                    ghc-data-default
                    ghc-email-validate
                    ghc-persistent
                    ghc-resourcet
                    ghc-shakespeare
                    ghc-wai
                    ghc-xss-sanitize
                    ghc-yesod-core
                    ghc-yesod-persistent
                    ghc-network-uri))
      (native-inputs (list ghc-hspec))
      (home-page "http://www.yesodweb.com/")
      (synopsis "Form handling support for Yesod Web Framework")
      (description
       "This Haskell package provides a set of basic form inputs such
as text, number, time, checkbox, select, textarea, etc through the
@code{Yesod.Form.Fields} module.  Also, there is @code{Yesod.Form.Nic} module
providing richtext field using Nic editor.")
      (license license:expat)))

(define-public ghc-yesod
  (package
    (name "ghc-yesod")
    (version "1.6.2.1")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "yesod" version))
              (sha256
               (base32
                "1qglaxqx96c7wi4817ff67c9g2fxlnjzdpgic458i80khpdlmb5c"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "yesod")))
    (inputs (list ghc-aeson
                  ghc-conduit
                  ghc-data-default-class
                  ghc-fast-logger
                  ghc-file-embed
                  ghc-monad-logger
                  ghc-shakespeare
                  ghc-streaming-commons
                  ghc-unordered-containers
                  ghc-wai
                  ghc-wai-extra
                  ghc-wai-logger
                  ghc-warp
                  ghc-yaml
                  ghc-yesod-core
                  ghc-yesod-form
                  ghc-yesod-persistent))
    (home-page "http://www.yesodweb.com/")
    (synopsis "Framework for creating type-safe, RESTful web applications")
    (description
     "The Haskell package package groups together the various
Yesod related packages into one cohesive whole.  This is the version of Yesod,
whereas most of the core code lives in @code{ghc-yesod-core}.")
    (license license:expat)))

(define-public ghc-hxt-charproperties
  (package
    (name "ghc-hxt-charproperties")
    (version "9.5.0.0")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "hxt-charproperties" version))
       (sha256
        (base32
         "0jm98jddbsd60jc2bz8wa71rslagbaqf00ia7fvfsaiaa54nk0r8"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "hxt-charproperties")))
    (home-page "https://github.com/UweSchmidt/hxt")
    (synopsis "Character properties and classes for XML and Unicode")
    (description
     "The modules provided by this package contain predicates for Unicode
blocks and char properties and character predicates defined by XML.  The
supported Unicode version is 7.0.0")
    (license license:expat)))

(define-public ghc-hxt-unicode
  (package
    (name "ghc-hxt-unicode")
    (version "9.0.2.4")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "hxt-unicode" version))
       (sha256
        (base32
         "0rj48cy8z4fl3zpg5bpa458kqr83adav6jnqv4i71dclpprj6n3v"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "hxt-unicode")))
    (inputs
     (list ghc-hxt-charproperties))
    (home-page
     "http://www.fh-wedel.de/~si/HXmlToolbox/index.html https://github.com/UweSchmidt/hxt")
    (synopsis
     "Unicode en-/decoding functions for utf8, iso-latin-* and other encodings")
    (description
     "This package provides Unicode encoding and decoding functions for
encodings used in the Haskell XML Toolbox.  ISO Latin 1-16, utf8, utf16, ASCII
are supported. Decoding is done with lazy functions, errors may be detected or
ignored.")
    (license license:expat)))

(define-public ghc-hxt-regex-xmlschema
  (package
    (name "ghc-hxt-regex-xmlschema")
    (version "9.2.0.7")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "hxt-regex-xmlschema" version))
       (sha256
        (base32
         "0ynrf65m7abq2fjnarlwq6i1r99pl89npibxx05rlplcgpybrdmr"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "hxt-regex-xmlschema")))
    (inputs
     (list ghc-hxt-charproperties ghc-hunit))
    (home-page "https://wiki.haskell.org/Regular_expressions_for_XML_Schema")
    (synopsis "Regular expression library for W3C XML Schema regular expressions")
    (description
     "This library supports full W3C XML Schema regular expressions inclusive
all Unicode character sets and blocks.  It is implemented by the technique of
derivations of regular expressions.")
    (license license:expat)))

(define-public ghc-hxt
  (package
    (name "ghc-hxt")
    (version "9.3.1.22")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "hxt" version))
       (sha256
        (base32
         "1n9snbdl46x23ka7bbsls1vsn0plpmfmbpbl0msjfm92fkk2yq7g"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "hxt")))
    (outputs '("out" "static" "doc"))
    (inputs
     (list ghc-hxt-charproperties ghc-hxt-unicode ghc-hxt-regex-xmlschema
           ghc-network-uri))
    (home-page "https://github.com/UweSchmidt/hxt")
    (synopsis "Collection of tools for processing XML with Haskell")
    (description
     "The Haskell XML Toolbox bases on the ideas of HaXml and HXML, but
introduces a more general approach for processing XML with Haskell.")
    (license license:expat)))

(define-public ghc-hxt-xpath
  (package
    (name "ghc-hxt-xpath")
    (version "9.1.2.2")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "hxt-xpath" version))
              (sha256
               (base32
                "0wlq9s01icalnvjkkilx5zaqp3ff4v5limj1xy8i18qpzjspqdsh"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "hxt-xpath")))
    (inputs (list ghc-hxt))
    (home-page "https://github.com/UweSchmidt/hxt")
    (synopsis "The XPath modules for HXT")
    (description
     "This extension for the Haskell XML Toolbox defines data types to
represent XPath, navigation trees and primitives to select and edit subtrees
from them.  Some primitives have both a functional and an arrow interface.")
    (license license:expat)))

(define-public ghc-http-common
  (package
    (name "ghc-http-common")
    (version "0.8.3.4")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "http-common" version))
       (sha256
        (base32
         "1xpbnfac0fqa5r670ggwm4kq3cmz9jpaw9bx40j9w9qiw6xi4i28"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "http-common")))
    (inputs
     (list ghc-base64-bytestring
           ghc-blaze-builder
           ghc-case-insensitive
           ghc-network
           ghc-random
           ghc-unordered-containers))
    (home-page "https://github.com/afcowie/http-streams/")
    (synopsis "Common types for HTTP clients and servers")
    (description "Base types used by a variety of HTTP clients and
servers.  See http-streams @code{Network.Http.Client} or pipes-http
@code{Pipes.Http.Client} for full documentation.  You can import
@code{Network.Http.Types} if you like, but both http-streams and
pipes-http re-export this package's types and functions.")
    (license license:bsd-3)))

(define-public ghc-http-streams
  (package
    (name "ghc-http-streams")
    (version "0.8.9.6")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "http-streams" version))
              (sha256
               (base32
                "1h8nnp1y4ngv6mwr3fxv428kcvrd3ming179sza8fkn49pcwdlxs"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "http-streams")))
    (inputs (list ghc-attoparsec
                  ghc-base64-bytestring
                  ghc-blaze-builder
                  ghc-case-insensitive
                  ghc-io-streams
                  ghc-hsopenssl
                  ghc-openssl-streams
                  ghc-unordered-containers
                  ghc-aeson
                  ghc-http-common
                  ghc-network-uri
                  ghc-network))
    (native-inputs (list ghc-hunit
                         ghc-lifted-base
                         ghc-aeson-pretty
                         ghc-hspec
                         ghc-hspec-expectations
                         ghc-random
                         ghc-snap-core
                         ghc-snap-server))
    (home-page "https://github.com/aesiniath/http-streams/")
    (synopsis "HTTP client using io-streams")
    (description
     "An HTTP client using the Snap Framework's io-streams
library to handle the streaming IO.  The API is optimized for ease of
use for the rather common case of code needing to query web services and
deal with the result.")
    (license license:bsd-3)))

;; Breaks cycle between ghc-http-streams and ghc-snap-server
(define-public ghc-http-streams-bootstrap
  (package
    (inherit ghc-http-streams)
    (name "ghc-http-streams-bootstrap")
    (arguments `(#:tests? #f))
    (native-inputs '())
    (properties '((hidden? #t)))))

(define-public ghc-snap-core
  (package
    (name "ghc-snap-core")
    (version "1.0.5.0")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "snap-core" version))
       (sha256
        (base32
         "0hf671g7h4nikfvi05q3mmcxhfcsh874dkansssn0mc68k9fsak4"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "snap-core")))
    (arguments
     `(#:cabal-revision
       ("3" "02r6plphl4vqig3xap9amdib0qjd98nqpn5jhy6hsbiwh3p7cy9b")))
    (inputs
     (list ghc-old-locale
           ghc-hunit
           ghc-attoparsec
           ghc-bytestring-builder
           ghc-case-insensitive
           ghc-lifted-base
           ghc-io-streams
           ghc-hashable
           ghc-monad-control
           ghc-random
           ghc-readable
           ghc-regex-posix
           ghc-transformers-base
           ghc-unix-compat
           ghc-unordered-containers
           ghc-vector
           ghc-network-uri
           ghc-network))
    (native-inputs
     (list ghc-quickcheck
           ghc-parallel
           ghc-test-framework
           ghc-test-framework-hunit
           ghc-test-framework-quickcheck2
           ghc-zlib))
    (home-page "http://snapframework.com/")
    (synopsis "Haskell Web Framework (core interfaces and types)")
    (description "Snap is a simple and fast web development framework
and server written in Haskell.  For more information, you can visit the
Snap project website at @uref{http://snapframework.com/}.  This library
contains the core definitions and types for the Snap framework.")
    (license license:bsd-3)))

(define-public ghc-snap-server
  (package
    (name "ghc-snap-server")
    (version "1.1.2.0")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "snap-server" version))
       (sha256
        (base32
         "0w4yv9a5ilpma0335ariwap2iscmdbaaif88lq3cm7px910nyc4j"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "snap-server")))
    (inputs
     (list ghc-attoparsec
           ghc-blaze-builder
           ghc-bytestring-builder
           ghc-case-insensitive
           ghc-clock
           ghc-io-streams
           ghc-io-streams-haproxy
           ghc-lifted-base
           ghc-network
           ghc-old-locale
           ghc-snap-core
           ghc-unix-compat
           ghc-vector))
    (native-inputs
     (list ghc-base16-bytestring
           ghc-monad-control
           ghc-random
           ghc-threads
           ghc-hunit
           ghc-quickcheck
           ghc-http-streams-bootstrap
           ghc-http-common
           ghc-parallel
           ghc-test-framework
           ghc-test-framework-hunit
           ghc-test-framework-quickcheck2))
    (arguments
     `(#:phases
       (modify-phases %standard-phases
         (add-before 'configure 'update-constraints
           (lambda _
             (substitute* "snap-server.cabal"
               (("\\b(attoparsec|base|bytestring|time)\\s+[^,]+" all dep)
                dep)))))))
    (home-page "http://snapframework.com/")
    (synopsis "Web server for the Snap Framework")
    (description "Snap is a simple and fast web development framework
and server written in Haskell.  For more information, you can visit the
Snap project website at @uref{http://snapframework.com/}.  The Snap HTTP
server is a high performance web server library written in Haskell.
Together with the snap-core library upon which it depends, it provides a
clean and efficient Haskell programming interface to the HTTP
protocol.")
    (license license:bsd-3)))

(define-public ghc-js-jquery
  (package
    (name "ghc-js-jquery")
    (version "3.3.1")
    (source
     (origin
       (method url-fetch)
       (uri
        (hackage-uri "js-jquery" version))
       (sha256
        (base32
         "16q68jzbs7kp07dnq8cprdcc8fd41rim38039vg0w4x11lgniq70"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "js-jquery")))
    (arguments `(#:tests? #f)) ; tests do network IO
    (home-page "https://github.com/ndmitchell/js-jquery")
    (synopsis "Obtain minified jQuery code")
    (description "This package bundles the minified
@url{http://jquery.com/, jQuery} code into a Haskell package, so it can
be depended upon by Cabal packages.  The first three components of the
version number match the upstream jQuery version.  The package is
designed to meet the redistribution requirements of downstream
users (e.g. Debian).")
    (license license:expat)))

(define-public ghc-js-flot
  (package
    (name "ghc-js-flot")
    (version "0.8.3")
    (source
     (origin
       (method url-fetch)
       (uri
        (hackage-uri "js-flot" version))
       (sha256
        (base32
         "0yjyzqh3qzhy5h3nql1fckw0gcfb0f4wj9pm85nafpfqp2kg58hv"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "js-flot")))
    (inputs
     (list ghc-http))
    (home-page "https://github.com/ndmitchell/js-flot")
    (synopsis "Obtain minified flot code")
    (description "This package bundles the minified
@url{http://www.flotcharts.org/, Flot} code (a jQuery plotting library)
into a Haskell package, so it can be depended upon by Cabal packages.
The first three components of the version number match the upstream flot
version.  The package is designed to meet the redistribution
requirements of downstream users (e.g. Debian).")
    (license license:expat)))

(define-public ghc-happstack-server
  (package
    (name "ghc-happstack-server")
    (version "7.7.2")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "happstack-server" version))
              (sha256
               (base32
                "175aal1l4g558y89skck3s04db0bjblkxp77bijf1s9iyc07n669"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "happstack-server")))
    (inputs (list ghc-network
                  ghc-network-uri
                  ghc-base64-bytestring
                  ghc-blaze-html
                  ghc-extensible-exceptions
                  ghc-hslogger
                  ghc-html
                  ghc-monad-control
                  ghc-old-locale
                  ghc-semigroups
                  ghc-sendfile
                  ghc-system-filepath
                  ghc-syb
                  ghc-threads
                  ghc-transformers-base
                  ghc-transformers-compat
                  ghc-utf8-string
                  ghc-zlib))
    (native-inputs (list ghc-hunit))
    (home-page "https://happstack.com")
    (synopsis "Web related tools and services for Haskell")
    (description
     "Happstack Server provides an HTTP server and a rich set of functions for
routing requests, handling query parameters, generating responses, working with
cookies, serving files, and more.")
    (license license:bsd-3)))

(define-public ghc-sendfile
  (package
    (name "ghc-sendfile")
    (version "0.7.11.4")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "sendfile" version))
              (sha256
               (base32
                "1i2i0w18l2ysambyylv93jzy0adiiqwwnhg7zagqb7p2srybxc3k"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "sendfile")))
    (inputs (list ghc-network))
    (home-page "https://github.com/Happstack/sendfile")
    (synopsis "Portable sendfile library for Haskell")
    (description
     "Haskell library which exposes zero-copy sendfile functionality in a portable way.")
    (license license:bsd-3)))

(define-public ghc-scalpel-core
  (package
    (name "ghc-scalpel-core")
    (version "0.6.2.1")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "scalpel-core" version))
              (sha256
               (base32
                "1yl1lsi5xm3qdlww2sb6vyppjiisj54f4yzvffv3qg8dgkfjfdra"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "scalpel-core")))
    (inputs (list ghc-data-default
                  ghc-fail
                  ghc-pointedlist
                  ghc-regex-base
                  ghc-regex-tdfa
                  ghc-tagsoup
                  ghc-vector))
    (native-inputs (list ghc-hunit))
    (home-page "https://github.com/fimad/scalpel")
    (synopsis "High level web scraping library for Haskell")
    (description
     "Scalpel core provides a subset of the scalpel web scraping library
that is intended to have lightweight dependencies and to be free of all
non-Haskell dependencies.")
    (license license:asl2.0)))

(define-public ghc-scalpel
  (package
    (name "ghc-scalpel")
    (version "0.6.2.1")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "scalpel" version))
              (sha256
               (base32
                "0w3l38czfsgbyd3x6yir7qw9bl8nmhclrbpbwfyhs39728jlscnc"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "scalpel")))
    (inputs (list ghc-scalpel-core
                  ghc-case-insensitive
                  ghc-data-default
                  ghc-http-client
                  ghc-http-client-tls
                  ghc-tagsoup))
    (home-page "https://github.com/fimad/scalpel")
    (synopsis "High level web scraping library for Haskell")
    (description
     "Scalpel is a web scraping library inspired by libraries like Parsec
and Perl's @code{Web::Scraper}.  Scalpel builds on top of TagSoup to provide a
declarative and monadic interface.")
    (license license:asl2.0)))

(define-public ghc-sourcemap
  (package
    (name "ghc-sourcemap")
    (version "0.1.7")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "sourcemap" version))
              (sha256
               (base32
                "09i340mhzlfi5ayy9cb0378glnygdmpdhhsgikm3zrvwf2wmwr2h"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "sourcemap")))
    (inputs (list ghc-aeson ghc-unordered-containers ghc-attoparsec
                  ghc-utf8-string))
    ;(native-inputs (list node))
    (arguments (list #:tests? #f)) ; Needs node and module source-map.
    (home-page
     "https://hackage.haskell.org/package/sourcemap")
    (synopsis
     "Implementation of source maps as proposed by Google and Mozilla")
    (description
     "Sourcemap provides an implementation of source maps, revision 3,
proposed by Google and Mozilla here
@url{https://wiki.mozilla.org/DevTools/Features/SourceMap}.")
    (license license:bsd-3)))

(define-public ghc-language-javascript
  (package
    (name "ghc-language-javascript")
    (version "0.7.1.0")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "language-javascript" version))
       (sha256
        (base32
         "0s6igb54cxm2jywgc3sq53f52gcsc39wd3g78yisfzvl9jm3d86i"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "language-javascript")))
    (inputs
     (list ghc-blaze-builder ghc-utf8-string))
    (native-inputs
     (list ghc-alex ghc-quickcheck ghc-happy ghc-hspec ghc-utf8-light))
    (home-page
     "https://github.com/erikd/language-javascript")
    (synopsis "Parser for JavaScript")
    (description
     "Parses Javascript into an Abstract Syntax Tree (AST).  Initially intended
as frontend to hjsmin.")
    (license license:bsd-3)))

(define-public ghc-bower-json
  (package
    (name "ghc-bower-json")
    (version "1.1.0.0")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "bower-json" version))
       (sha256
        (base32
         "0lnhcgivg38nicncb6czkkk3z2mk3jbifv1b4r51lk3p9blzydfl"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "bower-json")))
    (inputs
     (list ghc-aeson ghc-aeson-better-errors ghc-scientific
           ghc-transformers ghc-unordered-containers))
    (native-inputs
     (list ghc-tasty ghc-tasty-hunit))
    (home-page "https://github.com/hdgarrood/bower-json")
    (synopsis "Read bower.json from Haskell")
    (description
     "This package provides a data type and ToJSON/FromJSON instances for
Bower's package manifest file, bower.json.")
    (license license:expat)))

(define-public ghc-dav
  (package
    (name "ghc-dav")
    (version "1.3.4")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "DAV" version))
       (sha256
        (base32 "1isvi4fahq70lzxfz23as7qzkc01g7kba568l6flrgd0j1984fsy"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "DAV")))
    (inputs
     (list ghc-case-insensitive
           ghc-data-default
           ghc-exceptions
           ghc-http-client
           ghc-http-client-tls
           ghc-http-types
           ghc-lens
           ghc-transformers-base
           ghc-transformers-compat
           ghc-utf8-string
           ghc-xml-conduit
           ghc-xml-hamlet
           ghc-network
           ghc-network-uri
           ghc-optparse-applicative))
    (home-page "http://floss.scru.org/hDAV")
    (synopsis "RFC 4918 WebDAV support")
    (description "This package provides a library for the Web Distributed
Authoring and Versioning (WebDAV) extensions to HTTP as well an executable,
@command{hdav}, for command-line operation.")
    (license license:gpl3)))

(define-public ghc-yesod-test
  (package
    (name "ghc-yesod-test")
    (version "1.6.15")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "yesod-test" version))
              (sha256
               (base32
                "16q4f1l3m4l8iy5vmaa8c0vm2iiqhpghf3kykymlh41xy96mqpn3"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "yesod-test")))
    (inputs (list ghc-hunit
                  ghc-aeson
                  ghc-attoparsec
                  ghc-blaze-builder
                  ghc-blaze-html
                  ghc-case-insensitive
                  ghc-conduit
                  ghc-cookie
                  ghc-hspec-core
                  ghc-html-conduit
                  ghc-http-types
                  ghc-network
                  ghc-memory
                  ghc-pretty-show
                  ghc-wai
                  ghc-wai-extra
                  ghc-xml-conduit
                  ghc-xml-types
                  ghc-yesod-core
                  ghc-blaze-markup))
    (native-inputs (list ghc-hspec ghc-yesod-form ghc-unliftio
                         ghc-unliftio-core))
    (home-page "http://www.yesodweb.com")
    (synopsis "Integration testing for WAI/Yesod Applications")
    (description
     "This package's main goal is to encourage integration
and system testing of web applications by making everything easy to
test.  Tests are like browser sessions that keep track of cookies and
the last visited page.  You can perform assertions on the content of
HTML responses using CSS selectors.")
    (license license:expat)))

(define-public ghc-wai-app-static
  (package
    (name "ghc-wai-app-static")
    (version "3.1.7.4")
    (source (origin
              (method url-fetch)
              (uri (hackage-uri "wai-app-static" version))
              (sha256
               (base32
                "1h8zy3dprqjxvlqxrids65yg5qf1h4f63ddspwxrbp0r9d28hwb4"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "wai-app-static")))
    (inputs (list ghc-wai
                  ghc-http-types
                  ghc-unix-compat
                  ghc-old-locale
                  ghc-file-embed
                  ghc-http-date
                  ghc-blaze-html
                  ghc-blaze-markup
                  ghc-mime-types
                  ghc-unordered-containers
                  ghc-zlib
                  ghc-wai-extra
                  ghc-optparse-applicative
                  ghc-warp
                  ghc-cryptonite
                  ghc-memory))
    (native-inputs (list ghc-hspec ghc-network ghc-temporary ghc-mockery))
    (home-page "http://www.yesodweb.com/book/web-application-interface")
    (synopsis "WAI application for static serving")
    (description
     "This package provides a Web Application
Interface (WAI) application for static serving.  It also provides some
helper functions and datatypes for use outside of WAI.")
    (license license:expat)))

(define-public ghc-hjsmin
  (package
    (name "ghc-hjsmin")
    (version "0.2.0.4")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "hjsmin" version))
       (sha256
        (base32
         "1r2p5rjdjr25j3w4s57q5hxw2c3ymw12x7ms18yvglnq2ivr9fc1"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "hjsmin")))
    (arguments
     `(#:cabal-revision ("2"
                         "184g49wsj2sfm8d75kgr7ylfw29gbyrqbqp4syyz30ch047jd0af")
       #:phases
       (modify-phases %standard-phases
         (add-before 'build 'fix-dist-directory-for-tests
           (lambda _
             (substitute* '("test/test-cli.hs" "test/cli/core/runner")
               (("dist-newstyle") "dist")))))))
    (inputs
     (list ghc-language-javascript ghc-optparse-applicative))
    (native-inputs
     (list ghc-extra))
    (home-page "https://github.com/erikd/hjsmin")
    (synopsis "Haskell implementation of a JavaScript minifier")
    (description "This library provides tools reduce the size of
JavaScript files by stripping out extraneous whitespace and other
syntactic elements, without changing the semantics.")
    (license license:bsd-3)))

(define-public ghc-yesod-static
  (package
    (name "ghc-yesod-static")
    (version "1.6.1.0")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "yesod-static" version))
       (sha256
        (base32
         "18f5hm9ncvkzl8bkn39cg841z0k5iqs5w45afsyk9y6k98pjd54p"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "yesod-static")))
    (inputs
     (list ghc-async
           ghc-attoparsec
           ghc-base64-bytestring
           ghc-blaze-builder
           ghc-conduit
           ghc-cryptonite
           ghc-cryptonite-conduit
           ghc-css-text
           ghc-data-default
           ghc-file-embed
           ghc-hashable
           ghc-hjsmin
           ghc-http-types
           ghc-memory
           ghc-mime-types
           ghc-unix-compat
           ghc-unordered-containers
           ghc-wai
           ghc-wai-app-static
           ghc-yesod-core))
    (native-inputs
     (list ghc-hspec ghc-yesod-test ghc-wai-extra ghc-hunit ghc-rio))
    (home-page "https://www.yesodweb.com/")
    (synopsis "Static file serving subsite for Yesod")
    (description "This package provides a static file serving subsite
for the Yesod Web Framework.")
    (license license:expat)))

(define-public ghc-wai-handler-launch
  (package
    (name "ghc-wai-handler-launch")
    (version "3.0.3.1")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "wai-handler-launch" version))
       (sha256
        (base32
         "1ifqgyc1ccig5angh5l1iq7vyms4lvi8wzvysg5dw82nml49n02m"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "wai-handler-launch")))
    (inputs
     (list ghc-wai ghc-warp ghc-http-types ghc-streaming-commons
           ghc-async))
    (home-page "https://hackage.haskell.org/package/wai-handler-launch")
    (synopsis "Launch a Web application in the default browser")
    (description "This package handles cross-platform Web browser
launching and inserts JavaScript code to ping the server.  When the
server no longer receives pings, it shuts down.")
    (license license:expat)))

(define-public ghc-wai-cors
  (package
    (name "ghc-wai-cors")
    (version "0.2.7")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "wai-cors" version))
       (sha256
        (base32
         "10gv3jjlkcb13031frr818p56v2s0qf6dqjsfpwlhwdxdssvx5r5"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "wai-cors")))
    (arguments
     `(#:phases
       (modify-phases %standard-phases
         ;; As of version 0.2.7, there are two test suites: "unit-tests"
         ;; and "phantomjs".  Since we do not have a PhantomJS package,
         ;; we only run the unit tests.
         (replace 'check
           (lambda _
             (invoke "runhaskell" "Setup.hs" "test" "unit-tests"))))))
    (inputs
     (list ghc-attoparsec ghc-base-unicode-symbols ghc-case-insensitive
           ghc-http-types ghc-wai))
    (native-inputs
     (list ghc-network
           ghc-wai-websockets
           ghc-warp
           ghc-websockets
           ghc-tasty
           ghc-tasty-hunit
           ghc-wai-extra
           ghc-wai-websockets
           ghc-warp
           ghc-websockets))
    (home-page "https://github.com/larskuhtz/wai-cors")
    (synopsis "Cross-Origin Resource Sharing (CORS) for WAI")
    (description "This package provides an implementation of Cross-Origin
Resource Sharing (CORS) for the Web Application Framework (WAI) that
aims to be compliant with @url{https://www.w3.org/TR/cors}.")
    (license license:expat)))

(define-public ghc-network-run
  (package
    (name "ghc-network-run")
    (version "0.2.5")
    (source
     (origin
       (method url-fetch)
       (uri (hackage-uri "network-run" version))
       (sha256
        (base32 "08662w7ja9w4a4fwikaawxnxcszkd0mdmaajmshas2dd25xyikwi"))))
    (build-system haskell-build-system)
    (properties '((upstream-name . "network-run")))
    (inputs (list ghc-network))
    (home-page "https://hackage.haskell.org/package/network-run")
    (synopsis "Simple network runner library")
    (description
     "This package provides a simple network runner library in Haskell.")
    (license license:bsd-3)))

perl-license))) (define-public perl-email-simple (package (name "perl-email-simple") (version "2.216") (source (origin (method url-fetch) (uri (string-append "mirror://cpan/authors/id/R/RJ/RJBS/" "Email-Simple-" version ".tar.gz")) (sha256 (base32 "1m4brbjvalyp5kjqslqv4155dzwg977shxin208i7lc8236n6pyq")))) (build-system perl-build-system) (propagated-inputs `(("perl-email-date-format" ,perl-email-date-format))) (home-page "https://metacpan.org/release/Email-Simple") (synopsis "Parsing of RFC 2822 messages") (description "Email::Simple provides simple parsing of RFC 2822 message format and headers.") (license license:perl-license))) (define-public libesmtp (package (name "libesmtp") (version "1.0.6") (source (origin (method url-fetch) (uri (list (string-append "https://pkgs.fedoraproject.org/repo/pkgs/" "libesmtp/libesmtp-" version ".tar.bz2/" "bf3915e627fd8f35524a8fdfeed979c8/libesmtp-" version ".tar.bz2") ;; XXX This site is offline, so we fetch Fedora's cached copy ;; of the source tarball. (string-append "http://www.stafford.uklinux.net/libesmtp/libesmtp-" version ".tar.bz2"))) (sha256 (base32 "02zbniyz7qys1jmx3ghx21kxmns1wc3hmv80gp7ag7yra9f1m9nh")))) (build-system gnu-build-system) (propagated-inputs `(("openssl" ,openssl))) (home-page "http://www.stafford.uklinux.net/libesmtp/") (synopsis "Library for sending mail via remote hosts using SMTP") (description "libESMTP is an SMTP client which manages posting (or submission of) electronic mail via a preconfigured Mail Transport Agent (MTA). It may be used as part of a Mail User Agent (MUA) or other program that must be able to post electronic mail where mail functionality may not be that program's primary purpose.") (license (list license:lgpl2.1+ license:gpl2+)))) (define-public esmtp (package (name "esmtp") (version "1.2") (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/andywingo/esmtp") (commit "01bf9fc"))) (sha256 (base32 "1ay282rrl92h0m0m8z5zzjnwiiagi7c78aq2qvhia5mw7prwfyw2")) (file-name (string-append name "-" version "-checkout")))) (arguments `(#:phases (modify-phases %standard-phases (replace 'bootstrap (lambda _ (invoke "autoreconf" "-vfi")))))) (build-system gnu-build-system) (native-inputs `(("bison" ,bison) ("flex" ,flex) ("autoconf" ,autoconf) ("automake" ,automake) ("libtool" ,libtool))) (inputs `(("libesmtp" ,libesmtp))) (home-page "https://sourceforge.net/projects/esmtp/") (synopsis "Relay-only mail transfer agent (MTA)") (description "Esmtp is a simple relay-only mail transfer agent built using libESMTP. It sends e-mail via a remote SMTP server using credentials from the user's @file{$HOME/.esmtprc} configuration file; see the @command{esmtprc} man page for more on configuration. This package also provides minimal compatibility shims for the @command{sendmail}, @command{mailq}, and @command{newaliases} commands.") (license license:gpl2+))) (define-public fdm (package (name "fdm") (version "2.0") (source (origin (method url-fetch) (uri (string-append "https://github.com/nicm/fdm/releases/download/" version "/fdm-" version ".tar.gz")) (sha256 (base32 "196fs1z8y7p12wmqn1bylzz94szl58yv2aby3p30nmwjnyv8rch6")))) (build-system gnu-build-system) (inputs `(("tdb" ,tdb) ("openssl" ,openssl) ("zlib" ,zlib))) (home-page "https://github.com/nicm/fdm") (synopsis "Mail Retrieval Agent (MRA) and Mail Delivery Agent (MDA)") (description "fdm is a program designed to fetch mail from POP3 or IMAP servers, or receive local mail from stdin, and deliver it in various ways.") (license ;; Why point to a source file? Well, all the individual files have a ;; copy of this license in their headers, but there's no seprate file ;; with that information. (license:non-copyleft "https://github.com/nicm/fdm/blob/master/command.c")))) (define-public procmail (package (name "procmail") (version "3.22") (source (origin (method url-fetch) (uri (string-append "ftp://ftp.fu-berlin.de/pub/unix/mail/procmail/procmail-" version ".tar.gz")) (sha256 (base32 "05z1c803n5cppkcq99vkyd5myff904lf9sdgynfqngfk9nrpaz08")) ;; The following patch fixes an ambiguous definition of ;; getline() in formail.c. The patch is provided by Debian as ;; patch 24. (patches (search-patches "procmail-ambiguous-getline-debian.patch" "procmail-CVE-2014-3618.patch" "procmail-CVE-2017-16844.patch")))) (arguments `(#:phases (modify-phases %standard-phases (replace 'configure (lambda _ (substitute* "Makefile" (("/bin/sh") (which "sh")) (("/usr") (assoc-ref %outputs "out")) (("/bin/rm") (which "rm"))) #t))) #:tests? #f)) ;; There are no tests indicating a successful ;; build. Some tests of basic locking mechanisms provided by the ;; file system are performed during 'make install'. However, these ;; are performed before the actual build process. (build-system gnu-build-system) (inputs `(("exim" ,exim))) (home-page "http://www.procmail.org/") (synopsis "Versatile mail delivery agent (MDA)") (description "Procmail is a mail delivery agent (MDA) featuring support for a variety of mailbox formats such as mbox, mh and maildir. Incoming mail can be sorted into separate files/directories and arbitrary commands can be executed on mail arrival. Procmail is considered stable, but is no longer maintained.") (license license:gpl2+))) ;; procmail allows to choose the ;; nonfree Artistic License 1.0 ;; as alternative to the GPL2+. ;; This option is not listed here. (define-public khard (package (name "khard") (version "0.17.0") (source (origin (method url-fetch) (uri (pypi-uri name version)) (sha256 (base32 "062nv4xkfsjc11k9m52dh6xjn9z68a4a6x1s8z05wwv4jbp1lkhn")))) (build-system python-build-system) (arguments `(#:phases (modify-phases %standard-phases (add-after 'install 'install-completions (lambda* (#:key outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) (zsh (string-append out "/share/zsh/site-functions"))) (copy-recursively "misc/zsh" zsh) #t)))))) (native-inputs `(("python-setuptools-scm" ,python-setuptools-scm))) (inputs `(("python-atomicwrites" ,python-atomicwrites) ("python-configobj" ,python-configobj) ("python-ruamel.yaml" ,python-ruamel.yaml) ("python-unidecode" ,python-unidecode) ("python-vobject" ,python-vobject))) (synopsis "Console address book using CardDAV") (description "Khard is an address book for the console. It creates, reads, modifies and removes CardDAV address book entries at your local machine. For synchronizing with a remote address book, @command{vdirsyncer} is recommended. Khard can also be used from within the email client @command{mutt}.") (home-page "https://github.com/scheibler/khard") (license license:gpl3+))) (define-public perl-mail-spf (package (name "perl-mail-spf") (version "2.9.0") (source (origin (method url-fetch) (uri (string-append "mirror://cpan/authors/id/J/JM/JMEHNLE/mail-spf/Mail-SPF-v" version ".tar.gz")) (sha256 (base32 "0qk1rfgfm5drj4iyniiabrasrpqv570vzhgz66lwgb67y4amkjv1")))) (build-system perl-build-system) (native-inputs `(("perl-module-build" ,perl-module-build) ("perl-net-dns-resolver-programmable" ,perl-net-dns-resolver-programmable))) (arguments `(#:phases (modify-phases %standard-phases (add-before 'configure 'modify-Build.PL (lambda* (#:key outputs #:allow-other-keys) (substitute* "Build.PL" (("'/usr/sbin'") (string-append "'" (assoc-ref outputs "out") "/sbin'"))) #t))))) (inputs `(("perl-error" ,perl-error) ("perl-net-dns" ,perl-net-dns) ("perl-netaddr-ip" ,perl-netaddr-ip) ("perl-uri" ,perl-uri))) (home-page "https://metacpan.org/release/Mail-SPF") (synopsis "Perl implementation of Sender Policy Framework") (description "Mail::SPF is the Sender Policy Framework implemented in Perl.") (license license:bsd-3))) (define-public perl-mail-authenticationresults (package (name "perl-mail-authenticationresults") (version "1.20180923") (source (origin (method url-fetch) (uri (string-append "mirror://cpan/authors/id/M/MB/MBRADSHAW/" "Mail-AuthenticationResults-" version ".tar.gz")) (sha256 (base32 "1g1wym9vcbhldwvi4w5pl0fhd4jh2icj975awf4wr5xmkli9mxbz")))) (build-system perl-build-system) (native-inputs `(("perl-test-exception" ,perl-test-exception))) (home-page "https://metacpan.org/release/Mail-AuthenticationResults") (synopsis "Object Oriented Authentication-Results Headers") (description "Mail::AuthenticationResults parses the message header field that indicates the message authentication status as per RFC7601. This module is not fully compliant with the RFC but it tries to implement most styles of Authentication-Results header seen in the wild.") (license license:perl-license))) (define-public perl-mail-dkim (package (name "perl-mail-dkim") (version "0.58") (source (origin (method url-fetch) (uri (string-append "mirror://cpan/authors/id/M/MB/MBRADSHAW/Mail-DKIM-" version ".tar.gz")) (sha256 (base32 "0cgkal65qqcy57b21lgij90ba36wl66byw9i76g5yhwaa8ms8hqa")))) (build-system perl-build-system) (propagated-inputs `(("perl-crypt-openssl-rsa" ,perl-crypt-openssl-rsa) ("perl-mail-authenticationresults" ,perl-mail-authenticationresults) ("perl-mailtools" ,perl-mailtools) ("perl-net-dns" ,perl-net-dns))) (native-inputs `(("perl-net-dns-resolver-mock" ,perl-net-dns-resolver-mock) ("perl-test-requiresinternet" ,perl-test-requiresinternet) ("perl-yaml-libyaml" ,perl-yaml-libyaml))) (home-page "https://metacpan.org/release/Mail-DKIM") (synopsis "Signs/verifies Internet mail with DKIM/DomainKey signatures") (description "Mail::DKIM is a Perl module that implements the new Domain Keys Identified Mail (DKIM) standard, and the older Yahoo! DomainKeys standard, both of which sign and verify emails using digital signatures and DNS records. Mail-DKIM can be used by any Perl program that wants to provide support for DKIM and/or DomainKeys.") (license license:gpl3+))) (define-public dkimproxy (package (name "dkimproxy") (version "1.4.1") (source (origin (method url-fetch) (uri (string-append "mirror://sourceforge/dkimproxy/dkimproxy/" version "/dkimproxy-" version ".tar.gz")) (sha256 (base32 "1gc5c7lg2qrlck7b0lvjfqr824ch6jkrzkpsn0gjvlzg7hfmld75")) (patches (search-patches "dkimproxy-add-ipv6-support.patch")))) (build-system gnu-build-system) (arguments `(#:phases (modify-phases %standard-phases (add-after 'install 'make-wrapper (lambda* (#:key inputs outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) (wrap.pl (lambda (scripts keys) (for-each (lambda (script) (wrap-program (string-append out script) `("PERL5LIB" ":" prefix ,(map (λ (input) (string-append (assoc-ref inputs input) "/lib/perl5/site_perl")) keys)))) scripts)))) (wrap.pl (list "/bin/dkimproxy.in" "/bin/dkimproxy.out") (list "perl-crypt-openssl-rsa" "perl-io-socket-inet6" "perl-mailtools" "perl-mail-authenticationresults" "perl-mail-dkim" "perl-net-dns" "perl-net-server" "perl-socket6")) (wrap.pl (list "/bin/dkim_responder.pl") (list "perl-crypt-openssl-rsa" "perl-mail-dkim" "perl-mailtools" "perl-mime-tools" "perl-net-dns" "perl-timedate")) #t)))))) (inputs `(("perl" ,perl) ("perl-crypt-openssl-rsa" ,perl-crypt-openssl-rsa) ("perl-io-socket-inet6" ,perl-io-socket-inet6) ("perl-mailtools" ,perl-mailtools) ("perl-mail-authenticationresults" ,perl-mail-authenticationresults) ("perl-mail-dkim" ,perl-mail-dkim) ("perl-mime-tools" ,perl-mime-tools) ("perl-net-dns" ,perl-net-dns) ("perl-net-server" ,perl-net-server) ("perl-socket6" ,perl-socket6) ("perl-timedate" ,perl-timedate))) (home-page "http://dkimproxy.sourceforge.net/") (synopsis "SMTP proxy to sign and verify Internet mail with DKIM headers") (description "DKIMproxy is an SMTP proxy that signs and verifies Internet mail using the @code{Mail::DKIM} Perl module. It comprises two separate proxies: an outbound proxy for signing outgoing email, and an inbound proxy for verifying signatures of incoming messages. It was designed for Postfix, but can be used to add DKIM support to nearly any existing mail server. With Postfix, the proxies can operate as either @code{Before-Queue} or @code{After-Queue} content filters.") (license license:gpl2+))) (define-public mb2md (package (name "mb2md") (version "3.20") (source (origin (method url-fetch) (uri (string-append "http://batleth.sapienti-sat.org/projects/mb2md/mb2md-" version ".pl.gz")) (sha256 (base32 "0bvkky3c90738h3skd2f1b2yy5xzhl25cbh9w2dy97rs86ssjidg")))) (build-system trivial-build-system) (arguments '(#:modules ((guix build utils)) #:builder (begin (use-modules (guix build utils)) (let* ((source (assoc-ref %build-inputs "source")) (out (assoc-ref %outputs "out")) (bin (string-append out "/bin")) (perl (assoc-ref %build-inputs "perl")) (gzip (assoc-ref %build-inputs "gzip")) (perl-timedate (assoc-ref %build-inputs "perl-timedate")) (perl5lib (string-append perl-timedate "/lib/perl5/site_perl"))) (mkdir-p bin) (with-directory-excursion bin (copy-file source "mb2md.gz") (invoke (string-append gzip "/bin/gzip") "-d" "mb2md.gz") (substitute* "mb2md" (("#!/usr/bin/perl") (string-append "#!/usr/bin/perl -I " perl5lib))) (patch-shebang "mb2md" (list (string-append perl "/bin"))) (chmod "mb2md" #o555)) #t)))) (native-inputs `(("gzip" ,gzip))) (inputs `(("perl" ,perl) ("perl-timedate" ,perl-timedate))) (home-page "http://batleth.sapienti-sat.org/projects/mb2md/") (synopsis "Mbox to maildir converter") (description "Mb2md is a Perl script that takes one or more mbox format files and converts them to maildir format directories.") (license license:public-domain))) (define-public mblaze (package (name "mblaze") (version "1.1") (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/leahneukirchen/mblaze") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 (base32 "1bir977vnqs76g8jgv1yivqw0wk2kn56l3l5r4w2ipix3fir138y")))) (build-system gnu-build-system) (native-inputs `(("perl" ,perl))) (arguments `(#:tests? #f ; XXX: Upstream tests appear to be broken #:make-flags (list (string-append "CC=" ,(cc-for-target)) "PREFIX=" (string-append "DESTDIR=" %output)) #:phases (modify-phases %standard-phases (delete 'configure)))) (home-page "https://github.com/leahneukirchen/mblaze") (synopsis "Unix utilities to deal with Maildir") (description "The mblaze message system is a set of Unix utilities for processing and interacting with mail messages which are stored in maildir folders. Its design is roughly inspired by MH, the RAND Message Handling System, but it is a complete implementation from scratch. mblaze is a classic command line MUA and has no features for receiving or transferring messages; you can operate on messages in a local maildir spool, or fetch your messages using fdm(1), getmail(1), offlineimap(1), or similar utilities, and send it using dma(8), msmtp(1), sendmail(8), as provided by OpenSMTPD, Postfix, or similar. mblaze operates directly on maildir folders and doesn't use its own caches or databases. There is no setup needed for many uses. All utilities have been written with performance in mind. Enumeration of all messages in a maildir is avoided unless necessary, and then optimized to limit syscalls. Parsing message metadata is optimized to limit I/O requests. Initial operations on a large maildir may feel slow, but as soon as they are in the file system cache, everything is blazingly fast. The utilities are written to be memory efficient (i.e. not wasteful), but whole messages are assumed to fit into RAM easily (one at a time).") (license (list license:public-domain license:expat)))) ; mystrverscmp.c and mymemmem (define-public mpop (package (name "mpop") (version "1.4.12") (source (origin (method url-fetch) (uri (string-append "https://marlam.de/mpop/releases/" "mpop-" version ".tar.xz")) (sha256 (base32 "02j8qfd44dfyq1sq7r9znj9y6wam39ncch1sc8chcdlw5nsmaqsz")))) (build-system gnu-build-system) (inputs `(("gnutls" ,gnutls))) (native-inputs `(("pkg-config" ,pkg-config))) (home-page "https://marlam.de/mpop/") (synopsis "POP3 mail client") (description "mpop is a small and fast POP3 client suitable as a fetchmail replacement. mpop supports multiple accounts, header based mail filtering, delivery to mbox files, maildir folders or an @acronym{MDA, Mail Delivery Agent}, TLS/SSL, several authentication methods, @acronym{IDN, Internationalized Domain Names} and SOCKS proxies.") (license license:gpl3+))) (define-public mhonarc (package (name "mhonarc") (version "2.6.19") (source (origin (method url-fetch) (uri (string-append "mirror://cpan/authors/id/E/EH/EHOOD/MHonArc-" version ".tar.gz")) (sha256 (base32 "0ll3v93yji334zqp6xfzfxc0127pmjcznmai1l5q6dzawrs2igzq")))) (build-system perl-build-system) (home-page "https://www.mhonarc.org/") (synopsis "Create HTML archives of mail/news messages") (description "MHonArc is a Perl mail-to-HTML converter. MHonArc provides HTML mail archiving with index, mail thread linking, etc; plus other capabilities including support for MIME and powerful user customization features.") (license license:gpl2+))) (define-public sendmail (package (name "sendmail") (version "8.15.2") (source (origin (method url-fetch) (uri (string-append "ftp://ftp.sendmail.org/pub/sendmail/sendmail." version ".tar.gz")) (sha256 (base32 "0fdl9ndmspqspdlmghzxlaqk56j3yajk52d7jxcg21b7sxglpy94")))) (build-system gnu-build-system) (arguments `(#:phases (modify-phases %standard-phases (add-before 'build 'replace-/bin/sh (lambda _ (substitute* (append (list "smrsh/smrsh.c" "sendmail/conf.c" "contrib/mailprio" "contrib/mmuegel" "devtools/bin/configure.sh") (find-files "." ".*\\.m4") (find-files "." ".*\\.cf")) (("/bin/sh") (which "sh"))) (substitute* "devtools/bin/Build" (("SHELL=/bin/sh") (string-append "SHELL=" (which "sh")))) #t)) (replace 'configure (lambda _ ;; Render harmless any attempts to chown or chgrp (substitute* "devtools/bin/install.sh" (("owner=\\$2") "owner=''") (("group=\\$2") "group=''")) (with-output-to-file "devtools/Site/site.config.m4" (lambda () (format #t " define(`confCC', `gcc') define(`confOPTIMIZE', `-g -O2') define(`confLIBS', `-lresolv') define(`confINSTALL', `~a/devtools/bin/install.sh') define(`confDEPEND_TYPE', `CC-M') define(`confINST_DEP', `') " (getcwd)))) #t)) (replace 'build (lambda _ (invoke "sh" "Build") (with-directory-excursion "cf/cf" (copy-file "generic-linux.mc" "sendmail.mc") (invoke "sh" "Build" "sendmail.cf")) #t)) (add-before 'install 'pre-install (lambda _ (let ((out (assoc-ref %outputs "out"))) (mkdir-p (string-append out "/usr/bin")) (mkdir-p (string-append out "/usr/sbin")) (mkdir-p (string-append out "/etc/mail")) (setenv "DESTDIR" out) (with-directory-excursion "cf/cf" (invoke "sh" "Build" "install-cf")) #t)))) ;; There is no make check. There are some post installation tests, but those ;; require root privileges #:tests? #f)) (inputs `(("m4" ,m4) ("perl" ,perl))) (home-page "http://sendmail.org") (synopsis "Highly configurable Mail Transfer Agent (MTA)") (description "Sendmail is a mail transfer agent (MTA) originally developed by Eric Allman. It is highly configurable and supports many delivery methods and many transfer protocols.") (license (license:non-copyleft "file://LICENSE" "See LICENSE in the distribution.")))) (define-public sieve-connect (package (name "sieve-connect") (version "0.90") (source (origin (method url-fetch) (uri (string-append "https://people.spodhuis.org/phil.pennock/software/" "sieve-connect-" version ".tar.bz2")) (sha256 (base32 "00vnyzr67yr2ilnprbd388gfnwmrmbdx1jsig9d0n5q902jqn62a")))) (build-system gnu-build-system) (arguments `(#:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out"))) #:tests? #f ; no test suite #:phases (modify-phases %standard-phases (delete 'configure) ; no configure script (add-before 'install 'create-output-directories (lambda* (#:key outputs #:allow-other-keys) (let ((out (assoc-ref outputs "out"))) (for-each (lambda (subdirectory) (mkdir-p (string-append out "/" subdirectory))) (list "bin" "man/man1")) #t))) (add-after 'install 'wrap-program (lambda* (#:key inputs outputs #:allow-other-keys) (let ((out (assoc-ref outputs "out")) (path (getenv "PERL5LIB"))) (wrap-script (string-append out "/bin/sieve-connect") `("PERL5LIB" ":" = (,path))) #t)))))) (inputs `(("guile" ,guile-3.0) ; for wrap-script ("perl" ,perl) ("perl-authen-sasl" ,perl-authen-sasl) ("perl-io-socket-inet6" ,perl-io-socket-inet6) ("perl-io-socket-ssl" ,perl-io-socket-ssl) ("perl-net-dns" ,perl-net-dns) ("perl-socket6" ,perl-socket6) ("perl-term-readkey" ,perl-term-readkey) ("perl-term-readline" ,perl-term-readline-gnu))) (home-page "https://people.spodhuis.org/phil.pennock/software/#sieve-connect") (synopsis "ManageSieve client for managing Sieve e-mail filters") (description "Sieve-connect lets you view, upload, edit, delete, and otherwise manage Sieve scripts on any mail server that speaks the @dfn{ManageSieve} protocol, as specified in RFC 5804. @dfn{Sieve} (RFC 5228) is a specialised language for e-mail filtering. Sieve scripts are stored on the server and run whenever mail arrives. They can automatically sort new messages into folders, silently reject them, send an automated response, and more. @command{sieve-connect} is designed to be both a tool which can be invoked from scripts as well as a decent interactive client. It supports TLS for connection privacy, as well as authentication with SASL or GSSAPI client certificates. It should be a drop-in replacement for @command{sieveshell} from the Cyrus IMAP project.") (license license:bsd-3))) (define-public opensmtpd (package (name "opensmtpd") (version "6.8.0p2") (source (origin (method url-fetch) (uri (string-append "https://www.opensmtpd.org/archives/" "opensmtpd-" version ".tar.gz")) (sha256 (base32 "05sd7bmq29ibnqbl2z53hiyprfxzf0qydfdaixs68rz55wqhbgsi")))) (build-system gnu-build-system) (inputs `(("bdb" ,bdb) ("libasr" ,libasr) ("libevent" ,libevent) ("libressl" ,libressl) ; recommended, and supports e.g. ECDSA ("linux-pam" ,linux-pam) ("zlib" ,zlib))) (native-inputs `(("bison" ,bison) ("groff" ,groff))) ; for man pages (arguments `(#:configure-flags (list "--localstatedir=/var" ;; This is the default only if it exists at build time—it doesn't. "--with-path-socket=/var/run" "--with-path-CAfile=/etc/ssl/certs/ca-certificates.crt" "--with-user-smtpd=smtpd" "--with-user-queue=smtpq" "--with-group-queue=smtpq" "--with-auth-pam" "--with-table-db") #:phases (modify-phases %standard-phases ;; See: https://github.com/OpenSMTPD/OpenSMTPD/issues/1069. (add-after 'unpack 'fix-smtpctl-encrypt-bug (lambda _ (substitute* "usr.sbin/smtpd/smtpctl.c" (("\"encrypt\", \"--\",") "\"encrypt\",")) #t)) ;; Fix some incorrectly hard-coded external tool file names. (add-after 'unpack 'patch-FHS-file-names (lambda _ (substitute* "usr.sbin/smtpd/smtpctl.c" ;; ‘gzcat’ is auto-detected at compile time, but ‘cat’ isn't. (("/bin/cat") (which "cat"))) (substitute* "usr.sbin/smtpd/mda_unpriv.c" (("/bin/sh") (which "sh"))) #t)) ;; OpenSMTPD provides a single smtpctl utility to control both the ;; daemon and the local submission subsystem. To accomodate systems ;; that require historical interfaces such as sendmail, newaliases or ;; makemap, smtpctl operates in compatibility mode if called with the ;; historical name. (add-after 'install 'install-compability-links (lambda* (#:key outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) (sbin (string-append out "/sbin/"))) (for-each (lambda (command) (symlink "smtpctl" (string-append sbin command))) (list "mailq" "makemap" "newaliases" "send-mail" "sendmail"))) #t))))) (synopsis "Lightweight SMTP daemon") (description "OpenSMTPD is an implementation of server-side @acronym{SMTP, Simple Mail Transfer Protocol}, with some additional standard extensions. It allows ordinary machines to exchange e-mails with other systems speaking the SMTP protocol, or to deliver them to local users. In order to simplify the use of SMTP, OpenSMTPD implements a smaller set of functionality than those available in other SMTP daemons. The objective is to provide enough features to satisfy typical usage at the risk of unsuitability to esoteric or niche requirements.") (home-page "https://www.opensmtpd.org") (license (list license:bsd-2 license:bsd-3 license:bsd-4 (license:non-copyleft "file://COPYING") license:public-domain license:isc license:openssl)))) (define-public opensmtpd-extras (package (name "opensmtpd-extras") (version "6.7.1") (source (origin (method url-fetch) (uri (string-append "https://www.opensmtpd.org/archives/" "opensmtpd-extras-" version ".tar.gz")) (sha256 (base32 "1b1mx71bvmv92lbm08wr2p60g3qhikvv3n15zsr6dcwbk9aqahzq")))) (build-system gnu-build-system) (native-inputs `(("pkg-config" ,pkg-config))) (inputs `(("libressl" ,libressl) ("libevent" ,libevent) ("mysql" ,mysql) ("opensmtpd" ,opensmtpd) ("postgresql" ,postgresql) ("python" ,python-2) ("sqlite" ,sqlite))) (arguments `(#:configure-flags (list "--sysconfdir=/etc" "--localstatedir=/var" "--with-queue-null" "--with-queue-python" "--with-queue-ram" "--with-queue-stub" "--with-table-ldap" "--with-table-mysql" "--with-table-postgres" ;; "--with-table-redis" ; TODO: package hiredis "--with-table-socketmap" "--with-table-passwd" "--with-table-python" "--with-table-sqlite" "--with-table-stub" "--with-scheduler-ram" "--with-scheduler-stub" "--with-scheduler-python" "--with-user-smtpd=smtpd" ;; We have to configure it like this because the default checks for ;; for example Python in /usr/{,local/}bin and fails otherwise. (string-append "--with-python=" (assoc-ref %build-inputs "python"))))) (home-page "https://www.opensmtpd.org") (synopsis "Extra tables, filters, and various other addons for OpenSMTPD") (description "This package provides extra tables, filters, and various other addons for OpenSMTPD to extend its functionality.") (license (list license:bsd-2 license:bsd-3 ; openbsd-compat license:isc)))) ; everything else (define libopensmtpd ;; Private source dependency of opensmtpd-filter-dkimsign (by the same ;; author), until any project actually uses it in its compiled form. (let ((revision 48)) (package (name "libopensmtpd") (version (format #f "0.0.0-~a" revision)) (source (origin (method svn-fetch) (uri (svn-reference (url "http://imperialat.at/dev/libopensmtpd/") (revision revision))) (sha256 (base32 "04fgibpi6q0c3468ww3z7gsvraz0gyfps0c2dj8mdyri636c0x0s")) (file-name (git-file-name name version)))) (build-system gnu-build-system) (arguments `(#:make-flags (list "-f" "Makefile.gnu" (string-append "CC=" ,(cc-for-target)) (string-append "LOCALBASE=" (assoc-ref %outputs "out"))) #:tests? #f ; no test suite #:phases (modify-phases %standard-phases (add-after 'unpack 'inherit-ownership (lambda _ (substitute* "Makefile.gnu" (("-o \\$\\{BINOWN\\} -g \\$\\{BINGRP\\}") "")) #t)) (delete 'configure) ; no configure script (add-before 'install 'create-output-directories (lambda* (#:key outputs #:allow-other-keys) (let ((out (assoc-ref outputs "out"))) (mkdir-p (string-append out "/lib")) #t))) (add-after 'install 'install-header-file (lambda* (#:key make-flags outputs #:allow-other-keys) (let ((out (assoc-ref outputs "out"))) (mkdir-p (string-append out "/include")) (apply invoke "make" "includes" make-flags)))) (add-after 'install 'install-man-page (lambda* (#:key outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) (man3 (string-append out "/share/man/man3"))) ;; There is no make target for this. (install-file "osmtpd_run.3" man3) #t)))))) (inputs `(("libevent" ,libevent))) (home-page "http://imperialat.at/dev/libopensmtpd/") (synopsis "OpenSMTPd filter C API") (description "The @code{osmtpd} API is an event-based C programming interface for writing OpenSMTPd filters.") (license license:expat)))) (define-public opensmtpd-filter-dkimsign (package (name "opensmtpd-filter-dkimsign") ;; The .arch repackaging provides not only a usable Makefile, but patches ;; the source to actually build on GNU, e.g., by making pledge() optional. ;; It's effectively the portable branch that upstream lacks at this time. (version "0.2.arch2") ; also update both native-inputs (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/de-vri-es/filter-dkimsign") (commit (string-append "v" version)))) (sha256 (base32 "1dv6184h0gq2safnc7ln4za3arbafzc1xwkgwmiihqcjvdyxig0c")) (file-name (git-file-name name version)))) (build-system gnu-build-system) (arguments `(#:make-flags (list (string-append "CC=" ,(cc-for-target))) #:tests? #f ; no test suite #:phases (modify-phases %standard-phases (replace 'unpack (lambda* (#:key source inputs #:allow-other-keys) (copy-recursively source "filter-dkimsign") (copy-recursively (assoc-ref inputs "libopensmtpd-source") "libopensmtpd") (copy-file (assoc-ref inputs "Makefile") "Makefile") #t)) (delete 'configure) ; no configure script (replace 'install (lambda* (#:key outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) (libexec (string-append out "/libexec/opensmtpd")) (man8 (string-append out "/share/man/man8"))) (chdir "filter-dkimsign") (install-file "filter-dkimsign" libexec) (install-file "filter-dkimsign.8" man8) #t)))))) (native-inputs `(("Makefile" ,(origin (method url-fetch) (uri (string-append "https://aur.archlinux.org/cgit/aur.git/plain/Makefile" "?h=opensmtpd-filter-dkimsign" "&id=58393470477a2ff2a58f9d72f5d851698067539f")) (sha256 (base32 "0da5qr9hfjkf07ybvfva967njmf2x0b82z020r6v5f93jzsbqx92")) (file-name (string-append name "-" version "-Makefile")))) ("libopensmtpd-source" ,(package-source libopensmtpd)))) (inputs `(("libevent" ,libevent) ("libressl" ,libressl))) ; openssl works too but follow opensmtpd (home-page "http://imperialat.at/dev/filter-dkimsign/") (synopsis "OpenSMTPd filter for signing mail with DKIM") (description "The @command{filter-dkimsign} OpenSMTPd filter signs outgoing e-mail messages with @acronym{DKIM, DomainKeys Identified Mail} (RFC 4871).") (license license:expat))) (define-public mailman (package (name "mailman") (version "3.3.2") (source (origin (method url-fetch) (uri (pypi-uri "mailman" version)) (sha256 (base32 "0a5ckbf8hc3y28b7p5psp0d4bxk601jlr5pd3hhh545xd8d9f0dg")))) (build-system python-build-system) (propagated-inputs `(("gunicorn" ,gunicorn) ("python-aiosmtpd" ,python-aiosmtpd) ("python-alembic" ,python-alembic) ("python-atpublic" ,python-atpublic) ("python-authheaders" ,python-authheaders) ("python-authres" ,python-authres) ("python-click" ,python-click) ("python-dateutil" ,python-dateutil) ("python-dnspython" ,python-dnspython) ("python-falcon" ,python-falcon) ("python-flufl-bounce" ,python-flufl-bounce) ("python-flufl-i18n" ,python-flufl-i18n) ("python-flufl-lock" ,python-flufl-lock) ("python-importlib-resources" ,python-importlib-resources) ("python-lazr-config" ,python-lazr-config) ("python-passlib" ,python-passlib) ("python-requests" ,python-requests) ("python-sqlalchemy" ,python-sqlalchemy) ("python-zope-component" ,python-zope-component) ("python-zope-configuration" ,python-zope-configuration) ("python-zope-event" ,python-zope-event) ("python-zope-interface" ,python-zope-interface))) (native-inputs `(("python-nose" ,python-nose))) (home-page "https://www.list.org") (synopsis "Mailing list manager") (description "GNU Mailman is software for managing email discussion and mailing lists. Both users and administrators generally perform their actions in a web interface, although email and command-line interfaces are also provided. The system features built-in archiving, automatic bounce processing, content filtering, digest delivery, and more.") (license license:gpl3+))) (define-public python-mailmanclient (package (name "python-mailmanclient") (version "3.3.1") (source (origin (method url-fetch) (uri (pypi-uri "mailmanclient" version)) (sha256 (base32 "0pjgzpvhdb6ql8asb20xr8d01m646zpghmcp9fmscks0n1k4di4g")))) (build-system python-build-system) (arguments `(#:tests? #f)) ; Requires mailman running (propagated-inputs `(("python-requests" ,python-requests))) ;(native-inputs ; `(("mailman" ,mailman) ; ("python-falcon" ,python-falcon) ; ("python-pytest" ,python-pytest) ; ("python-pytest-services" ,python-pytest-services))) (home-page "https://www.list.org/") (synopsis "Python bindings for the Mailman 3 REST API") (description "The mailmanclient library provides official Python bindings for the GNU Mailman 3 REST API.") (properties `((python2-variant . ,(delay python2-mailmanclient)))) (license license:lgpl3+))) ;; This is the last version which supports Python-2. (define-public python2-mailmanclient (let ((base (package-with-python2 (strip-python2-variant python-mailmanclient)))) (package (inherit base) (version "3.1.1") (source (origin (method url-fetch) (uri (pypi-uri "mailmanclient" version)) (sha256 (base32 "0fdfs5g3pf30v2i7w18pdkv9xnfxmfcv66mzv56dck0a1igq07m3")))) (propagated-inputs `(("python2-six" ,python2-six) ("python2-httplib2" ,python2-httplib2)))))) (define-public mlmmj (package (name "mlmmj") (version "1.3.0") (source (origin (method url-fetch) (uri (string-append "http://mlmmj.org/releases/mlmmj-" version ".tar.bz2")) (sha256 (base32 "0hpj10qad821ci11si8xc2qnmkzfn90y13s43fm4fca38f0qjp8w")))) (build-system gnu-build-system) (inputs `(("perl" ,perl))) ; For "contrib/web/" (native-inputs `(("pkg-config" ,pkg-config))) (arguments `(#:configure-flags ;; mlmmj-receive-strip is a replacement for mlmmj-receive ;; It opens the files control/mimedeny and control/mimestrip to get a list ;; of mimetypes for parts of multipart/mime messages that should be denied ;; or stripped. The parts then get stripped directly when the mail is ;; received. mlmmj-receive-strip also appends an extra header ;; X-ThisMailContainsUnwantedMimeParts: Y when the mail contains unwanted ;; mime parts (list "--enable-receive-strip") #:phases (modify-phases %standard-phases (add-before 'install 'install-contrib (lambda* (#:key outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) (share (string-append out "/share/mlmmj")) (contrib (string-append share "/contrib/web")) (texts (string-append share "/listtexts"))) (copy-recursively "contrib/web/" contrib) (copy-recursively "listtexts" texts) (rename-file texts (string-append share "/texts")) #t)))))) (home-page "http://mlmmj.org") (synopsis "Mailing list managing made joyful") (description "Mlmmj is a simple and slim mailing list manager (MLM) inspired by ezmlm. It works with many different Mail Transport Agents (MTAs) and is simple for a system administrator to install, configure and integrate with other software. As it uses very few resources, and requires no daemons, it is ideal for installation on systems where resources are limited. Its features include: @enumerate @item Archive, Custom headers / footer, @item Fully automated bounce handling (similar to ezmlm), @item Complete requeueing functionality, Moderation functionality, Subject prefix, @item Subscribers only posting, Regular expression access control, @item Functionality to retrieve old posts, Web interface, Digests, @item No-mail subscription, VERP support, @item Delivery Status Notification (RFC1891) support, @item Rich and customisable texts for automated operations. @end enumerate\n") (license license:expat))) (define-public python-django-mailman3 (package (name "python-django-mailman3") (version "1.3.4") (source (origin (method url-fetch) (uri (pypi-uri "django-mailman3" version)) (sha256 (base32 "1yrm7wpjy34xai72vn2vkhc9131cdrbqy08rrabf36kynj5vcdvy")))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases (replace 'check (lambda _ (setenv "DJANGO_SETTINGS_MODULE" "django_mailman3.tests.settings_test") (invoke "django-admin" "test" "--pythonpath=.")))))) (propagated-inputs `(("python-django" ,python-django) ("python-django-allauth" ,python-django-allauth) ("python-django-gravatar2" ,python-django-gravatar2) ("python-mailmanclient" ,python-mailmanclient) ("python-pytz" ,python-pytz))) (native-inputs `(("python-mock" ,python-mock))) (home-page "https://gitlab.com/mailman/django-mailman3") (synopsis "Django library to help interaction with Mailman") (description "This package contains libraries and templates for Django-based interfaces interacting with Mailman.") (license license:gpl3+))) (define-public python-mailman-hyperkitty (package (name "python-mailman-hyperkitty") (version "1.1.0") (source (origin (method url-fetch) (uri (pypi-uri "mailman-hyperkitty" version)) (sha256 (base32 "1lfqa9admhvdv71f528jmz2wl0i5cv77v6l64px2pm4zqr9ckkjx")) (patches (list (origin ;; see: https://gitlab.com/mailman/mailman-hyperkitty/issues/17 ;; fixes test_archive_message_unserializable (method url-fetch) (uri "https://salsa.debian.org/mailman-team/mailman-hyperkitty/raw/debian/1.1.0-9/debian/patches/0002-Skip-the-test_archive_message_unserializable.patch") (sha256 (base32 "0p1fwm46c4bl81lvsg3kjhn2r1lwgkpgxamb3xyqn7h9qdrw10hw"))))))) (build-system python-build-system) (propagated-inputs `(("python-requests" ,python-requests) ("python-zope-interface" ,python-zope-interface))) (inputs `(("mailman" ,mailman))) (native-inputs `(("python-mock" ,python-mock) ("python-nose" ,python-nose) ("python-nose2" ,python-nose2))) (home-page "https://gitlab.com/mailman/mailman-hyperkitty/") (synopsis "Mailman archiver plugin for HyperKitty") (description "Mailman3 allows emails sent to its mailing lists to be archived by any software provided that there is a plugin (loadable by Mailman3) designed to communicate with it properly. This module contains a Mailman3 archiver plugin which sends emails to HyperKitty, the official Mailman3 web archiver.") (license license:gpl3+))) (define-public python-hyperkitty (package (name "python-hyperkitty") (version "1.3.3") (source (origin (method url-fetch) (uri (pypi-uri "HyperKitty" version)) (sha256 (base32 "0p85r9q6mn5as5b39xp9hkkipnk0156acx540n2ygk3qb3jd4a5n")))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases (replace 'check (lambda _ (setenv "PYTHONPATH" (string-append ".:" (getenv "PYTHONPATH"))) (invoke "example_project/manage.py" "test" "--settings=hyperkitty.tests.settings_test")))))) (propagated-inputs `(("python-dateutil" ,python-dateutil) ("python-django" ,python-django-2.2) ("python-django-compressor" ,python-django-compressor) ("python-django-extensions" ,python-django-extensions) ("python-django-gravatar2" ,python-django-gravatar2) ("python-django-haystack" ,python-django-haystack) ("python-django-mailman3" ,python-django-mailman3) ("python-django-q" ,python-django-q) ("python-djangorestframework" ,python-djangorestframework) ("python-flufl-lock" ,python-flufl-lock) ("python-mailmanclient" ,python-mailmanclient) ("python-networkx" ,python-networkx) ("python-pytz" ,python-pytz) ("python-robot-detection" ,python-robot-detection))) (native-inputs `(("python-beautifulsoup4" ,python-beautifulsoup4) ("python-elasticsearch" ,python-elasticsearch) ("python-isort" ,python-isort) ("python-mock" ,python-mock) ("python-whoosh" ,python-whoosh))) (home-page "https://gitlab.com/mailman/hyperkitty") (synopsis "Web interface to access GNU Mailman v3 archives") (description "The hyperkitty Django app provides a web user interface to access GNU Mailman3 archives, and manage it. This interface uses django, and requires some configuration.") (license license:gpl3))) ; Some files are gpl2+ (define-public postorius (package (name "postorius") (version "1.3.3") (source (origin (method url-fetch) (uri (pypi-uri "postorius" version)) (sha256 (base32 "08jn23gblbkfl09qlykbpsmp39mmach3sl69h1j5cd5kkx839rwa")))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases (replace 'check (lambda* (#:key inputs outputs tests? #:allow-other-keys) (add-installed-pythonpath inputs outputs) (if tests? (invoke "python" "example_project/manage.py" "test" "--settings=test_settings" "postorius") #t)))) #:tests? #f)) ; Tests try to run a mailman instance to test against. (inputs `(("python-django" ,python-django) ("python-django-mailman3" ,python-django-mailman3) ("python-mailmanclient" ,python-mailmanclient) ("python-readme-renderer" ,python-readme-renderer))) (native-inputs `(("python-beautifulsoup4" ,python-beautifulsoup4) ("python-isort" ,python-isort) ("python-mock" ,python-mock) ("python-vcrpy" ,python-vcrpy))) (home-page "https://gitlab.com/mailman/postorius") (synopsis "Web user interface for GNU Mailman") (description "Postorius is a Django app which provides a web user interface to access GNU Mailman.") (license (list license:gpl3+ license:lgpl3+)))) (define-public blists (package (name "blists") (version "2.0") (source (origin (method url-fetch) (uri (string-append "http://download.openwall.net/pub/projects/" "blists/blists-" version ".tar.gz")) (sha256 (base32 "1xll5wn7py3bbncbwrj172f56nz75c9gwfsa80rwd96ss9gfmp3c")))) (build-system gnu-build-system) (arguments `(#:tests? #f ; No tests #:phases (modify-phases %standard-phases (delete 'configure) (replace 'install (lambda* (#:key outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) (bin (string-append out "/bin"))) (install-file "bindex" bin) (install-file "bit" bin) #t)))))) (home-page "http://www.openwall.com/blists/") (synopsis "Web interface to mailing list archives") (description "Blists is a web interface to mailing list archives that works off indexed mbox files. There are two programs: @code{bindex} and @code{bit}. @code{bindex} generates or updates the index file (incremental updates are supported). @code{bit} is a CGI/SSI program that generates web pages on the fly. Both programs are written in C and are very fast.") (license license:expat))) (define-public swaks (package (name "swaks") (version "20201014.0") (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/jetmore/swaks") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 (base32 "131i2b1yxhnbqkfk4kky40pfanqw2c5lcgbnjhfqp5cvpawpk2ai")))) (build-system perl-build-system) (inputs `(("perl-io-socket-inet6" ,perl-io-socket-inet6) ("perl-net-dns" ,perl-net-dns) ("perl-net-ssleay" ,perl-net-ssleay) ("perl-socket6" ,perl-socket6))) ; used by perl-io-socket-inet6 (arguments `(#:tests? #f ; no tests #:phases (modify-phases %standard-phases (add-after 'unpack 'set-build_version (lambda _ (substitute* "swaks" (("\"DEVRELEASE\"") (format #f "\"~a\"" ,version))) #true)) (delete 'configure) (replace 'build (lambda _ (invoke "pod2man" "doc/base.pod" "swaks.1"))) (replace 'install (lambda* (#:key outputs #:allow-other-keys) (let ((out (assoc-ref outputs "out"))) (install-file "swaks" (string-append out "/bin")) (install-file "swaks.1" (string-append out "/share/man/man1"))) #t)) (add-after 'install 'wrap-program (lambda* (#:key outputs #:allow-other-keys) (wrap-program (string-append (assoc-ref outputs "out") "/bin/swaks") `("PERL5LIB" ":" = (,(getenv "PERL5LIB")))) #t))))) (home-page "https://jetmore.org/john/code/swaks/") (synopsis "Featureful SMTP test tool") (description "Swaks is a flexible, scriptable, transaction-oriented SMTP test tool. It handles SMTP features and extensions such as TLS, authentication, and pipelining; multiple versions of the SMTP protocol including SMTP, ESMTP, and LMTP; and multiple transport methods including unix-domain sockets, internet-domain sockets, and pipes to spawned processes. Options can be specified in environment variables, configuration files, and the command line allowing maximum configurability and ease of use for operators and scripters.") (license license:gpl2+))) (define-public alpine (package (name "alpine") (version "2.24") (source (origin (method git-fetch) ;; There are two versions: the plain continuation of Alpine without extra ;; patches and the version which adds extra fixes. Every distro uses ;; the patched version, and so do we to not break expectations. ;; http://alpine.freeiz.com/alpine/readme/README.patches (uri (git-reference (url "http://repo.or.cz/alpine.git") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 (base32 "0d5ybnsv29gs8krl66db56avmssq28jlg0qj5i1wka05ncc3740d")) (modules '((guix build utils))) (snippet '(begin ;; Remove pre-built binaries scattered across the source repository. (for-each delete-file (find-files "." "\\.(dll|exe)")) #t)))) (build-system gnu-build-system) (arguments `(#:make-flags (list (string-append "CC=" ,(cc-for-target))) #:configure-flags (list (string-append "--with-ssl-include-dir=" (assoc-ref %build-inputs "openssl") "/include/openssl") (string-append "--with-ssl-dir=" (assoc-ref %build-inputs "openssl")) (string-append "--with-ssl-certs-dir=" "/etc/ssl/certs/") (string-append "--with-ssl-lib-dir=" (assoc-ref %build-inputs "openssl") "/lib") (string-append "--with-interactive-spellcheck=" (assoc-ref %build-inputs "aspell") "/bin/aspell") "--with-date-stamp=Thu 1 Jan 01:00:01 CET 1970") #:phases (modify-phases %standard-phases (add-after 'unpack 'assume-shadow-passwords ;; Alpine's configure script confuses ‘shadow password support’ with ;; ‘/etc/shadow exists in the build environment’. It does not. (lambda _ (substitute* "configure" (("test -f /etc/shadow") "true")) #t)) (add-after 'unpack 'make-reproducible (lambda _ ;; This removes time-dependent code to make alpine reproducible. (substitute* "pico/blddate.c" (("%02d-%s-%d") "1970-01-01")) #t))))) (inputs `(("ncurses" ,ncurses) ("openssl" ,openssl) ("gnutls" ,gnutls) ("openldap" ,openldap) ("cyrus-sasl" ,cyrus-sasl) ("mit-krb5" ,mit-krb5) ("aspell" ,aspell) ("tcl" ,tcl) ("linux-pam" ,linux-pam))) (home-page "https://repo.or.cz/alpine.git") (synopsis "Alternatively Licensed Program for Internet News and Email") (description "Alpine is a text-based mail and news client. Alpine includes several tools and applications: @enumerate @item alpine, the Alpine mailer @item pico, the standalone text editor, GNU nano's predecessor @item pilot, the standalone file system navigator @end enumerate\n") (license license:asl2.0))) (define-public balsa (package (name "balsa") (version "2.6.1") (source (origin (method url-fetch) (uri (string-append "https://pawsa.fedorapeople.org/balsa/" "balsa-" version ".tar.bz2")) (sha256 (base32 "1xkxx801p7sbfkn0bh3cz85wra4xf1z1zhjqqc80z1z1nln7fhb4")))) (build-system gnu-build-system) (arguments `(#:configure-flags '(;; Balsa tries to install additional MIME icons ;; under gtk+ directory. "--enable-extra-mimeicons=no" "--with-gtksourceview" "--with-canberra" "--with-spell-checker=gtkspell" "--with-gpgme" "--with-sqlite" "--with-compface" "--with-ldap"))) (inputs `(("cyrus-sasl" ,cyrus-sasl) ("enchant" ,enchant) ("gdk-pixbuf" ,gdk-pixbuf) ("gmime" ,gmime) ("gnutls" ,gnutls) ("gpgme" ,gpgme) ("gtk+" ,gtk+) ("gtksourceview" ,gtksourceview-3) ("gtkspell3" ,gtkspell3) ("libcanberra" ,libcanberra) ("libesmtp" ,libesmtp) ("libical" ,libical) ("libnotify" ,libnotify) ("libsecret" ,libsecret) ("openldap" ,openldap) ("sqlite" ,sqlite) ("webkitgtk" ,webkitgtk))) (native-inputs `(("compface" ,compface) ("glib" ,glib "bin") ("intltool" ,intltool) ("pkg-config" ,pkg-config) ("yelp-tools" ,yelp-tools))) (home-page "https://pawsa.fedorapeople.org/balsa") (synopsis "E-mail client for GNOME") (description "Balsa is a highly configurable and robust mail client for the GNOME desktop. It supports both POP3 and IMAP servers as well as the mbox, maildir and mh local mailbox formats. Balsa also supports SMTP and/or the use of a local MTA such as Sendmail.") (license license:gpl3+))) (define-public afew (package (name "afew") (version "3.0.1") (source (origin (method url-fetch) (uri (pypi-uri "afew" version)) (sha256 (base32 "0wpfqbqjlfb9z0hafvdhkm7qw56cr9kfy6n8vb0q42dwlghpz1ff")))) (build-system python-build-system) (inputs `(("notmuch" ,notmuch) ("python-chardet" ,python-chardet) ("python-dkimpy" ,python-dkimpy) ("python-notmuch" ,python-notmuch))) (native-inputs `(("python-freezegun" ,python-freezegun) ("python-setuptools-scm" ,python-setuptools-scm))) (home-page "https://github.com/afewmail/afew") (synopsis "Initial tagging script for notmuch mail") (description "afew is an initial tagging script for notmuch mail. It provides automatic tagging each time new mail is registered with notmuch. It can add tags based on email headers or Maildir folders and can handle spam and killed threads.") (license license:isc))) (define-public pan (package (name "pan") (version "0.146") (source (origin (method url-fetch) (uri (string-append "http://pan.rebelbase.com/download/releases/" version "/source/" name "-" version ".tar.bz2")) (sha256 (base32 "17agd27sn4a7nahvkpg0w39kv74njgdrrygs74bbvpaj8rk2hb55")))) (arguments `(#:configure-flags '("--with-gtk3" "--with-gtkspell" "--with-gnutls" "--enable-libnotify" "--enable-manual" "--enable-gkr") #:phases (modify-phases %standard-phases (add-before 'configure 'patch-gpg2 (lambda* (#:key inputs #:allow-other-keys) (substitute* "pan/usenet-utils/gpg.cc" (("\"gpg2\"") (string-append "\"" (assoc-ref inputs "gnupg") "/bin/gpg\""))) #t))))) (inputs `(("gmime" ,gmime-2.6) ("gnupg" ,gnupg) ("gnutls" ,gnutls) ("gtk+" ,gtk+) ("gtkspell3" ,gtkspell3) ("libnotify" ,libnotify) ("libsecret" ,libsecret) ("libxml2" ,libxml2) ("zlib" ,zlib))) (native-inputs `(("gettext-minimal" ,gettext-minimal) ("itstool" ,itstool) ("pkg-config" ,pkg-config))) (build-system gnu-build-system) (home-page "http://pan.rebelbase.com/") (synopsis "Pan newsreader") (description "@code{pan} is a Usenet newsreader that's good at both text and binaries. It supports offline reading, scoring and killfiles, yEnc, NZB, PGP handling, multiple servers, and secure connections.") ;; License of the docs: fdl-1.1; Others: gpl2. (license (list license:fdl1.1+ license:gpl2)))) (define-public imapfilter (package (name "imapfilter") (version "2.7.5") (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/lefcha/imapfilter") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 (base32 "0a7f85r3axwclzw1s79zl2l8222nj2gklvvq33w9qv0dz5n71dcx")))) (build-system gnu-build-system) (arguments `(#:tests? #f #:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out")) (string-append "CC=" ,(cc-for-target))) #:phases (modify-phases %standard-phases (delete 'configure)))) ; no configure script (inputs `(("lua" ,lua) ("pcre2" ,pcre2) ("openssl" ,openssl))) (home-page "https://github.com/lefcha/imapfilter") (synopsis "IMAP mail filtering utility") (description "IMAPFilter is a mail filtering utility. It connects to remote mail servers using IMAP, sends searching queries to the server and processes mailboxes based on the results. It can be used to delete, copy, move, flag, etc. messages residing in mailboxes at the same or different mail servers. The 4rev1 and 4 versions of IMAP are supported.") (license license:expat))) (define-public urlscan (package (name "urlscan") (version "0.9.5") (source (origin (method url-fetch) (uri (pypi-uri "urlscan" version)) (sha256 (base32 "07vcwirap0p4dkqrqblfn1q017slgd8m6qyijvbi3gxnr09pbyx2")))) (build-system python-build-system) (propagated-inputs `(("python-urwid" ,python-urwid))) (home-page "https://github.com/firecat53/urlscan") (synopsis "View/select the URLs in an email message or file") (description "Urlscan is a small program that is designed to integrate with the Mutt mail reader to allow you to easily launch a Web browser for URLs contained in email messages. It parses an email message or file and scans it for URLs and email addresses. It then displays the URLs and their context within the message, and allows you to choose one or more URLs to send to your Web browser. Alternatively, it send a list of all URLs to standard output. It is a replacement for the @command{urlview} program.") (license license:gpl2))) (define-public tnef (package (name "tnef") (version "1.4.18") (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/verdammelt/tnef") (commit version))) (sha256 (base32 "104g48mcm00bgiyzas2vf86331w7bnw7h3bc11ib4lp7rz6zqfck")) (file-name (git-file-name name version)))) (build-system gnu-build-system) (native-inputs `(("autoconf" ,autoconf) ("automake" ,automake))) (arguments `(#:parallel-tests? #f)) ;tests are side-effect'y (home-page "https://github.com/verdammelt/tnef") (synopsis "Unpack @code{application/ms-tnef} attachments") (description "TNEF is a tar-like program that unpacks MIME attachments of type @code{application/ms-tnef}.") (license license:gpl2+))) (define-public mumi (let ((commit "8c82c8f104ff0013e2bfb3d6b4277280f32446a6") (revision "3")) (package (name "mumi") (version (git-version "0.0.1" revision commit)) (source (origin (method git-fetch) (uri (git-reference (url "https://git.elephly.net/software/mumi.git") (commit commit))) (file-name (git-file-name name version)) (sha256 (base32 "1gkwagy7qplzq2x2zqsbrwhlilxviqb0dqhrvnnhxd7z8wvyzcsi")))) (build-system gnu-build-system) (arguments `(#:modules ((guix build gnu-build-system) ((guix build guile-build-system) #:select (target-guile-effective-version)) (guix build utils)) #:imported-modules ((guix build guile-build-system) ,@%gnu-build-system-modules) #:configure-flags '("--localstatedir=/var") #:phases (modify-phases %standard-phases (add-after 'install 'wrap-executable (lambda* (#:key outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) (bin (string-append out "/bin")) (version (target-guile-effective-version)) (scm (string-append out "/share/guile/site/" version)) (go (string-append out "/lib/guile/" version "/site-ccache"))) (wrap-program (string-append bin "/mumi") `("GUILE_LOAD_PATH" ":" prefix (,scm ,(getenv "GUILE_LOAD_PATH"))) `("GUILE_LOAD_COMPILED_PATH" ":" prefix (,go ,(getenv "GUILE_LOAD_COMPILED_PATH")))) #t)))))) (inputs `(("guile-email" ,guile-email-latest) ("guile-fibers" ,guile-fibers) ("guile-gcrypt" ,guile-gcrypt) ("guile-json" ,guile-json-3) ("guile-redis" ,guile-redis) ("guile-syntax-highlight" ,guile-syntax-highlight) ("guile-webutils" ,guile-webutils) ("guile-xapian" ,guile-xapian) ("guile" ,guile-3.0) ("mailutils" ,mailutils))) (native-inputs `(("autoconf" ,autoconf) ("automake" ,automake) ("pkg-config" ,pkg-config))) (home-page "https://git.elephly.net/software/mumi.git") (synopsis "Debbugs web interface") (description "Mumi is a Debbugs web interface.") (license license:agpl3+)))) (define-public ytnef (package (name "ytnef") (version "1.9.3") (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/Yeraze/ytnef") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 (base32 "07h48s5qf08503pp9kafqbwipdqghiif22ghki7z8j67gyp04l6l")))) (build-system gnu-build-system) (native-inputs `(("autoconf" ,autoconf) ("automake" ,automake) ("libtool" ,libtool))) (home-page "https://github.com/Yeraze/ytnef/") (synopsis "TNEF stream reader for winmail.dat files") (description "This package provides a TNEF stream reader library and related tools to process winmail.dat files.") (license license:gpl2+))) (define-public public-inbox (package (name "public-inbox") (version "1.5.0") (source (origin (method git-fetch) (uri (git-reference (url "https://public-inbox.org") (commit (string-append "v" version)))) (sha256 (base32 "03zj7shdl3vibs7k5lr673bwcf8j1xx8is3mjz34ca4cdh6p5j2k")) (file-name (git-file-name name version)))) (build-system perl-build-system) (arguments '(#:phases (modify-phases %standard-phases (add-before 'configure 'qualify-paths (lambda _ ;; Use absolute paths for 'xapian-compact'. (let ((xapian-compact (which "xapian-compact"))) (substitute* "script/public-inbox-compact" (("xapian-compact") xapian-compact))) #t)) (add-before 'check 'pre-check (lambda _ (substitute* "t/spawn.t" (("\\['env'\\]") (string-append "['" (which "env") "']"))) (substitute* "t/ds-leak.t" (("/bin/sh") (which "sh"))) (invoke "./certs/create-certs.perl") ;; XXX: This test fails due to zombie process is not reaped by ;; the builder. (substitute* "t/httpd-unix.t" (("^SKIP: \\{") "SKIP: { skip('Guix');")) #t)) (add-after 'install 'wrap-programs (lambda* (#:key inputs outputs #:allow-other-keys) (let ((out (assoc-ref outputs "out"))) (for-each (lambda (prog) (wrap-program prog ;; Let those scripts find their perl modules. `("PERL5LIB" ":" prefix (,(string-append out "/lib/perl5/site_perl") ,(getenv "PERL5LIB"))) ;; 'git' is invoked in various files of the PublicInbox ;; perl module. `("PATH" ":" prefix (,(string-append (assoc-ref inputs "git") "/bin"))))) (find-files (string-append out "/bin")))) #t))))) (native-inputs `(("xapian" ,xapian) ;; For testing. ("lsof" ,lsof) ("openssl" ,openssl))) (inputs `(("git" ,git) ("perl-dbd-sqlite" ,perl-dbd-sqlite) ("perl-dbi" ,perl-dbi) ("perl-email-address-xs" ,perl-email-address-xs) ("perl-email-mime-contenttype" ,perl-email-mime-contenttype) ("perl-email-mime" ,perl-email-mime) ("perl-email-simple" ,perl-email-simple) ("perl-net-server" ,perl-net-server) ("perl-filesys-notify-simple" ,perl-filesys-notify-simple) ("perl-plack-middleware-deflater" ,perl-plack-middleware-deflater) ("perl-plack-middleware-reverseproxy" ,perl-plack-middleware-reverseproxy) ("perl-plack" ,perl-plack) ("perl-search-xapian" ,perl-search-xapian) ("perl-timedate" ,perl-timedate) ("perl-uri-escape" ,perl-uri-escape) ;; For testing. ("perl-ipc-run" ,perl-ipc-run) ("perl-xml-feed" ,perl-xml-feed))) (home-page "https://public-inbox.org/README.html") (synopsis "Archive mailing lists in git repositories") (description "public-inbox implements the sharing of an email inbox via git to complement or replace traditional mailing lists. Readers may read via NNTP, Atom feeds or HTML archives.") (license license:agpl3+))) (define-public sylpheed (package (name "sylpheed") (version "3.7.0") (source (origin (method url-fetch) (uri (string-append "https://sylpheed.sraoss.jp/sylpheed/v3.7/" name "-" version ".tar.xz")) (sha256 (base32 "0j9y5vdzch251s264diw9clrn88dn20bqqkwfmis9l7m8vmwasqd")))) (build-system gnu-build-system) (native-inputs `(("pkg-config" ,pkg-config))) (inputs `(("bogofilter" ,bogofilter) ("compface" ,compface) ("gnupg" ,gnupg-1) ("gpgme" ,gpgme) ("gtk+-2.0" ,gtk+-2) ("gtkspell" ,gtkspell3) ("libnsl" ,libnsl) ("openldap" ,openldap) ("openssl" ,openssl))) (home-page "https://sylpheed.sraoss.jp/en/") (synopsis "Lightweight GTK+ email client") (description "Sylpheed is a simple, lightweight but featureful, and easy-to-use e-mail client. Sylpheed provides intuitive user-interface. Sylpheed is also designed for keyboard-oriented operation.") (license license:gpl2+))) (define-public python-authres (package (name "python-authres") (version "1.2.0") (source (origin (method url-fetch) (uri (pypi-uri "authres" version)) (sha256 (base32 "1dr5zpqnb54h4f5ax8334l1dcp8j9083d7v4vdi1xqkwmnavklck")))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases (replace 'check ;; Run doctests as described in the README. (lambda _ (invoke "python" "-m" "authres" "-v")))))) (home-page "https://launchpad.net/authentication-results-python") (synopsis "Authentication-Results email header creator and parser") (description "This Python module can be used to generate and parse RFC 5451/7001/7601 @code{Authentication-Results} email headers. It supports extensions such as: @itemize @item RFC 5617 DKIM/ADSP @item RFC 6008 DKIM signature identification (@code{header.b}) @item RFC 6212 @acronym{VBR, Vouch By Reference} @item RFC 6577 @acronym{SPF, Sender Policy Framework} @item RFC 7281 @code{Authentication-Results} registration for S/MIME @item RFC 7293 The @code{Require-Recipient-Valid-Since} header field @item RFC 7489 @acronym{DMARC, Domain-based Message Authentication Reporting and Conformance} @item @acronym{ARC, Authenticated Received Chain} (draft-ietf-dmarc-arc-protocol-08) @end itemize\n") (license license:asl2.0))) (define-public python-dkimpy (package (name "python-dkimpy") (version "1.0.5") (source (origin (method url-fetch) (uri (pypi-uri "dkimpy" version)) (sha256 (base32 "088iz5cqjqh4c7141d94pvn13bh25aizqlrifwv6fs5g16zj094s")))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases (add-after 'patch-source-shebangs 'patch-more-source (lambda* (#:key inputs #:allow-other-keys) (let ((openssl (assoc-ref inputs "openssl"))) (substitute* "dkim/dknewkey.py" (("/usr/bin/openssl") (string-append openssl "/bin/openssl")))) #t)) (replace 'check (lambda _ (invoke "python" "test.py")))))) (propagated-inputs `(("python-dnspython" ,python-dnspython))) (native-inputs `(("python-authres" ,python-authres) ("python-pynacl" ,python-pynacl))) (inputs `(("openssl" ,openssl))) (home-page "https://launchpad.net/dkimpy") (synopsis "DKIM (DomainKeys Identified Mail)") (description "Python module that implements @dfn{DKIM} (DomainKeys Identified Mail) email signing and verification (RFC6376). It also provides helper scripts for command line signing and verification. It supports DKIM signing/verifying of ed25519-sha256 signatures (RFC 8463). It also supports the RFC 8617 Authenticated Received Chain (ARC) protocol.") (license license:bsd-3))) (define-public python-authheaders (package (name "python-authheaders") (version "0.13.0") (source (origin (method url-fetch) (uri (pypi-uri "authheaders" version)) (sha256 (base32 "14k6i72k5f8dyvps8vc0aq0cczc8lvqpgjfjzsy6qqychjvjcmwk")))) (build-system python-build-system) (propagated-inputs `(("python-authres" ,python-authres) ("python-dkimpy" ,python-dkimpy) ("python-dnspython" ,python-dnspython) ("python-publicsuffix2" ,python-publicsuffix2))) (home-page "https://github.com/ValiMail/authentication-headers") (synopsis "Library wrapping email authentication header verification and generation") (description "This is a Python library for the generation of email authentication headers. The library can perform DKIM, SPF, and DMARC validation, and the results are packaged into the Authentication-Results header. The library can DKIM and ARC sign messages and output the corresponding signature headers.") ;; The package's metadata claims it were MIT licensed, but the source file ;; headers disagree. MPL-2 for the public suffix list. (license (list license:zpl2.1 license:zlib license:mpl2.0)))) (define-public python-aiosmtpd (package (name "python-aiosmtpd") (version "1.2.2") (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/aio-libs/aiosmtpd") (commit version))) (sha256 (base32 "0083d6nf75xv8nq1il6jabz36v6c452svy4p402csxwwih5pw6sk")) (file-name (git-file-name name version)))) (build-system python-build-system) (arguments '(#:phases (modify-phases %standard-phases (add-after 'unpack 'delete-failing-tests (lambda _ ;; This test uses an expired certificate. (delete-file "aiosmtpd/tests/test_smtps.py") #t)) (replace 'check (lambda _ (invoke "python" "-m" "nose2" "-v")))))) (native-inputs `(("python-flufl-testing" ,python-flufl-testing) ("python-nose2" ,python-nose2))) (propagated-inputs `(("python-atpublic" ,python-atpublic))) (home-page "https://aiosmtpd.readthedocs.io/") (synopsis "Asyncio based SMTP server") (description "This project is a reimplementation of the Python stdlib @code{smtpd.py} based on asyncio.") (license (list license:asl2.0 license:lgpl3)))) ; only for setup_helpers.py (define-public rspamd (package (name "rspamd") (version "2.7") (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/rspamd/rspamd") (commit version))) (sha256 (base32 "0fw6nbfc3xqapzq5nydakwgpw6cz6vb3qby2aqlr06lzf87d3hic")) (file-name (git-file-name name version)))) (build-system cmake-build-system) (arguments '(#:configure-flags '("-DENABLE_LUAJIT=ON"))) (inputs `(("openssl" ,openssl) ("glib" ,glib) ("ragel" ,ragel) ("luajit" ,luajit) ("sqlite" ,sqlite) ("file" ,file) ("icu4c" ,icu4c) ("pcre" ,pcre) ("zlib" ,zlib) ("perl" ,perl) ("libsodium" ,libsodium))) (native-inputs `(("pkg-config" ,pkg-config))) (synopsis "Spam filtering system") (description "Rspamd is an advanced spam filtering system that allows evaluation of messages by a number of rules including regular expressions, statistical analysis and custom services such as URL black lists. Each message is analysed by Rspamd and given a spam score.") (home-page "https://www.rspamd.com/") (license license:asl2.0)))