Request Trial

The router

A guide to use, extend and configure the router

» Next - More about the java clients

The router - message broker and authority

The router has two major tasks: Handling the authentication and passing messages to the correct client.


It is possible to extend the authentication process in any way. Connectanum comes with the default wamp-cra authentication, a trust-all authentication as well as some generic oAuth2 and token-based authentication methods. The IAuthenticationExecutor interface or the AbstractAuthenticationExecutor class can be used to extend the process.

public interface IAuthenticationExecutor{
    void setApplicationStorage(ApplicationStorage applications);
    boolean canAuthenticate(String authenticationMethod);
    void applyForAuthentication(Hello hello, Channel channel);
    void authenticate(Authenticate authenticate, Channel channel);

Message broker

Passing the messages to the correct clients is processed automatically, but can be influenced by permitting RPC registration and calls as well as event subscription and publishing. This is done by the IMessageSecurityEnvironment interface.

public interface IMessageSecurityEnvironment {
    boolean subscriptionAllowed(Channel channel, Subscribe subscribe);
    boolean publishAllowed(Channel channel, Publish publish);
    boolean registerAllowed(Channel channel, Register register);
    boolean callAllowed(Channel channel, Call call);

Connectanum comes with a TrustedMessageEnvironment implementation that simply allows all registrations and message transfers. In addition the ConfiguredMessageEnvironment provides an implementation that is configurable inside the conf.json like this:


Where to use Get started The router The java client JavaScript and other clients