Lucene search

K
zeroscienceGjoko KrsticZSL-2021-5626
HistoryFeb 07, 2021 - 12:00 a.m.

SmartFoxServer 2X 2.17.0 God Mode Console WebSocket XSS

2021-02-0700:00:00
Gjoko Krstic
zeroscience.mk
231

3.5 Low

CVSS2

Attack Vector

NETWORK

Attack Complexity

MEDIUM

Authentication

SINGLE

Confidentiality Impact

NONE

Integrity Impact

PARTIAL

Availability Impact

NONE

AV:N/AC:M/Au:S/C:N/I:P/A:N

5.4 Medium

CVSS3

Attack Vector

NETWORK

Attack Complexity

LOW

Privileges Required

LOW

User Interaction

REQUIRED

Scope

CHANGED

Confidentiality Impact

LOW

Integrity Impact

LOW

Availability Impact

NONE

CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N

5.6 Medium

AI Score

Confidence

High

0.006 Low

EPSS

Percentile

78.4%

Title: SmartFoxServer 2X 2.17.0 God Mode Console WebSocket XSS
Advisory ID: ZSL-2021-5626
Type: Local/Remote
Impact: Cross-Site Scripting
Risk: (2/5)
Release Date: 07.02.2021

Summary

SmartFoxServer (SFS) is a comprehensive SDK for rapidly developing multiplayer games and applications with Adobe Flash/Flex/Air, Unity, HTML5, iOS, Universal Windows Platform, Android, Java, C++ and more. SmartFoxServer comes with a rich set of features, an impressive documentation set, tens of examples with their source, powerful administration tools and a very active support forum. Born in 2004, and evolving continuously since then, today SmartFoxServer is the leading middleware to create large scale multiplayer games, MMOs and virtual communities. Thanks to its simplicity of use, versatility and performance, it currently powers hundreds of projects all over the world, from small chats and turn-based games to massive virtual worlds and realtime games.

Description

Authenticated Cross-Site Scripting was discovered. Input passed to the AdminTool console is not properly sanitized before being returned to the user. This can be exploited to execute arbitrary HTML code in a user’s browser session in context of an affected site.

Vendor

gotoAndPlay() - <https://www.smartfoxserver.com>

Affected Version

Server: 2.17.0
Remote Admin: 3.2.6
SmartFoxServer 2X, Pro, Basic

Tested On

Windows (all) 64bit installer
Linux/Unix 64bit installer
MacOS (10.8+) 64bit installer
Java 1.8.0_281
Python 3.9.1
Python 2.7.14

Vendor Status

[29.01.2021] Vulnerability discovered.
[29.01.2021] Asked vendor about the console module, how to enable it.
[30.01.2021] No response.
[31.01.2021] Vendor contacted.
[01.02.2021] Vendor asks more details.
[01.02.2021] Sent details to the vendor.
[01.02.2021] Vendor responds.
[01.02.2021] Replied to the vendor, asking for a plan.
[03.02.2021] Vendor will fix the Credentials Disclosure. Other issues are working as expected.
[07.02.2021] Public security advisory released.

PoC

sfs_xss.txt

Credits

Vulnerability discovered by Gjoko Krstic - <[email protected]>

References

[1] <https://cve.mitre.org/cgi-bin/cvename.cgi?name=2021-26549&gt;
[2] <https://nvd.nist.gov/vuln/detail/CVE-2021-26549&gt;
[3] <https://www.exploit-db.com/exploits/49528&gt;
[4] <https://packetstormsecurity.com/files/161335/&gt;
[5] <https://cxsecurity.com/issue/WLB-2021020037&gt;
[6] <https://exchange.xforce.ibmcloud.com/vulnerabilities/196349&gt;
[7] <https://www.tenable.com/cve/CVE-2021-26549&gt;

Changelog

[07.02.2021] - Initial release
[10.02.2021] - Added reference [3], [4], [5], [6] and [7]

Contact

Zero Science Lab

