Vulnerabilities in pkg:gem/publify_core

PACKAGE
Advisory Identifier: GHSA-8fm5-gg2f-f66q
Advisory Summary

CVE-2024-39311 is a LOW cross-site scripting vulnerability (CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')) affecting Publify core libraries in the RubyGems ecosystem. The issue involves publify vulnerable to cross-site scripting (xss) via redirects requiring user interaction. Remediation is available by upgrading affected packages to version 10.0.2.

15 Known Advisory Record(s)
Package Vulnerability Intelligence

pkg:gem/publify_core

15 Known Advisory Record(s)

Vulnerability advisories affecting package pkg:gem/publify_core. Select an advisory below to view technical details or fixes.

Advisory ID CVE / NVD Severity Summary
GHSA-8fm5-gg2f-f66q CVE-2024-39311 LOW Publify Vulnerable To Cross-Site Scripting (XSS) Via Redirects Requiring User Interaction
GHSA-x3rq-r3cm-5vc4 CVE-2022-0524 HIGH Publify Business Logic Errors
GHSA-c273-c6vg-4pv5 CVE-2022-1810 MODERATE Publify has Improper Access Controls
GHSA-3hwx-c6cp-q972 CVE-2022-1811 CRITICAL Publify vulnerable to cross site scripting
GHSA-5jm7-g527-m694 CVE-2022-1553 MODERATE Publify exposes article metadata
GHSA-w78q-4w34-jrjx CVE-2022-0578 MODERATE Publify vulnerable to code injection
GHSA-79m3-q3wh-c3qm CVE-2022-0574 MODERATE Publify Incorrect Authorization
GHSA-vq74-9583-hrm4 CVE-2014-3211 HIGH Publify vulnerable to DoS attack
GHSA-g7gf-2rqw-5rwx CVE-2023-0569 MODERATE Publify contains Weak Password Requirements
GHSA-rc42-jghf-vr8f CVE-2022-1812 CRITICAL Integer overflow in publify_core
GHSA-q3rm-f527-ghxj CVE-2023-0299 CRITICAL Publify Improper Input Validation vulnerability
GHSA-79wq-g4v9-gfj4 CVE-2022-2815 MODERATE Publify Core does not strip metadata from images
GHSA-x24j-87x9-jvv5 CVE-2021-25973 MODERATE Publify `guest` role users can self-register even when the admin does not allow it
GHSA-wmh9-x28j-c6gr CVE-2021-25974 MODERATE Cross site scripting in publify
GHSA-3h7v-wqw7-ff28 CVE-2021-25975 MODERATE Cross site scripting in publify

CVE-2024-39311 at a Glance

CVE Identifier CVE-2024-39311
GHSA Identifier GHSA-8fm5-gg2f-f66q
Severity LOW
CVSS v3.1 Base Score N/A
CWE Classification CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')
Affected Product Publify core
Package Ecosystem RubyGems
Published Date
Last Updated

How to Fix CVE-2024-39311

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

publify_core fixed: 10.0.2
Upgrade publify_core to 10.0.2
Verify Direct and Transitive Dependencies

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

inspect dependencies for publify_core

How to Check if You Are Affected

To determine whether your application is affected by CVE-2024-39311, inspect your project dependencies for Publify core:

inspect dependencies for publify_core

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

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting'), where the product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. In Publify core, 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

### Summary A publisher on a `publify` application is able to perform a cross-site scripting attack on an administrator using the redirect functionality. ### Details A publisher on a `publify` application is able to perform a cross-site scripting attack on an administrator using the redirect functionality. The exploitation of this XSS vulnerability requires the administrator to click a malicious link. We can create a redirect to a `javascript:alert()` URL. Whilst the redirect itself doesn't work, on the administrative panel, an a tag is created with the payload as the URI. Upon clicking this link, the XSS is triggered. An attack could attempt to hide their payload by using HTML, or other encodings, as to not make it obvious to an administrator that this is a malicious link. ### PoC A publisher can create a new redirect as shown below. The payload used is `javascript:alert()`. ![image](https://user-images.githubusercontent.com/44903767/295206083-3cf432c6-1f58-49a2-b09c-777e9707e0ff.png) An administrator will now see this redirect in their overview of the page. ![image](https://user-images.githubusercontent.com/44903767/295206204-3d4dc59a-8f82-42f3-98b2-a1809790351f.png) If they click the link on the right, it triggers the XSS. ![image](https://user-images.githubusercontent.com/44903767/295206292-3fea85f5-6918-4eff-8206-4a275a6e79e4.png) ### Impact A publisher may attempt to use this vulnerability to escalate their privileges and become an administrator.

CVE-2024-39311 Affected Publify core Versions

1 component(s)
Fixed Versions:
10.0.2
Product / Package Ecosystem Affected Versions Fixed Version
publify_core
RubyGems
< 10.0.2
10.0.2

References

Frequently Asked Questions

What is CVE-2024-39311?
CVE-2024-39311 is a security vulnerability in Publify core involving Publify Vulnerable To Cross-Site Scripting (XSS) Via Redirects Requiring User Interaction under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting').
Which Publify core versions are affected?
Affected versions include releases prior to 10.0.2 across affected packages: publify_core.
What version fixes CVE-2024-39311?
Upgrading to 10.0.2 (or the latest patched release for your respective branch) resolves the vulnerability.
Is publify_core affected?
Yes, publify_core is affected in releases prior to 10.0.2. Upgrade your dependency to 10.0.2 or later.
What CWE is associated with CVE-2024-39311?
CVE-2024-39311 is classified under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting') (The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.).
How can I check RubyGems dependencies for CVE-2024-39311?
Run the dependency tree command: 'inspect dependencies for publify_core'. 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-8fm5-gg2f-f66q",
  "modified" : "2025-03-28T16:34:33Z",
  "published" : "2025-03-28T16:34:33Z",
  "aliases" : [ "CVE-2024-39311" ],
  "summary" : "Publify Vulnerable To Cross-Site Scripting (XSS) Via Redirects Requiring User Interaction",
  "details" : "### Summary\nA publisher on a `publify` application is able to perform a cross-site scripting attack on an administrator using the redirect functionality.\n\n### Details\nA publisher on a `publify` application is able to perform a cross-site scripting attack on an administrator using the redirect functionality. The exploitation of this XSS vulnerability requires the administrator to click a malicious link.\n\nWe can create a redirect to a `javascript:alert()` URL. Whilst the redirect itself doesn't work, on the administrative panel, an a tag is created with the payload as the URI. Upon clicking this link, the XSS is triggered. \n\nAn attack could attempt to hide their payload by using HTML, or other encodings, as to not make it obvious to an administrator that this is a malicious link.\n\n### PoC\nA publisher can create a new redirect as shown below. The payload used is `javascript:alert()`.\n![image](https://user-images.githubusercontent.com/44903767/295206083-3cf432c6-1f58-49a2-b09c-777e9707e0ff.png)\n\nAn administrator will now see this redirect in their overview of the page.\n![image](https://user-images.githubusercontent.com/44903767/295206204-3d4dc59a-8f82-42f3-98b2-a1809790351f.png)\n\nIf they click the link on the right, it triggers the XSS.\n![image](https://user-images.githubusercontent.com/44903767/295206292-3fea85f5-6918-4eff-8206-4a275a6e79e4.png)\n\n### Impact\nA publisher may attempt to use this vulnerability to escalate their privileges and become an administrator.",
  "severity" : [ {
    "type" : "CVSS_V4",
    "score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:A/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N/E:P"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "RubyGems",
      "name" : "publify_core"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "10.0.2"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/publify/publify/security/advisories/GHSA-8fm5-gg2f-f66q"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2024-39311"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/publify/publify"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-79" ],
    "severity" : "LOW",
    "github_reviewed" : true,
    "github_reviewed_at" : "2025-03-28T16:34:33Z",
    "nvd_published_at" : "2025-03-28T15:15:44Z"
  }
}