CVE-2021-43821: Opencast ingest service impl Files Accessible To External Parties Vulnerability

CRITICAL
Advisory Identifier: GHSA-59g4-hpg3-3gcp
CVSS 9.9
CWE-552
Published
Advisory Summary

CVE-2021-43821 is a CRITICAL (CVSS 9.9) files accessible to external parties vulnerability (CWE-552: Files or Directories Accessible to External Parties) affecting Opencast ingest service impl libraries in the Maven ecosystem. The issue involves files accessible to external parties in opencast. Remediation is available by upgrading affected packages to version 10.6.

CVE-2021-43821 at a Glance

CVE Identifier CVE-2021-43821
GHSA Identifier GHSA-59g4-hpg3-3gcp
Severity CRITICAL
CVSS v3.1 Base Score 9.9
CWE Classification CWE-552: Files or Directories Accessible to External Parties
Affected Product Opencast ingest service impl
Package Ecosystem Maven
Published Date
Last Updated

Security Impact

CVSS: 9.9

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:C/C:H/I:H/A:H).

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

How to Fix CVE-2021-43821

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

org.opencastproject:opencast-ingest-service-impl fixed: 10.6
<dependency>
    <groupId>org.opencastproject</groupId>
    <artifactId>opencast-ingest-service-impl</artifactId>
    <version>10.6</version>
</dependency>
Verify Direct and Transitive Dependencies

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

mvn dependency:tree -Dincludes=org.opencastproject

How to Check if You Are Affected

To determine whether your Java application is affected by CVE-2021-43821, inspect your build dependencies using the Maven Dependency Plugin:

mvn dependency:tree -Dincludes=org.opencastproject

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

Note: The mvn dependency:tree -Dincludes=org.opencastproject command inspects the resolved dependency graph declared in your project's POM files; it does not perform automated security scanning or inspect runtime dynamic classpaths. Always verify runtime container classpaths and shaded JARs.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-552: Files or Directories Accessible to External Parties, where the product makes files or directories accessible to unauthorized actors, even though they should not be. In Opencast ingest service impl, 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

Opencast before version 10.6 allows references to local file URLs in ingested media packages, allowing attackers to include local files from Opencast's host machines and making them available via the web interface. ### Impact Before Opencast 10.6, Opencast would [open and include local files during ingests](https://github.com/opencast/opencast/blob/69952463971cf578363e3b97d8edaf334ff51253/modules/ingest-service-impl/src/main/java/org/opencastproject/ingest/impl/IngestServiceImpl.java#L1587). Attackers could exploit this to include most local files the process has read access to, extracting secrets from the host machine. For example, to expose the `custom.properties` of develop.opencast.org via the asset manager, an attacker could have run: ``` curl -f -i -u admin:opencast \ https://develop.opencast.org/ingest/addMediaPackage/fast \ -F 'flavor=presenter/source'\ -F mediaUri=file:///srv/opencast/opencast-dist-allinone/etc/custom.properties\ -F title="custom.properties" ``` An attacker would need to have the privileges required to add new media to exploit this. But these are often widely given. ### Patches The issue has been fixed in Opencast 10.6 and 11.0. ### Workarounds You can mitigate this issue by narrowing down the read access Opencast has to files on the file system using UNIX permissions or mandatory access control systems like SELinux. This cannot prevent access to files Opencast needs to read though and we highly recommend updating. ### References - [Example of problematic code](https://github.com/opencast/opencast/blob/69952463971cf578363e3b97d8edaf334ff51253/modules/ingest-service-impl/src/main/java/org/opencastproject/ingest/impl/IngestServiceImpl.java#L1587). - [Patch fixing the issue](https://github.com/opencast/opencast/commit/65c46b9d3e8f045c544881059923134571897764) ### For more information If you have any questions or comments about this advisory: * Open an issue in [our issue tracker](https://github.com/opencast/opencast/issues) * Email us at [security@opencast.org](mailto:security@opencast.org)

CVE-2021-43821 Affected Opencast ingest service impl Versions

1 component(s)
Fixed Versions:
10.6
Product / Package Ecosystem Affected Versions Fixed Version
org.opencastproject:opencast-ingest-service-impl
Maven
< 10.6
10.6

References

Frequently Asked Questions

