matterbridge 1.6.6-dev.6 → 1.6.6-dev.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +3 -0
- package/dist/matterbridge.js +25 -5
- package/dist/matterbridgeEdge.js +3 -3
- package/dist/matterbridgeWebsocket.js +3 -1
- package/frontend/build/asset-manifest.json +3 -3
- package/frontend/build/index.html +1 -1
- package/frontend/build/static/js/{main.1bf53a29.js → main.cb537856.js} +3 -3
- package/frontend/build/static/js/{main.1bf53a29.js.map → main.cb537856.js.map} +1 -1
- package/npm-shrinkwrap.json +75 -64
- package/package.json +4 -4
- /package/frontend/build/static/js/{main.1bf53a29.js.LICENSE.txt → main.cb537856.js.LICENSE.txt} +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -20,6 +20,8 @@ Tamer (https://github.com/tammeryousef1006) has created the Matterbridge Discord
|
|
|
20
20
|
|
|
21
21
|
- [frontend]: Add the possibility to install a specific version or the dev of any plugin (i.e. you can install matterbridge-hass@dev or matterbridge-hass@0.0.3).
|
|
22
22
|
It is also possible to use the install plugin to install a specific version of matterbridge (i.e. you can install matterbridge@dev or matterbridge@1.6.5)
|
|
23
|
+
- [frontend]: Add the possibility to set the matter discriminator for commissioning (you can always override passing **-discriminator [DISCRIMINATOR]** on the command line).
|
|
24
|
+
- [frontend]: Add the possibility to set the matter passcode for commissioning (you can always override passing **-passcode [PASSCODE]** on the command line).
|
|
23
25
|
- [frontend]: Add the possibility to set the matter port for commissioning (you can always override passing **-port [PORT]** on the command line).
|
|
24
26
|
- [deviceTypes]: Add device type airConditioner (not supported by the Apple Home).
|
|
25
27
|
- [docker]: Add matterbridge-hass to docker dev.
|
|
@@ -27,6 +29,7 @@ Tamer (https://github.com/tammeryousef1006) has created the Matterbridge Discord
|
|
|
27
29
|
|
|
28
30
|
### Changed
|
|
29
31
|
|
|
32
|
+
- [package]: Update matter.js to 0.11.9-alpha.0-20241206-22f23333.
|
|
30
33
|
- [plugin]: Removed check on package types since we are moving to production plugins.
|
|
31
34
|
- [package]: Set required node version to 18, 20 and 22.
|
|
32
35
|
- [package]: Update dependencies.
|
package/dist/matterbridge.js
CHANGED
|
@@ -69,6 +69,8 @@ export class Matterbridge extends EventEmitter {
|
|
|
69
69
|
matteripv4address: undefined,
|
|
70
70
|
matteripv6address: undefined,
|
|
71
71
|
matterPort: 5540,
|
|
72
|
+
matterDiscriminator: undefined,
|
|
73
|
+
matterPasscode: undefined,
|
|
72
74
|
restartRequired: false,
|
|
73
75
|
refreshRequired: false,
|
|
74
76
|
};
|
|
@@ -199,8 +201,8 @@ export class Matterbridge extends EventEmitter {
|
|
|
199
201
|
throw new Error('Fatal error creating node storage manager and context for matterbridge');
|
|
200
202
|
}
|
|
201
203
|
this.port = getIntParameter('port') ?? (await this.nodeContext.get('matterport', 5540)) ?? 5540;
|
|
202
|
-
this.passcode = getIntParameter('passcode');
|
|
203
|
-
this.discriminator = getIntParameter('discriminator');
|
|
204
|
+
this.passcode = getIntParameter('passcode') ?? (await this.nodeContext.get('matterpasscode'));
|
|
205
|
+
this.discriminator = getIntParameter('discriminator') ?? (await this.nodeContext.get('matterdiscriminator'));
|
|
204
206
|
if (hasParameter('logger')) {
|
|
205
207
|
const level = getParameter('logger');
|
|
206
208
|
if (level === 'debug') {
|
|
@@ -1647,7 +1649,7 @@ export class Matterbridge extends EventEmitter {
|
|
|
1647
1649
|
this.log.debug(`Creating matter commissioning server for plugin ${plg}${pluginName}${db} with uniqueId ${uniqueId} serialNumber ${serialNumber}`);
|
|
1648
1650
|
this.log.debug(`Creating matter commissioning server for plugin ${plg}${pluginName}${db} with softwareVersion ${softwareVersion} softwareVersionString ${softwareVersionString}`);
|
|
1649
1651
|
this.log.debug(`Creating matter commissioning server for plugin ${plg}${pluginName}${db} with hardwareVersion ${hardwareVersion} hardwareVersionString ${hardwareVersionString}`);
|
|
1650
|
-
this.log.debug(`Creating matter commissioning server for plugin ${plg}${pluginName}${db} with nodeLabel '${productName}' port ${CYAN}${this.port}${db}
|
|
1652
|
+
this.log.debug(`Creating matter commissioning server for plugin ${plg}${pluginName}${db} with nodeLabel '${productName}' port ${CYAN}${this.port}${db} discriminator ${CYAN}${this.discriminator}${db} passcode ${CYAN}${this.passcode}${db} `);
|
|
1651
1653
|
if (this.ipv4address) {
|
|
1652
1654
|
const networkInterfaces = os.networkInterfaces();
|
|
1653
1655
|
const availableAddresses = Object.values(networkInterfaces)
|
|
@@ -2313,7 +2315,9 @@ export class Matterbridge extends EventEmitter {
|
|
|
2313
2315
|
this.matterbridgeInformation.mattermdnsinterface = (await this.nodeContext?.get('mattermdnsinterface', '')) || '';
|
|
2314
2316
|
this.matterbridgeInformation.matteripv4address = (await this.nodeContext?.get('matteripv4address', '')) || '';
|
|
2315
2317
|
this.matterbridgeInformation.matteripv6address = (await this.nodeContext?.get('matteripv6address', '')) || '';
|
|
2316
|
-
this.matterbridgeInformation.matterPort = (await this.nodeContext?.get('matterport', 5540))
|
|
2318
|
+
this.matterbridgeInformation.matterPort = (await this.nodeContext?.get('matterport', 5540)) ?? 5540;
|
|
2319
|
+
this.matterbridgeInformation.matterDiscriminator = await this.nodeContext?.get('matterdiscriminator');
|
|
2320
|
+
this.matterbridgeInformation.matterPasscode = await this.nodeContext?.get('matterpasscode');
|
|
2317
2321
|
this.matterbridgeInformation.matterbridgePaired = this.matterbridgePaired;
|
|
2318
2322
|
this.matterbridgeInformation.matterbridgeConnected = this.matterbridgeConnected;
|
|
2319
2323
|
this.matterbridgeInformation.matterbridgeQrPairingCode = this.matterbridgeQrPairingCode;
|
|
@@ -2634,11 +2638,27 @@ export class Matterbridge extends EventEmitter {
|
|
|
2634
2638
|
if (command === 'setmatterport') {
|
|
2635
2639
|
const port = Math.min(Math.max(parseInt(param), 5540), 5560);
|
|
2636
2640
|
this.matterbridgeInformation.matterPort = port;
|
|
2637
|
-
this.log.debug(`Set matter
|
|
2641
|
+
this.log.debug(`Set matter commissioning port to ${CYAN}${port}${db}`);
|
|
2638
2642
|
await this.nodeContext?.set('matterport', port);
|
|
2639
2643
|
res.json({ message: 'Command received' });
|
|
2640
2644
|
return;
|
|
2641
2645
|
}
|
|
2646
|
+
if (command === 'setmatterdiscriminator') {
|
|
2647
|
+
const discriminator = Math.min(Math.max(parseInt(param), 1000), 4095);
|
|
2648
|
+
this.matterbridgeInformation.matterDiscriminator = discriminator;
|
|
2649
|
+
this.log.debug(`Set matter commissioning discriminator to ${CYAN}${discriminator}${db}`);
|
|
2650
|
+
await this.nodeContext?.set('matterdiscriminator', discriminator);
|
|
2651
|
+
res.json({ message: 'Command received' });
|
|
2652
|
+
return;
|
|
2653
|
+
}
|
|
2654
|
+
if (command === 'setmatterpasscode') {
|
|
2655
|
+
const passcode = Math.min(Math.max(parseInt(param), 10000000), 90000000);
|
|
2656
|
+
this.matterbridgeInformation.matterPasscode = passcode;
|
|
2657
|
+
this.log.debug(`Set matter commissioning passcode to ${CYAN}${passcode}${db}`);
|
|
2658
|
+
await this.nodeContext?.set('matterpasscode', passcode);
|
|
2659
|
+
res.json({ message: 'Command received' });
|
|
2660
|
+
return;
|
|
2661
|
+
}
|
|
2642
2662
|
if (command === 'setmblogfile') {
|
|
2643
2663
|
this.log.debug('Matterbridge file log:', param);
|
|
2644
2664
|
this.matterbridgeInformation.fileLogger = param === 'true';
|
package/dist/matterbridgeEdge.js
CHANGED
|
@@ -9,7 +9,7 @@ import { copyDirectory, getParameter, hasParameter } from './utils/utils.js';
|
|
|
9
9
|
import { DeviceTypeId, LogLevel as MatterLogLevel, LogFormat as MatterLogFormat, VendorId, EndpointServer } from '@matter/main';
|
|
10
10
|
import { ServerNode, Endpoint as EndpointNode, Environment, StorageService } from '@matter/main';
|
|
11
11
|
import { BasicInformationCluster } from '@matter/main/clusters';
|
|
12
|
-
import { FabricAction, MdnsService } from '@matter/main/protocol';
|
|
12
|
+
import { FabricAction, MdnsService, PaseClient } from '@matter/main/protocol';
|
|
13
13
|
import { GenericSwitchDevice } from '@matter/main/devices';
|
|
14
14
|
import { AggregatorEndpoint } from '@matter/main/endpoints';
|
|
15
15
|
import { BridgedDeviceBasicInformationServer, SwitchServer } from '@matter/main/behaviors';
|
|
@@ -49,8 +49,8 @@ export class MatterbridgeEdge extends Matterbridge {
|
|
|
49
49
|
if (this.mdnsInterface)
|
|
50
50
|
this.environment.vars.set('mdns.networkInterface', this.mdnsInterface);
|
|
51
51
|
this.port = 5540;
|
|
52
|
-
this.passcode =
|
|
53
|
-
this.discriminator =
|
|
52
|
+
this.passcode = PaseClient.generateRandomPasscode();
|
|
53
|
+
this.discriminator = PaseClient.generateRandomDiscriminator();
|
|
54
54
|
}
|
|
55
55
|
async startMatterStorage(storageType, storageName) {
|
|
56
56
|
this.log.info(`Starting matter node storage...`);
|
|
@@ -81,7 +81,9 @@ export async function wsMessageHandler(client, message) {
|
|
|
81
81
|
this.matterbridgeInformation.mattermdnsinterface = (await this.nodeContext?.get('mattermdnsinterface', '')) || '';
|
|
82
82
|
this.matterbridgeInformation.matteripv4address = (await this.nodeContext?.get('matteripv4address', '')) || '';
|
|
83
83
|
this.matterbridgeInformation.matteripv6address = (await this.nodeContext?.get('matteripv6address', '')) || '';
|
|
84
|
-
this.matterbridgeInformation.matterPort = (await this.nodeContext?.get('matterport', 5540))
|
|
84
|
+
this.matterbridgeInformation.matterPort = (await this.nodeContext?.get('matterport', 5540)) ?? 5540;
|
|
85
|
+
this.matterbridgeInformation.matterDiscriminator = await this.nodeContext?.get('matterdiscriminator');
|
|
86
|
+
this.matterbridgeInformation.matterPasscode = await this.nodeContext?.get('matterpasscode');
|
|
85
87
|
this.matterbridgeInformation.matterbridgePaired = this.matterbridgePaired;
|
|
86
88
|
this.matterbridgeInformation.matterbridgeConnected = this.matterbridgeConnected;
|
|
87
89
|
this.matterbridgeInformation.matterbridgeQrPairingCode = this.matterbridgeQrPairingCode;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"files": {
|
|
3
3
|
"main.css": "./static/css/main.823e08b6.css",
|
|
4
|
-
"main.js": "./static/js/main.
|
|
4
|
+
"main.js": "./static/js/main.cb537856.js",
|
|
5
5
|
"static/js/453.abd36b29.chunk.js": "./static/js/453.abd36b29.chunk.js",
|
|
6
6
|
"static/media/roboto-latin-700-normal.woff2": "./static/media/roboto-latin-700-normal.4535474e1cf8598695ad.woff2",
|
|
7
7
|
"static/media/roboto-latin-500-normal.woff2": "./static/media/roboto-latin-500-normal.7077203b1982951ecf76.woff2",
|
|
@@ -61,11 +61,11 @@
|
|
|
61
61
|
"static/media/roboto-greek-ext-400-normal.woff": "./static/media/roboto-greek-ext-400-normal.16eb83b4a3b1ea994243.woff",
|
|
62
62
|
"index.html": "./index.html",
|
|
63
63
|
"main.823e08b6.css.map": "./static/css/main.823e08b6.css.map",
|
|
64
|
-
"main.
|
|
64
|
+
"main.cb537856.js.map": "./static/js/main.cb537856.js.map",
|
|
65
65
|
"453.abd36b29.chunk.js.map": "./static/js/453.abd36b29.chunk.js.map"
|
|
66
66
|
},
|
|
67
67
|
"entrypoints": [
|
|
68
68
|
"static/css/main.823e08b6.css",
|
|
69
|
-
"static/js/main.
|
|
69
|
+
"static/js/main.cb537856.js"
|
|
70
70
|
]
|
|
71
71
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
<!doctype html><html lang="en"><head><meta charset="utf-8"/><base href="./"><link rel="icon" href="./matterbridge 32x32.png"/><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><title>Matterbridge</title><link rel="manifest" href="./manifest.json"/><script defer="defer" src="./static/js/main.
|
|
1
|
+
<!doctype html><html lang="en"><head><meta charset="utf-8"/><base href="./"><link rel="icon" href="./matterbridge 32x32.png"/><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><title>Matterbridge</title><link rel="manifest" href="./manifest.json"/><script defer="defer" src="./static/js/main.cb537856.js"></script><link href="./static/css/main.823e08b6.css" rel="stylesheet"></head><body><noscript>You need to enable JavaScript to run this app.</noscript><div id="root"></div></body></html>
|