Web: <https://www.zeroscience.mk>
e-mail: [email protected]

<html><body><p>SmartFoxServer 2X 2.17.0 God Mode Console WebSocket XSS


Vendor: gotoAndPlay()
Product web page: https://www.smartfoxserver.com
Affected version: Server: 2.17.0
                  Remote Admin: 3.2.6
                  SmartFoxServer 2X, Pro, Basic

Summary: SmartFoxServer (SFS) is a comprehensive SDK for
rapidly developing multiplayer games and applications
with Adobe Flash/Flex/Air, Unity, HTML5, iOS, Universal
Windows Platform, Android, Java, C++ and more. SmartFoxServer
comes with a rich set of features, an impressive
documentation set, tens of examples with their source,
powerful administration tools and a very active support
forum. Born in 2004, and evolving continuously since
then, today SmartFoxServer is the leading middleware to
create large scale multiplayer games, MMOs and virtual
communities. Thanks to its simplicity of use, versatility
and performance, it currently powers hundreds of projects
all over the world, from small chats and turn-based games
to massive virtual worlds and realtime games.

Desc: Authenticated Cross-Site Scripting was discovered.
Input passed to the AdminTool console is not properly
sanitized before being returned to the user. This can be
exploited to execute arbitrary HTML code in a user's browser
session in context of an affected site.

-----------------------------------------------------------------
/ConsoleModuleReqHandler.java:
------------------------------

 private String checkHTML(String data) {
     if (data.indexOf(60) &gt; -1 &amp;&amp; data.indexOf("<span data='data.replaceAll("\\&lt;",' data.replaceall="" return="">", "&gt;");
     }
     return data;

-----------------------------------------------------------------

Tested on: Windows (all) 64bit installer
           Linux/Unix 64bit installer
           MacOS (10.8+) 64bit installer
           Java 1.8.0_281
           Python 3.9.1
           Python 2.7.14


Vulnerability discovered by Gjoko 'LiquidWorm' Krstic
                            @zeroscience


Advisory ID: ZSL-2021-5626
Advisory URL: https://www.zeroscience.mk/en/vulnerabilities/ZSL-2021-5626.php

CVE ID: CVE-2021-26549
CVE URL: https://cve.mitre.org/cgi-bin/cvename.cgi?name=2021-26549
NIST URL: https://nvd.nist.gov/vuln/detail/CVE-2021-26549


29.01.2021

--


Typing payload:
<script>confirm(document.URL)

WebSocket payload:
\x80\x00\x52\x12\x00\x03\x00\x01\x63\x02\x01\x00
\x01\x61\x03\x00\x0D\x00\x01\x70\x12\x00\x03\x00
\x01\x63\x08\x00\x0C\x63\x6F\x6E\x73\x6F\x6C\x65
\x2E\x68\x69\x6E\x74\x00\x01\x72\x04\xFF\xFF\xFF
\xFF\x00\x01\x70\x12\x00\x01\x00\x01\x63\x08\x00
\x18\x3C\x73\x63\x72\x69\x70\x74\x3E\x63\x6F\x6E
\x66\x69\x72\x6D\x28\x64\x6F\x63\x75\x6D\x65\x6E
\x74\x2E\x55\x52\x4C\x29
</script></span></p></body></html>

3.5 Low

CVSS2

Attack Vector

NETWORK

Attack Complexity

MEDIUM

Authentication

SINGLE

Confidentiality Impact

NONE

Integrity Impact

PARTIAL

Availability Impact

NONE

AV:N/AC:M/Au:S/C:N/I:P/A:N

5.4 Medium

CVSS3

Attack Vector

NETWORK

Attack Complexity

LOW

Privileges Required

LOW

User Interaction

REQUIRED

Scope

CHANGED

Confidentiality Impact

LOW

Integrity Impact

LOW

Availability Impact

NONE

CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N

5.6 Medium

AI Score

Confidence

High

0.006 Low

EPSS

Percentile

78.4%

Related for ZSL-2021-5626