What is CVE-2021-43821?
CVE-2021-43821 is a security vulnerability in Opencast ingest service impl involving Files Accessible to External Parties in Opencast under CWE-552: Files or Directories Accessible to External Parties.
Which Opencast ingest service impl versions are affected?
Affected versions include releases prior to 10.6 across affected packages: org.opencastproject:opencast-ingest-service-impl.
What version fixes CVE-2021-43821?
Upgrading to 10.6 (or the latest patched release for your respective branch) resolves the vulnerability.
Is opencast-ingest-service-impl affected?
Yes, org.opencastproject:opencast-ingest-service-impl is affected in releases prior to 10.6. Upgrade your dependency to 10.6 or later.
What is the CVSS score of CVE-2021-43821?
CVE-2021-43821 has a CVSS v3.1 base score of 9.9 (CRITICAL) with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H.
What CWE is associated with CVE-2021-43821?
CVE-2021-43821 is classified under CWE-552: Files or Directories Accessible to External Parties (The product makes files or directories accessible to unauthorized actors, even though they should not be.).
How can I check Maven dependencies for CVE-2021-43821?
Run the dependency tree command: 'mvn dependency:tree -Dincludes=org.opencastproject'. 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-59g4-hpg3-3gcp",
  "modified" : "2022-01-04T18:53:43Z",
  "published" : "2021-12-14T21:44:03Z",
  "aliases" : [ "CVE-2021-43821" ],
  "summary" : "Files Accessible to External Parties in Opencast",
  "details" : "Opencast before version 10.6 allows references to local file URLs in ingested media packages, allowing attackers to include local files from Opencast's host machines and making them available via the web interface.\n\n### Impact\n\nBefore Opencast 10.6, Opencast would [open and include local files during ingests](https://github.com/opencast/opencast/blob/69952463971cf578363e3b97d8edaf334ff51253/modules/ingest-service-impl/src/main/java/org/opencastproject/ingest/impl/IngestServiceImpl.java#L1587). Attackers could exploit this to include most local files the process has read access to, extracting secrets from the host machine.\n\nFor example, to expose the `custom.properties` of develop.opencast.org via the asset manager, an attacker could have run:\n\n```\ncurl -f -i -u admin:opencast \\\n  https://develop.opencast.org/ingest/addMediaPackage/fast \\\n  -F 'flavor=presenter/source'\\\n  -F mediaUri=file:///srv/opencast/opencast-dist-allinone/etc/custom.properties\\\n  -F title=\"custom.properties\"  \n```\n\nAn attacker would need to have the privileges required to add new media to exploit this. But these are often widely given.\n\n\n### Patches\n\nThe issue has been fixed in Opencast 10.6 and 11.0.\n\n### Workarounds\n\nYou can mitigate this issue by narrowing down the read access Opencast has to files on the file system using UNIX permissions or mandatory access control systems like SELinux. This cannot prevent access to files Opencast needs to read though and we highly recommend updating.\n\n### References\n\n-  [Example of problematic code](https://github.com/opencast/opencast/blob/69952463971cf578363e3b97d8edaf334ff51253/modules/ingest-service-impl/src/main/java/org/opencastproject/ingest/impl/IngestServiceImpl.java#L1587).\n- [Patch fixing the issue](https://github.com/opencast/opencast/commit/65c46b9d3e8f045c544881059923134571897764)\n\n### For more information\n\nIf you have any questions or comments about this advisory:\n* Open an issue in [our issue tracker](https://github.com/opencast/opencast/issues)\n* Email us at [security@opencast.org](mailto:security@opencast.org)\n",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Maven",
      "name" : "org.opencastproject:opencast-ingest-service-impl"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "10.6"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/opencast/opencast/security/advisories/GHSA-59g4-hpg3-3gcp"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2021-43821"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/opencast/opencast/commit/65c46b9d3e8f045c544881059923134571897764"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/opencast/opencast"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/opencast/opencast/blob/69952463971cf578363e3b97d8edaf334ff51253/modules/ingest-service-impl/src/main/java/org/opencastproject/ingest/impl/IngestServiceImpl.java#L1587"
  }, {
    "type" : "WEB",
    "url" : "https://mvnrepository.com/artifact/org.opencastproject/opencast-ingest-service-impl"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-552" ],
    "severity" : "CRITICAL",
    "github_reviewed" : true,
    "github_reviewed_at" : "2021-12-14T19:29:54Z",
    "nvd_published_at" : "2021-12-14T20:15:00Z"
  }
}