CVE-2021-40347: Postorius GNU Mailman Postorius Access Control Vulnerability

MODERATE
Advisory Identifier: GHSA-v83x-78q3-gr2j
CVSS 5.4
CWE-284
Published
Advisory Summary

CVE-2021-40347 is a MODERATE (CVSS 5.4) gnu mailman postorius access control vulnerability (CWE-284: Improper Access Control) affecting Postorius libraries in the PyPI ecosystem. The issue involves gnu mailman postorius access control issues. Remediation is available by upgrading affected packages to version 1.3.5.

CVE-2021-40347 at a Glance

CVE Identifier CVE-2021-40347
GHSA Identifier GHSA-v83x-78q3-gr2j
Severity MODERATE
CVSS v3.1 Base Score 5.4
CWE Classification CWE-284: Improper Access Control
Affected Product Postorius
Package Ecosystem PyPI
Published Date
Last Updated

Security Impact

CVSS: 5.4

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required Low (PR:L)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality Low (C:L)
Integrity Low (I:L)
Availability None (A:N)

How to Fix CVE-2021-40347

To remediate this vulnerability, upgrade all affected Postorius dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

postorius fixed: 1.3.5
pip install postorius>=1.3.5
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

pip show postorius

How to Check if You Are Affected

To determine whether your Python environment is affected by CVE-2021-40347, inspect your installed packages using pip:

pip show postorius

Analyze the terminal output to locate any version of Postorius in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.3.5), your application is affected.

Note: The pip show postorius command checks currently installed packages in your active Python environment.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-284: Improper Access Control, where the product does not restrict or incorrectly restricts access to a resource from an unauthorized actor. In Postorius, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

An issue was discovered in `views/list.py` in GNU Mailman Postorius before 1.3.5. An attacker (logged into any account) can send a crafted POST request to unsubscribe any user from a mailing list, also revealing whether that address was subscribed in the first place.

CVE-2021-40347 Affected Postorius Versions

1 component(s)
Fixed Versions:
1.3.5
Product / Package Ecosystem Affected Versions Fixed Version
postorius
PyPI
< 1.3.5
1.3.5

References

Frequently Asked Questions

What is CVE-2021-40347?
CVE-2021-40347 is a security vulnerability in Postorius involving GNU Mailman Postorius Access Control Issues under CWE-284: Improper Access Control.
Which Postorius versions are affected?
Affected versions include releases prior to 1.3.5 across affected packages: postorius.
What version fixes CVE-2021-40347?
Upgrading to 1.3.5 (or the latest patched release for your respective branch) resolves the vulnerability.
Is postorius affected?
Yes, postorius is affected in releases prior to 1.3.5. Upgrade your dependency to 1.3.5 or later.
What is the CVSS score of CVE-2021-40347?
CVE-2021-40347 has a CVSS v3.1 base score of 5.4 (MODERATE) with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N.
What CWE is associated with CVE-2021-40347?
CVE-2021-40347 is classified under CWE-284: Improper Access Control (The product does not restrict or incorrectly restricts access to a resource from an unauthorized actor.).
How can I check PyPI dependencies for CVE-2021-40347?
Run the dependency tree command: 'pip show postorius'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-v83x-78q3-gr2j",
  "modified" : "2024-10-21T20:10:57Z",
  "published" : "2022-05-24T19:14:08Z",
  "aliases" : [ "CVE-2021-40347" ],
  "summary" : "GNU Mailman Postorius Access Control Issues",
  "details" : "An issue was discovered in `views/list.py` in GNU Mailman Postorius before 1.3.5. An attacker (logged into any account) can send a crafted POST request to unsubscribe any user from a mailing list, also revealing whether that address was subscribed in the first place.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:N"
  }, {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "postorius"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "1.3.5"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2021-40347"
  }, {
    "type" : "WEB",
    "url" : "https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=993746"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/pypa/advisory-database/tree/main/vulns/postorius/PYSEC-2021-319.yaml"
  }, {
    "type" : "PACKAGE",
    "url" : "https://gitlab.com/mailman/postorius"
  }, {
    "type" : "WEB",
    "url" : "https://gitlab.com/mailman/postorius/-/commit/3d880c56b58bc26b32eac0799407d74b64b7474b"
  }, {
    "type" : "WEB",
    "url" : "https://gitlab.com/mailman/postorius/-/issues/531"
  }, {
    "type" : "WEB",
    "url" : "https://gitlab.com/mailman/postorius/-/tags"
  }, {
    "type" : "WEB",
    "url" : "https://phabricator.wikimedia.org/T289798"
  }, {
    "type" : "WEB",
    "url" : "https://www.debian.org/security/2021/dsa-4970"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-284" ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2024-04-22T22:50:22Z",
    "nvd_published_at" : "2021-09-10T19:15:00Z"
  }
}