starting zigbee2mqtt on 2 different raspberry generate the same panId
different panId
2 different raspberry pi's with:
on startup,
RPI-01
10/21/2019, 4:53:52 PM - info: Logging to directory: '/opt/zigbee2mqtt/data/log/2019-10-21.16-53-50'
10/21/2019, 4:53:52 PM - debug: Removing old log directory '/opt/zigbee2mqtt/data/log/2019-10-19.23-13-00'
10/21/2019, 4:53:52 PM - debug: Loaded state from file /opt/zigbee2mqtt/data/state.json
10/21/2019, 4:53:52 PM - debug: Saving state to file /opt/zigbee2mqtt/data/state.json
10/21/2019, 4:53:52 PM - info: Starting zigbee2mqtt version 1.6.0 (commit #e26ad2a)
10/21/2019, 4:53:52 PM - info: Starting zigbee-shepherd
10/21/2019, 4:53:52 PM - debug: Using zigbee-shepherd with settings: '{"net":{"panId":6754,"extPanId":[221,221,221,221,221,221,221,221],"channelList":[11],"precfgkey":"HIDDEN"},"dbPath":"/opt/zigbee2mqtt/data/database.db","coordBackupPath":"/opt/zigbee2mqtt/data/coordinator_backup.json","sp":{"baudRate":115200,"rtscts":true}}'
10/21/2019, 4:53:54 PM - info: zigbee-shepherd started
10/21/2019, 4:53:54 PM - info: Coordinator firmware version: '20190608'
10/21/2019, 4:53:54 PM - debug: zigbee-shepherd info: {"enabled":true,"net":{"state":"Coordinator","channel":"11","panId":6754,"extPanId":[221,221,221,221,221,221,221,221],"ieeeAddr":"0x00124b0018e1a46a","nwkAddr":0},"firmware":{"transportrev":2,"product":0,"version":"2.6.3","revision":20190608},"startTime":1571669634,"joinTimeLeft":0}
10/21/2019, 4:53:54 PM - info: Currently 0 devices are joined:
10/21/2019, 4:53:54 PM - info: Zigbee: disabling joining new devices.
on RPI-02
10/21/2019, 4:54:17 PM - info: Logging to directory: '/opt/zigbee2mqtt/data/log/2019-10-21.16-54-16'
10/21/2019, 4:54:17 PM - debug: Removing old log directory '/opt/zigbee2mqtt/data/log/2019-10-20.23-57-56'
10/21/2019, 4:54:17 PM - debug: Loaded state from file /opt/zigbee2mqtt/data/state.json
10/21/2019, 4:54:17 PM - debug: Saving state to file /opt/zigbee2mqtt/data/state.json
10/21/2019, 4:54:17 PM - info: Starting zigbee2mqtt version 1.6.0 (commit #e26ad2a)
10/21/2019, 4:54:17 PM - info: Starting zigbee-shepherd
10/21/2019, 4:54:17 PM - debug: Using zigbee-shepherd with settings: '{"net":{"panId":6754,"extPanId":[221,221,221,221,221,221,221,221],"channelList":[11],"precfgkey":"HIDDEN"},"dbPath":"/opt/zigbee2mqtt/data/database.db","coordBackupPath":"/opt/zigbee2mqtt/data/coordinator_backup.json","sp":{"baudRate":115200,"rtscts":true}}'
10/21/2019, 4:54:24 PM - info: zigbee-shepherd started
10/21/2019, 4:54:24 PM - info: Coordinator firmware version: '20190608'
10/21/2019, 4:54:24 PM - debug: zigbee-shepherd info: {"enabled":true,"net":{"state":"Coordinator","channel":"11","panId":6754,"extPanId":[221,221,221,221,221,221,221,221],"ieeeAddr":"0x00124b0018e1f452","nwkAddr":0},"firmware":{"transportrev":2,"product":0,"version":"2.6.3","revision":20190608},"startTime":1571669664,"joinTimeLeft":0}
10/21/2019, 4:54:24 PM - info: Currently 0 devices are joined:
10/21/2019, 4:54:24 PM - info: Zigbee: disabling joining new devices.
on the timestamps you can see the "proof" they are from different devices :-)
Both have panId:6754
I had some problems:
zigbee2mqtt version: 1.6.0
CC253X firmware version: 20190608
This is actually expected behaviour as this allows to recover a network on z-stack 1.2. Z-stack 3 will refuse to start when a duplicate pan id has been detected.
Hi @Koenkk,
Can you elaborate this a little bit more? Or point me to some documentation?
"this allows to recover a network on z-stack 1.2"
Does it mean that some close neighbor can "recover" my network?
Not feeling very comfortable with this..
If he uses the same network key, yes. That's why https://www.zigbee2mqtt.io/how_tos/how_to_secure_network.html is recommended.
Hello @Koenkk
Thanx. I changed my key.
Suggestion: because of importance of this key, I would like suggest that this setting is included by default in the out-of-the-box config. So users get more aware of potential risks by not changing the key. The documentation is very clear, no criticism on that, but for newbies like me, you start with the basic configuration like mentioned on on https://www.zigbee2mqtt.io/getting_started/running_zigbee2mqtt.html.
It's maybe a good idea to have following lines in your example?
advanced:
# change pan_id for your own environment
pan_id: [default panId]
# change pan_id for security reasons
network_key: [default network key]
kind regards,
Bart
@bartplessers @Koenkk @danielwelch Maybe a feature enhancement to:
Update the configuration example comments to better reflect this
# Optional: network encryption key, will improve security (Note: changing requires repairing of all devices) (default: shown below)
This should maybe changed to a better text:
# Optional: It is highly recommended that you change your network encryption key, to avoid security problems (Note: changing requires repairing of all devices) (default: shown below)
Add a warn entry in the logs if zigbee2mqtt starts with the default key
Investigate the possibility to randomize the key in the addon (at installation time), so people have a different key before they start pairing, reading logs later on and realizing they need to start over.
Yeah well, this could be the beginning of a long series of improvements, but I would also understand that the current status is to document these features and let the user decide.
zigbee2mqtt is fun to use and simple for most users. I struggle with re-pairing devices from time on my own network, so I can imagine my neighbors pain trying to spy on my network, to get a temperature sensor read.
Before using zigbee in security critical applications many more points would have to be checked further and not only those mentioned above.
@ciotlosm the warning and doc changes look good to me, can you make a PR?
I will further think about how we can randomize a key.
@Koenkk Will do
A question to make the subject clear.
So that two networks in my home do not have conflicts between them, is it enough to generate a different network key or does the pan_id also need to be established as well?
@zhapwey
pan_id. pan_id can be the same.This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Most helpful comment
@zhapwey
pan_id.pan_idcan be the same.