{"id":"CVE-2024-41677","aliases":["EUVD-2024-2469","GHSA-2rwj-7xq8-4gx4"],"status":"published","title":"Cross-site Scripting (XSS) vulnerability due to improper HTML escaping in qwik","description":"Qwik is a performance focused javascript framework. A potential mutation XSS vulnerability exists in Qwik for versions up to but not including 1.6.0. Qwik improperly escapes HTML on server-side rendering. It converts strings according to the rules found in the `render-ssr.ts` file. It sometimes causes the situation that the final DOM tree rendered on browsers is different from what Qwik expects on server-side rendering. This may be leveraged to perform XSS attacks, and a type of the XSS is known as mXSS (mutation XSS). This has been resolved in qwik version 1.6.0 and @builder.io/qwik version 1.7.3. All users are advised to upgrade. There are no known workarounds for this vulnerability.","severity":{"version":"3.1","score":6.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:L","level":"medium","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-10","score":0.00497,"percentile":0.42958,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-79"],"published":"2024-08-06T17:52:14Z","modified":"2026-10-28T02:30:44Z","fixes":[{"ecosystem":"npm","package":"@builder.io/qwik","fixed_in":["1.7.3"],"sources":["ghsa","osv"]}],"affected":[{"source":"ghsa","ecosystem":"npm","package":"@builder.io/qwik","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.7.3"}]}]},{"source":"osv","ecosystem":"npm","package":"@builder.io/qwik","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"1.7.3"}]}]}],"products":[{"vendor":"qwik","product":"qwik"},{"vendor":"qwikdev","product":"qwik"}],"references":[{"url":"https://github.com/QwikDev/qwik/security/advisories/GHSA-2rwj-7xq8-4gx4","tags":["x_refsource_CONFIRM","Exploit","Vendor Advisory","advisory","web"]},{"url":"https://github.com/QwikDev/qwik/commit/7e742eb3a1001542d795776c0317d47df8b9d64e","tags":["x_refsource_MISC","Patch","fix","web"]},{"url":"https://github.com/QwikDev/qwik/blob/v1.5.5/packages/qwik/src/core/render/ssr/render-ssr.ts#L1182-L1208","tags":["x_refsource_MISC","Product","web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2024-41677","tags":["advisory"]},{"url":"https://github.com/advisories/GHSA-2rwj-7xq8-4gx4"},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/41xxx/CVE-2024-41677.json","tags":["advisory"]},{"url":"https://github.com/QwikDev/qwik","tags":["package"]}],"sources":{"cve":[{"id":"CVE-2024-41677","title":"Cross-site Scripting (XSS) vulnerability due to improper HTML escaping in qwik","description":"Qwik is a performance focused javascript framework. A potential mutation XSS vulnerability exists in Qwik for versions up to but not including 1.6.0. Qwik improperly escapes HTML on server-side rendering. It converts strings according to the rules found in the `render-ssr.ts` file. It sometimes causes the situation that the final DOM tree rendered on browsers is different from what Qwik expects on server-side rendering. This may be leveraged to perform XSS attacks, and a type of the XSS is known as mXSS (mutation XSS). This has been resolved in qwik version 1.6.0 and @builder.io/qwik version 1.7.3. All users are advised to upgrade. There are no known workarounds for this vulnerability.","status":"published","published":"2024-08-06T17:52:14.648Z","modified":"2024-08-08T19:04:29.078Z","cvss":[{"version":"3.1","score":6.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:L","level":"medium","assessor":"cna"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T14:34:03.661584Z"}],"euvd":[{"id":"EUVD-2024-2469","description":"Qwik is a performance focused javascript framework. A potential mutation XSS vulnerability exists in Qwik for versions up to but not including 1.6.0. Qwik improperly escapes HTML on server-side rendering. It converts strings according to the rules found in the `render-ssr.ts` file. It sometimes causes the situation that the final DOM tree rendered on browsers is different from what Qwik expects on server-side rendering. This may be leveraged to perform XSS attacks, and a type of the XSS is known as mXSS (mutation XSS). This has been resolved in qwik version 1.6.0 and @builder.io/qwik version 1.7.3. All users are advised to upgrade. There are no known workarounds for this vulnerability.","status":"published","published":"2024-08-06T17:52:14Z","modified":"2024-08-08T19:04:29Z","cvss":[{"version":"3.1","score":6.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:L","level":"medium"}],"updated_at":"2026-11-03T00:56:21.653692Z"}],"ghsa":[{"id":"GHSA-2rwj-7xq8-4gx4","title":"Qwik has a potential mXSS vulnerability due to improper HTML escaping","description":"### Summary\n\nA potential mXSS vulnerability exists in Qwik for versions up to 1.6.0.\n\n### Details\n\nQwik improperly escapes HTML on server-side rendering. It converts strings according to the following rules:\n\nhttps://github.com/QwikDev/qwik/blob/v1.5.5/packages/qwik/src/core/render/ssr/render-ssr.ts#L1182-L1208\n\n- If the string is an attribute value:\n    - `\"` -\u003e `\u0026quot;`\n    - `\u0026` -\u003e `\u0026amp;`\n    - Other characters -\u003e No conversion\n- Otherwise:\n    - `\u003c` -\u003e `\u0026lt;`\n    - `\u003e` -\u003e `\u0026gt;`\n    - `\u0026` -\u003e `\u0026amp;`\n    - Other characters -\u003e No conversion\n\nIt sometimes causes the situation that the final DOM tree rendered on browsers is different from what Qwik expects on server-side rendering. This may be leveraged to perform XSS attacks, and a type of the XSS is known as mXSS (mutation XSS).\n\n## PoC\n\nA vulnerable component:\n```javascript\nimport { component$ } from \"@builder.io/qwik\";\nimport { useLocation } from \"@builder.io/qwik-city\";\n\nexport default component$(() =\u003e {\n  \n  // user input\n  const { url } = useLocation();\n  const href = url.searchParams.get(\"href\") ?? \"https://example.com\";\n\n  return (\n    \u003cdiv\u003e\n      \u003cnoscript\u003e\n        \u003ca href={href}\u003etest\u003c/a\u003e\n      \u003c/noscript\u003e\n    \u003c/div\u003e\n  );\n});\n```\n\nIf a user accesses the following URL,\n```\nhttp://localhost:4173/?href=\u003c/noscript\u003e\u003cscript\u003ealert(123)\u003c/script\u003e\n```\nthen, `alert(123)` will be executed.\n\n### Impact\n\nXSS","status":"published","published":"2024-08-06T18:24:47Z","modified":"2024-08-07T07:55:48Z","cvss":[{"version":"4.0","score":5.1,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N","level":"medium"},{"version":"3.1","score":6.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:L","level":"medium"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T14:37:58.427757Z"}],"nvd":[{"id":"CVE-2024-41677","description":"Qwik is a performance focused javascript framework. A potential mutation XSS vulnerability exists in Qwik for versions up to but not including 1.6.0. Qwik improperly escapes HTML on server-side rendering. It converts strings according to the rules found in the `render-ssr.ts` file. It sometimes causes the situation that the final DOM tree rendered on browsers is different from what Qwik expects on server-side rendering. This may be leveraged to perform XSS attacks, and a type of the XSS is known as mXSS (mutation XSS). This has been resolved in qwik version 1.6.0 and @builder.io/qwik version 1.7.3. All users are advised to upgrade. There are no known workarounds for this vulnerability.","status":"published","published":"2024-08-06T18:15:56.883Z","modified":"2026-06-17T07:48:01.89Z","cvss":[{"version":"3.1","score":6.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:L","level":"medium","assessor":"secondary"},{"version":"3.1","score":6.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N","level":"medium","assessor":"primary"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T14:10:17.832118Z"}],"osv":[{"id":"CVE-2024-41677","title":"Cross-site Scripting (XSS) vulnerability due to improper HTML escaping in qwik","description":"Qwik is a performance focused javascript framework. A potential mutation XSS vulnerability exists in Qwik for versions up to but not including 1.6.0. Qwik improperly escapes HTML on server-side rendering. It converts strings according to the rules found in the `render-ssr.ts` file. It sometimes causes the situation that the final DOM tree rendered on browsers is different from what Qwik expects on server-side rendering. This may be leveraged to perform XSS attacks, and a type of the XSS is known as mXSS (mutation XSS). This has been resolved in qwik version 1.6.0 and @builder.io/qwik version 1.7.3. All users are advised to upgrade. There are no known workarounds for this vulnerability.","status":"published","published":"2024-08-06T17:52:14.648Z","modified":"2026-10-28T02:30:44.499135991Z","cvss":[{"version":"3.1","score":6.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:L","level":"medium"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T15:44:41.963899Z"},{"id":"GHSA-2rwj-7xq8-4gx4","title":"Qwik has a potential mXSS vulnerability due to improper HTML escaping","description":"### Summary\n\nA potential mXSS vulnerability exists in Qwik for versions up to 1.6.0.\n\n### Details\n\nQwik improperly escapes HTML on server-side rendering. It converts strings according to the following rules:\n\nhttps://github.com/QwikDev/qwik/blob/v1.5.5/packages/qwik/src/core/render/ssr/render-ssr.ts#L1182-L1208\n\n- If the string is an attribute value:\n    - `\"` -\u003e `\u0026quot;`\n    - `\u0026` -\u003e `\u0026amp;`\n    - Other characters -\u003e No conversion\n- Otherwise:\n    - `\u003c` -\u003e `\u0026lt;`\n    - `\u003e` -\u003e `\u0026gt;`\n    - `\u0026` -\u003e `\u0026amp;`\n    - Other characters -\u003e No conversion\n\nIt sometimes causes the situation that the final DOM tree rendered on browsers is different from what Qwik expects on server-side rendering. This may be leveraged to perform XSS attacks, and a type of the XSS is known as mXSS (mutation XSS).\n\n## PoC\n\nA vulnerable component:\n```javascript\nimport { component$ } from \"@builder.io/qwik\";\nimport { useLocation } from \"@builder.io/qwik-city\";\n\nexport default component$(() =\u003e {\n  \n  // user input\n  const { url } = useLocation();\n  const href = url.searchParams.get(\"href\") ?? \"https://example.com\";\n\n  return (\n    \u003cdiv\u003e\n      \u003cnoscript\u003e\n        \u003ca href={href}\u003etest\u003c/a\u003e\n      \u003c/noscript\u003e\n    \u003c/div\u003e\n  );\n});\n```\n\nIf a user accesses the following URL,\n```\nhttp://localhost:4173/?href=\u003c/noscript\u003e\u003cscript\u003ealert(123)\u003c/script\u003e\n```\nthen, `alert(123)` will be executed.\n\n### Impact\n\nXSS","status":"published","published":"2024-08-06T18:24:47Z","modified":"2024-08-06T18:55:31Z","cvss":[{"version":"3.1","score":6.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:L","level":"medium"},{"version":"4.0","score":5.1,"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N","level":"medium"}],"cwes":["CWE-79"],"updated_at":"2026-11-02T15:46:34.700741Z"}]}}
