Category Archives: News

Security for HTML5 games

With SmartFoxServer 2X 2.13.4 we introduced websocket origin checks for HTML5 clients. What this mechanism does is essentially verify the provenance of the client against a white-list of domains configured by the server admin. If the client origin does not match any of the allowed domains the client connection is denied.

In this article we’ll demonstrate how to use and configure websocket origins in SmartFoxServer 2X and discuss the advantages and limitations of this security measure. We’ll also take a deeper look at the issue of cheating clients and propose several ideas to improve the security of your online game. Continue reading

New C# API v1.7.9 released

We just released v1.7.9 of the SFS2X C# client API for Unity / .Net / Mono / Universal Windows Platform.

What’s new:

  • Rewritten BlueBox client, using .Net 4.5.x classes.
  • Added support for BlueBox (tunneled) connection over HTTPS.
  • Added support for proxy settings for the BlueBox connection (not available under Universal Windows Platform).
  • Rewritten SmartFox.InitCrypto() method; now it doesn’t require to be run as a coroutine in Unity.
  • Unified .DLLs for Unity and .Net/Mono; now both environments can reference the same library.
  • Updated WebsocketSharp library for Unity WebGL builds.

…And we also fixed a WSS connection issue in Unity.

You can get the updated API at this url: https://www.smartfoxserver.com/download/sfs2x#p=client

Enjoy!

SFS2X multi-threading demystified

Often times articles in this blog are inspired by questions and issues raised by our users and this new entry is no exception. One aspect of SmartFoxServer that seems to intimidate developers is the multi-threaded environment behind custom Extensions, and the relative implications in terms of concurrency, scalability and performance.

In this new entry we’re going to demystify the subject and demonstrate how simple and painless is writing server side code, even when many other things are running concurrently. Continue reading

New JavaScript API v1.7.10 released

We just released v1.7.10 of the SFS2X JavaScript client API.

Starting from this new version, we completely reviewed the build process of the API.
This fixes some compatibility issues of the internal third-party libraries with module bundlers (like webpack) and also brings:

  • reduced API file size (-41%)
  • a source map to help debug the API, should unexpected issues show up in the future
  • the official SFS2X API package for the npm package builder
  • Node.js compatibility

As always, the new package is available on the download page of our website (other than in the npm repository, from now on).

In order to showcase the usage of the API with npm and webpack, we also released a variant Connector example describing the project setup and build process, including the new source mapping option.

Enjoy!

New client API updates available!

We have just released a new client side API update across all supported platforms, ironing out a few bugs that were reported recently.

In particular we have solved an issue whereby reconnecting an encrypted session would cause a server side error and fail to reconnect.

Make sure to check our client API section of the website to read the release notes and download the updates.

HTML5 / JavaScript tutorials

We just published the first batch of HTML5 / JavaScript tutorials describing the following examples in details:

  • Connector
    Learn how to configure the client and make your first connection
  • Simple Chat
    Learn how to create a basic chat environment for connected users
  • Advanced Chat
    Learn how to create a complete browser-based chat application featuring public chat messaging, Rooms management, private chat messaging and more
  • Game Lobby
    Learn how to create a “lobby” application where users can meet and invite each other to play games

All tutorials are available in our documentation website.