XMPP support for GenieACS

@naalhode, @gittela I just published the code last night. See ‘xmpp’ branch. Sorry I didn’t have the time to do that last week. This won’t be merged with master until the next major release (probably 1.3). But I don’t expect that to take long anyway as I want to quickly get it out the door to focus on 2.0.

Curious to hear your thoughts about how this compares to your own implementation and what things you might have done differently.

Here’s some instructions how to configure XMPP:

1- Install an XMPP server. No special requirements here. Any XMPP server should do the job fine.

2- Add the correct SRV DNS record for your XMPP server. See https://wiki.xmpp.org/web/SRV_Records. Also make sure to add A and AAAA records for the same domain.

3- Create two XMPP users, one for Genie, and one for your CPEs. Note that all your CPEs will be using the same XMPP user. We’ll use the following two users as examples:

ACS user: acs@xmpp.example.com
Passwrod: password1

CPE user: cpe@xmpp.example.com
Passwrod: password2

4- Pass the env vars GENIEACS_XMPP_JID and GENIEACS_XMPP_PASSWORD to Genie. If you’ve used the official GenieACS installation guide, those need to go in /opt/genieacs/genieacs.env. The first var should hold the XMPP user that Genie should use (e.g. acs@xmpp.example.com). While the second one is the password for that user. Make sure to restart genieacs-nbi and genieacs-ui after making this change.

GENIEACS_XMPP_JID=acs@xmpp.example.com
GENIEACS_XMPP_PASSWORD=password1

5- Modify the provision script ‘inform’ by adding the following:

declare("InternetGatewayDevice.XMPP.Connection.*", {path: daily, value: daily}, {path: 1});
declare("InternetGatewayDevice.XMPP.Connection.*.Enable", {path: daily, value: daily}, {value: true});
declare("InternetGatewayDevice.XMPP.Connection.*.Username", {path: daily, value: daily}, {value: "cpe"});
declare("InternetGatewayDevice.XMPP.Connection.*.Password", {path: daily, value: daily}, {value: "password2"});
declare("InternetGatewayDevice.XMPP.Connection.*.Resource", {path: daily, value: daily}, {value: username});
declare("InternetGatewayDevice.XMPP.Connection.*.Domain", {path: daily, value: daily}, {value: "xmpp.example.com"});
declare("InternetGatewayDevice.ManagementServer.ConnReqAllowedJabberIDs", {path: daily, value: daily}, {value: "acs@xmpp.example.com"});
3 Likes