Device Monitoring Studio - Monitor, log and analyze data coming through PC ports and connections
Download Device Monitoring Studio Hide this button

Server Configuration File Reference

Device Monitoring Studio Server reads its configuration from the config.json file located in the same folder as dmssrv.exe server executable (unless overridden by --config command-line parameter).

This topic describes the structure of the configuration file. Device Monitoring Studio Server Configuration Utility may also be used as a visual editor of the configuration file.

NOTE

JSON file format does not support comments. If you use // or /* ... */ comments in a configuration file, server will treat it as malformed and will refuse to start.

WARNING

Any configuration file syntax error is considered a critical error.

JSON File Structure

We will describe the JSON file structure by means of a TypeScript declaration:

interface AccessToken
{
    // A list of hardware IDs this token is allowed to monitor.
    // An empty list means that all devices are allowed
    allowedHardwareIds?: string[];
}

const enum MessageLevel
{
    Critical,   // 0
    Error,  // 1
    Warning,    // 2
    Informational,  // 3
    Debug,  // 4
}

interface Config
{
    // Full path to log file. Default value is "%PROGRAMDATA%\HHD Software\Device Monitoring Studio Server\dmssrv.log"
    logPath?: string = "%PROGRAMDATA%\\HHD Software\\Device Monitoring Studio Server\\dmssrv.log";
    
    // Logging level, specified as number. Default value is 3 (Informational)
    logLevel?: MessageLevel = 3;

    // Comma-separated list of local endpoints, see below. Default value is an empty string
    listenEndpoints?: string = "";

    // default TCP port. Default value is 6612
    defaultListeningPort?: number = 6612;

    // A list of access tokens. Default value is an empty array
    authKeys?: AccessToken[] = [];

    // Enable server advertisement. Default value is true
    advertise?: boolean = true;
 
    // Enable anonymous access. Default value is true
    allowAnonymous?: boolean = true;
};

All configuration parameters are optional and provide reasonable defaults if omitted.

Endpoint Syntax

listenEndpoints parameter is a comma-separated list of local endpoints the server listens on. The server supports the following endpoint syntaxes:

hostname
Any local hostname that the server will try to resolve. Must refer to one of the local network adapters.
hostname:port
The same as before, but explicitly specifies TCP port.
ipv4
A local IPv4 address.
ipv4:port
A local IPv4 address and TCP port.
ipv6
A local IPv6 address.
[ipv6]:port
A local IPv6 address and TCP port. Note that IPv6 address must be enclosed in square brackets if it is followed by a port number.
* or empty string
Use all local addresses. This is the default setting.
*:port
Use a specific TCP port on all local addresses.

Server Configuration

The server reads configuration file only on startup. If you modify the configuration file, make sure the server is restarted to pick up the changes.