NocoDB Vulnerable to Stored Cross-Site Scripting in Formula.vue
Description
NocoDB is software for building databases as spreadsheets. Prior to 0.202.9, a stored cross-site scripting vulnerability exists within the Formula virtual cell comments functionality. The nc-gui/components/virtual-cell/Formula.vue displays a v-html tag with the value of "urls" whose contents are processed by the function replaceUrlsWithLink(). This function recognizes the pattern URI::(XXX) and creates a hyperlink tag <a> with href=XXX. However, it leaves all the other contents outside of the pattern URI::(XXX) unchanged. This vulnerability is fixed in 0.202.9.
Affected packages
Versions sourced from the GitHub Security Advisory.
| Package | Affected versions | Patched versions |
|---|---|---|
nocodbnpm | < 0.202.9 | 0.202.9 |
Affected products
1Patches
17f58ce3726dffix: sanitise formula text before rendering
1 file changed · +8 −1
packages/nc-gui/utils/urlUtils.ts+8 −1 modified@@ -6,8 +6,15 @@ export const replaceUrlsWithLink = (text: string): boolean | string => { } const rawText = text.toString() + + // create a temporary element to sanitise the string + // by encoding any html code + const tempEl = document.createElement('div') + tempEl.textContent = rawText + const sanitisedText = tempEl.innerHTML + let found = false - const out = rawText.replace(/URI::\((.*?)\)/g, (_, url) => { + const out = sanitisedText.replace(/URI::\((.*?)\)/g, (_, url) => { found = true const a = document.createElement('a') a.textContent = url
Vulnerability mechanics
Generated by null/stub on May 9, 2026. Inputs: CWE entries + fix-commit diffs from this CVE's patches. Citations validated against bundle.
References
4- github.com/advisories/GHSA-h6r4-xvw6-jc5hghsaADVISORY
- nvd.nist.gov/vuln/detail/CVE-2023-49781ghsaADVISORY
- github.com/nocodb/nocodb/commit/7f58ce3726dfec71537d8b80474a0f95a48a1574ghsax_refsource_MISCWEB
- github.com/nocodb/nocodb/security/advisories/GHSA-h6r4-xvw6-jc5hghsax_refsource_CONFIRMWEB
News mentions
0No linked articles in our index yet.