Skip to content
Fencer Vulns
medium 4.3

CVE-2021-3856 json

Keycloak has Files or Directories Accessible to External Parties

published 2022-08-26 4 y ago modified 2026-06-17 4 mo ago also GHSA-3w4v-rvc4-2xpw , EUVD-2022-6472

cvss
4.3
version 3.1, NVD
cisa kev
Not listed
not in CISA's catalog
epss
1.2%
EPSS 1.2% chance of exploitation in 30 days, percentile 67%
public exploits
0
none known

Summary

ClassLoaderTheme and ClasspathThemeResourceProviderFactory allows reading any file available as a resource to the classloader. By sending requests for theme resources with a relative path from an external HTTP client, the client will receive the content of random files if available.

Patch / fix

  • maven org.keycloak:keycloak-core 15.1.0
  • redhat keycloak 15.1.0
  • rh-sso7 red hat single sign on 7.6 1-4.el7sso
  • rh-sso7-runtime red hat single sign on 7.6 1-4.el7sso
  • rh-sso7-keycloak red hat single sign on 7.6 18.0.0-2.redhat_00001.1.el7sso
  • rh-sso7-keycloak-server red hat single sign on 7.6 18.0.0-2.redhat_00001.1.el7sso
  • rh-sso7-javapackages-tools red hat single sign on 7.6 3.4.1-5.15.3.jbcs.el7
  • rh-sso7-python-javapackages red hat single sign on 7.6 3.4.1-5.15.3.jbcs.el7
  • rh-sso7 red hat single sign on 7.6 1-4.el8sso
  • rh-sso7-runtime red hat single sign on 7.6 1-4.el8sso

red hat advisories RHBA-2022:5452RHBA-2022:5454

Vendor advisories

What the vendors themselves say about their products: affected, fixed or not affected, and what to do.

red hat product security vex CVE-2021-3856 updated cvss 4.3

keycloak-services: ClassLoaderTheme and ClasspathThemeResourceProviderFactory allows reading any file available as a resource to the classloader

  • Red Hat A-MQ Online keycloak-services
    affected: no fix planned “Out of support scope”
  • Red Hat Single Sign-On 7.6 for RHEL 7 Server rh-sso7 1-4.el7sso, rh-sso7-runtime 1-4.el7sso, rh-sso7-keycloak 18.0.0-2.redhat_00001.1.el7sso, rh-sso7-javapackages-tools 3.4.1-5.15.3.jbcs.el7, rh-sso7-python-javapackages 3.4.1-5.15.3.jbcs.el7, rh-sso7-keycloak-server 18.0.0-2.redhat_00001.1.el7sso
    fixed: vendor fix RHBA-2022:5452
  • Red Hat Single Sign-On 7.6 for RHEL 8 rh-sso7 1-4.el8sso, rh-sso7-runtime 1-4.el8sso, rh-sso7-javapackages-tools 3.4.1-5.15.6.el8sso, rh-sso7-keycloak 18.0.0-2.redhat_00001.1.el8sso, rh-sso7-python3-javapackages 3.4.1-5.15.6.el8sso, rh-sso7-keycloak-server 18.0.0-2.redhat_00001.1.el8sso
    fixed: vendor fix RHBA-2022:5454

Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf

Exploit prediction

1.16% chance of exploitation in the next 30 days, higher than 67% of all scored CVEs (FIRST EPSS, 2026-11-08).

CVSS scores

assigned by version score vector
NVD 3.1 4.3 CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N
GitHub 3.1 4.3 CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:N/A:N

Affected packages

ecosystem package affected fixed in
maven org.keycloak:keycloak-core
<15.1.0
15.1.0

Affected products

  • n/a keycloak

Classification

Weakness
  • CWE-552 Files or Directories Accessible to External Parties
  • CWE-22 Improper Limitation of a Pathname to a Restricted Directory

References

Sources

Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.