Skip to content

Commit 95c69be

Browse files
jasnowRubySec CI
authored and
RubySec CI
committed
Updated advisory posts against rubysec/ruby-advisory-db@aa479b5
1 parent 229f292 commit 95c69be

File tree

1 file changed

+60
-0
lines changed

1 file changed

+60
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
---
2+
layout: advisory
3+
title: 'GHSA-8fx8-3rg2-79xw (camaleon_cms): Camaleon CMS vulnerable to stored XSS
4+
through user file upload (GHSL-2024-184)'
5+
comments: false
6+
categories:
7+
- camaleon_cms
8+
advisory:
9+
gem: camaleon_cms
10+
ghsa: 8fx8-3rg2-79xw
11+
url: https://github.com/owen2345/camaleon-cms/security/advisories/GHSA-r9cr-qmfw-pmrc
12+
title: Camaleon CMS vulnerable to stored XSS through user file upload (GHSL-2024-184)
13+
date: 2024-09-23
14+
description: |
15+
A stored cross-site scripting has been found in the image upload
16+
functionality that can be used by normal registered users:
17+
It is possible to upload a SVG image containing JavaScript and
18+
it's also possible to upload a HTML document when the format
19+
parameter is manually changed to [documents][1] or a string of
20+
an [unsupported format][2]. If an authenticated user or administrator
21+
visits that uploaded image or document malicious JavaScript can
22+
be executed on their behalf (e.g. changing or deleting content
23+
inside of the CMS.)
24+
25+
[1]: https://github.com/owen2345/camaleon-cms/blob/feccb96e542319ed608acd3a16fa5d92f13ede67/app/uploaders/camaleon_cms_uploader.rb#L105-L106
26+
[2]: https://github.com/owen2345/camaleon-cms/blob/feccb96e542319ed608acd3a16fa5d92f13ede67/app/uploaders/camaleon_cms_uploader.rb#L110-L111
27+
28+
## Impact
29+
30+
This issue may lead to account takeover due to reflected
31+
Cross-site scripting (XSS).
32+
33+
## Remediation
34+
35+
Only allow the upload of safe files such as PNG, TXT and others
36+
or serve all "unsafe" files such as SVG and other files with a
37+
content-disposition: attachment header, which should prevent
38+
browsers from displaying them.
39+
40+
Additionally, a [Content security policy (CSP)][3] can be created
41+
that disallows inlined script. (Other parts of the application
42+
might need modification to continue functioning.)
43+
44+
[3]: https://web.dev/articles/csp
45+
46+
To prevent the theft of the auth_token it could be marked with
47+
HttpOnly. This would however not prevent that actions could be
48+
performed as the authenticated user/administrator. Furthermore,
49+
it could make sense to use the authentication provided by
50+
Ruby on Rails, so that stolen tokens cannot be used anymore
51+
after some time.
52+
cvss_v3: 5.4
53+
patched_versions:
54+
- ">= 2.8.1"
55+
related:
56+
url:
57+
- https://github.com/owen2345/camaleon-cms/security/advisories/GHSA-r9cr-qmfw-pmrc
58+
- https://github.com/rubysec/ruby-advisory-db/blob/master/gems/camaleon_cms/GHSA-r9cr-qmfw-pmrc.yml
59+
- https://github.com/advisories/GHSA-8fx8-3rg2-79xw
60+
---

0 commit comments

Comments
 (0)