Install sjsxc (SOGo)

Klaus edited this page Feb 13, 2017 · 13 revisions

Get the code

a) Packed version

Download the latest version from releases and extract it to /usr/lib/GNUstep/SOGo/WebServerResources/.

b) Nightly version

cd /opt
git clone sjsxc
cd sjsxc
git submodule update --init --recursive
ln -s /opt/sjsxc /usr/lib/GNUstep/SOGo/WebServerResources/

JSXC Configuration for XMPP

It is good to first make sure you can connect and established XMPP communications before configuring the WebRTC part (which should anyway work most of the time right off with default configuration).

Rename sjsxc/js/sjsxc.config.sample.js to sjsxc/js/sjsxc.config.js and adjust the values for xmpp server, bosh url and xmpp domain.


Here below is an example of a working config file with few options although sufficient to get JSXC plugin to connect to your XMPP server.

File sjsxc.config.js :

 * feel free to browse through ./jsxc/src/jsxc.options.js to see possible configurations options

var sjsxc = {};
sjsxc.config = {
    /** enable chat by default? */
    enable: true,

    /** JSXC options. */
    jsxc: {
        xmpp: {
            /** url to bosh server binding. Adapt port to the one you declared in your XMPP server's config */
            url: '',

           /** domain part of your jid */
            domain: '',

            /** which resource should be used? Blank, means random. */
            resource: '',

            /** Allow user to overwrite xmpp settings? */
            overwrite: true,

            /** Should chat start on login? */
            onlogin: true

note : it might be a good idea to use a reverse proxy for reaching the BOSH server (url parameter then becoming, otherwise tight-up networks would prevent the user to connect to XMPP's port.

SOGo configuration

Add SOGoUIAdditionalJSFiles to your sogo config (/etc/sogo/sogo.conf).

a) Packed version:


    SOGoUIAdditionalJSFiles = (
        "sjsxc/js/lib/jquery.min.js", // only SOGo v3

b) Nightly version:


    SOGoUIAdditionalJSFiles = (
        "sjsxc/js/lib/jquery.min.js", // only SOGo v3

Restart sogo service

sudo service sogo restart


First off, make sure your BOSH server is accessible, and that the certificate is valid for HTTPS. One way to do that is prepare a generic test file (testBosh.txt) that you'll call via curl command :

Content of the file testBosh.txt :

<body content='text/xml; charset=utf-8'
    xmlns='' xmlns:xmpp='urn:xmpp:xbosh'/>

Save the file locally on your computer and run:

curl -X POST -d@testBosh.txt

If you get this kind of output, you are good to go as far as BOSH access to XMPP server is concerned, with valid certificate for HTTPS access.

<body xmlns="" xmlns:stream="" from="" authid="55j3i8xlx2" sid="55j3i8xlx2" secure="true" requests="2" inactivity="30" polling="5" wait="60"><stream:features><mechanisms xmlns="urn:ietf:params:xml:ns:xmpp-sasl"><mechanism>PLAIN</mechanism></mechanisms><bind xmlns="urn:ietf:params:xml:ns:xmpp-bind"/><session xmlns="urn:ietf:params:xml:ns:xmpp-session"><optional/></session></stream:features></body>

Finally, JSXC core being all about javascript, you need to open your browser console (Ctrl-Shift-i on Firefox) and filter all JS information.


Once JSXC is well anchored in your SOGo interface and you have a fully functionnal OTR-capable integrated chat, it is now time to test and use video chat.

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.