From: Michael Orlitzky Date: Sun, 28 Aug 2022 15:21:25 +0000 (-0400) Subject: list-remote-forwards.cabal: update for newer cabal and ghc-9.x. X-Git-Tag: 0.0.2~2 X-Git-Url: https://gitweb.michael.orlitzky.com/?a=commitdiff_plain;h=79c47dbf0a6fbe108fbf604ce695582910eef8fc;p=list-remote-forwards.git list-remote-forwards.cabal: update for newer cabal and ghc-9.x. --- diff --git a/list-remote-forwards.cabal b/list-remote-forwards.cabal index 08f3c98..eae777b 100644 --- a/list-remote-forwards.cabal +++ b/list-remote-forwards.cabal @@ -1,9 +1,9 @@ +cabal-version: 3.0 name: list-remote-forwards version: 0.0.1 -cabal-version: >= 1.8 author: Michael Orlitzky maintainer: Michael Orlitzky -license: AGPL-3 +license: AGPL-3.0-only license-file: doc/LICENSE bug-reports: mailto:michael@orlitzky.com category: Mail, Utils @@ -16,125 +16,125 @@ synopsis: List all remote forwards for mail accounts stored in a SQL database. description: /Usage/: - . + @ list-remote-forwards [OPTIONS] @ - . + List all remote forwards for mail accounts stored in a SQL database. - . + A list of local domains is supplied to the program (more or less) through the @--domain-query@ option. Any addresses which forward to another address not contained in this list of local domains is considered a remote forward. Remote forwards can cause problems for a number of reasons, the most common of which are, - . + * If the sender has an SPF record authorizing his mail server to send mail on his behalf, then when his message is forwarded by the recipient's mail server, it will fail any subsequent SPF checks. This will likely cause the message to be rejected, and the original recipient's server will generate backscatter. - . + * If any spam makes it through the filter on the recipient's mail server, that spam will then be forwarded to a remote destination. The remote destination will blame the forwarding server for the spam, and that can impact its reputation and potentially lead to a blacklisting even though the spam did not originate on the recipient's server. - . + Whether or not these are an issue depends on the circumstances, but in any case it is useful to know who is forwarding mail off-site. - . + /Input:/ - . + None. - . + /Output:/ - . + A list of addresses that are forwarded to remote domains. - . + /Options/: - . + @ \--database @ - . + The name of the database (or file, if SQLite) to which we should connect. - . + Default: The name of the current user (Postgres only). - . + @ \--domain-query @ SQL query used to produce a list of local domains. This should return the set of all domains (i.e one column) that are local to the server. See the default value for an example. - . + Default: \"SELECT domain FROM domain WHERE domain <> 'ALL' ORDER BY domain;\" - . + @ \--exclude-mx, -e @ - . + The name of a mail exchanger, the forwards of whose domains we should ignore. For example, if one mail exchanger, mx1.example.com, has strict spam filtering, it may be acceptable to have remote forwarding for domains that have mx1.example.com as their sole mail exchanger (MX record). In that case, you might want to exclude those domains from the report by naming mx1.example.com here. - . + A forward will be excluded from the report only if /all/ of its MX records are contained in the given exclude list. - . + This option can be repeated to add mail exchangers to the exclude list. - . + Default: [] (empty) - . + @ \--forward-query, -f @ - . + SQL query used to produce a list of all forwards on the mail system. This query should return the set of all (address, goto) triples, where \"goto\" is the destination address; i.e. to where the \"address\" forwards. The \"goto\" field may contain more than one email address, separated by commas. - . + Default: \"SELECT address,goto FROM alias ORDER BY address;\" - . + @ \--host, -h @ - . + Hostname where the database is located (Postgres-only). - . + Default: None, a UNIX domain socket connection is attempted (Postgres only) - . + @ \--password @ - . + Password used to connect to the database (Postgres-only). - . + Default: None (assumes passwordless authentication) - . + @ \--port @ Port number used to connect to the database (Postgres-only). - . + Default: None, a UNIX domain socket connection is attempted (Postgres only) - . + @ \--username, -u @ - . + Username used to connect to the database (Postgres-only). - . + Default: The current user - . + /Examples/: - . + @ $ list-remote-forwards --database=test\/fixtures\/postfixadmin.sqlite3 user1@example.com -> user1@example.net @@ -146,7 +146,7 @@ description: executable list-remote-forwards build-depends: - base >= 4.6 && < 5, + base >= 4.15 && < 5, bytestring >= 0.10, cmdargs >= 0.10, configurator >= 0.2, @@ -160,6 +160,10 @@ executable list-remote-forwards MissingH >= 1.2, tasty >= 0.8, tasty-hunit >= 0.8 + + default-language: + Haskell2010 + main-is: Main.hs @@ -177,9 +181,13 @@ executable list-remote-forwards Report String + autogen-modules: + Paths_list_remote_forwards + test-suite testsuite type: exitcode-stdio-1.0 hs-source-dirs: src test + default-language: Haskell2010 main-is: TestSuite.hs other-modules: @@ -191,8 +199,11 @@ test-suite testsuite Paths_list_remote_forwards Report + autogen-modules: + Paths_list_remote_forwards + build-depends: - base >= 4.6 && < 5, + base >= 4.15 && < 5, bytestring >= 0.10, cmdargs >= 0.10, configurator >= 0.2, @@ -209,9 +220,10 @@ test-suite testsuite test-suite doctests type: exitcode-stdio-1.0 hs-source-dirs: test + default-language: Haskell2010 main-is: Doctests.hs build-depends: - base == 4.*, + base >= 4.15 && < 5, -- Additional test dependencies. doctest >= 0.9, filemanip >= 0.3.6