bluez/mesh
Inga Stotland 7cdc215ff5 mesh: Add finalization of a newly created node
When a new node is created as a result of successful completion
of either Join() or Create() or Import() methods and has been
confirmed via successful token delivery to the application,
clean up node's D-Bus resources (application path, element paths, etc)
that have been gathered during the initial GetMAnagedObjects() call.
Also, remove the agent instance associaed with the new node.

These resources will be re-populated after the Attach() call
verifies the node's integrity.
2020-05-22 13:45:52 -07:00
..
agent.c mesh: Free allocated agent in mesh_remove_agent() 2020-05-22 13:45:52 -07:00
agent.h mesh: Refresh provisioner's capabilities 2020-04-01 12:06:14 -07:00
appkey.c mesh: Move Replay Protection to mesh/net.c 2020-01-30 11:03:47 -08:00
appkey.h mesh: Move Replay Protection to mesh/net.c 2020-01-30 11:03:47 -08:00
bluetooth-mesh.conf mesh: Allow sending on org.bluez.mesh.Provisioner1 2019-07-18 09:47:14 -07:00
bluetooth-mesh.service.in build: Add support for systemd bluetooth-mesh service 2019-06-06 11:58:22 -07:00
cfgmod-server.c mesh: Fix publication setup for vendor models 2020-04-30 10:09:05 -07:00
cfgmod.h mesh: Fix opcode for OP_VEND_MODEL_APP_GET 2020-01-17 23:06:57 -08:00
crypto.c mesh: Fix GCC 10.0 warnings 2020-04-18 08:21:03 -07:00
crypto.h mesh: Remove redundant code from mesh/crypto 2020-04-07 09:52:44 -07:00
dbus.c mesh: Add Time-outs to critical dbus send-with-replies 2020-04-14 08:45:47 -07:00
dbus.h mesh: Add Time-outs to critical dbus send-with-replies 2020-04-14 08:45:47 -07:00
error.h mesh: Update copyright dates 2019-05-17 13:14:40 -07:00
friend.c mesh: Add net key index to sar structure 2020-03-31 16:27:56 -07:00
friend.h mesh: Friendship clean-up and rewrite 2019-11-28 13:49:59 -08:00
keyring.c mesh: Fix keyring app keys directory iteration 2020-02-07 09:22:47 -08:00
keyring.h mesh: Automate AppKey update on KR phase 2-->3-->0 2019-09-10 09:32:40 -07:00
main.c mesh: Rename --index to --io, support additional io types. 2020-01-16 08:45:31 -08:00
manager.c mesh: Refresh provisioner's capabilities 2020-04-01 12:06:14 -07:00
manager.h mesh: Cancel unprovisioned scan on exit or app disconnect 2019-11-14 14:10:18 -08:00
mesh-config-json.c mesh: Fix double-free 2020-05-20 15:16:55 -07:00
mesh-config.h mesh: Fix double-free 2020-05-20 15:16:55 -07:00
mesh-defs.h mesh: Move SEQ_MASK define in mesh-defs.h 2020-04-01 18:27:14 -07:00
mesh-io-api.h mesh: rework incoming advertisement filtering 2020-02-26 11:20:08 -08:00
mesh-io-generic.c mesh: Fix segfault caused by re-enabling of HCI controller 2020-05-17 08:12:20 -07:00
mesh-io-generic.h mesh: Shared private meshd interfaces 2018-08-20 12:48:14 -07:00
mesh-io.c mesh: rework incoming advertisement filtering 2020-02-26 11:20:08 -08:00
mesh-io.h mesh: rework incoming advertisement filtering 2020-02-26 11:20:08 -08:00
mesh-main.conf mesh: Add mesh-main.conf file with general mesh configuration 2019-12-16 14:52:36 -08:00
mesh-mgmt.c mesh: Remove redundant code in mesh IO mgmt 2019-12-15 09:33:37 -08:00
mesh-mgmt.h mesh: Move HCI handling to mesh-io-generic 2019-06-24 09:04:44 -07:00
mesh.c mesh: Add finalization of a newly created node 2020-05-22 13:45:52 -07:00
mesh.h mesh: Add mesh-main.conf file with general mesh configuration 2019-12-16 14:52:36 -08:00
model.c mesh: Allow short messages to be segmented 2020-03-20 11:51:18 -07:00
model.h mesh: Allow short messages to be segmented 2020-03-20 11:51:18 -07:00
net-keys.c mesh: Fix valgrind memory leak warnings 2020-05-15 18:25:30 -07:00
net-keys.h mesh: Fix valgrind memory leak warnings 2020-05-15 18:25:30 -07:00
net.c mesh: Fix valgrind memory leak warnings 2020-05-15 18:25:30 -07:00
net.h mesh: Fix valgrind memory leak warnings 2020-05-15 18:25:30 -07:00
node.c mesh: Add finalization of a newly created node 2020-05-22 13:45:52 -07:00
node.h mesh: Add finalization of a newly created node 2020-05-22 13:45:52 -07:00
org.bluez.mesh.service build: Add support for systemd bluetooth-mesh service 2019-06-06 11:58:22 -07:00
pb-adv.c mesh: Handle close for Acceptor 2020-03-25 10:31:14 -07:00
pb-adv.h mesh: Fix support for Provisioner Initiator 2019-07-14 08:32:18 -07:00
prov-acceptor.c mesh: Handle close for Acceptor 2020-03-25 10:31:14 -07:00
prov-initiator.c mesh: Honor provisioner's capabilities 2020-04-01 12:06:14 -07:00
prov.h mesh: Convert provisioning pkts to packed structs 2019-07-14 08:32:18 -07:00
provision.h mesh: Refresh provisioner's capabilities 2020-04-01 12:06:14 -07:00
README mesh: ELL encrypt dependancy README section added 2019-05-31 16:46:34 -07:00
rpl.c mesh: Add NVM storage of Replay Protection 2020-01-30 11:03:47 -08:00
rpl.h mesh: Add NVM storage of Replay Protection 2020-01-30 11:03:47 -08:00
util.c mesh: Relocate tree deletion to util.c/h 2020-01-30 11:03:47 -08:00
util.h mesh: Relocate tree deletion to util.c/h 2020-01-30 11:03:47 -08:00

Bluetooth Mesh Daemon
*********************

Copyright (C) 2019  Intel Corporation. All rights reserved.

Compilation and installation
============================

In addition to main BlueZ requirements, MeshCtl needs the following:
	- json-c library

Configuration and options
=========================

	--enable-mesh

		Build mesh daemon and other Bluetooth Mesh based tools

Current implementation of the mesh daemon requires exclusive access to
a Bluetooth controller.
The AutoEnable option in the installed main.conf should be set to "false".

Storage
=======

Default storage directory is /var/lib/bluetooth/mesh.

The directory contains the provisioned nodes configurations.
Each node has its own subdirectory, named after node's Device UUID (32-digit
hexadecimal string) that is generated by the application that created a node.

Each subdirectory contains the following files:
	- node.json:
		node configuration and is populated by the
		daemon based on the configuration commands from a
		provisioner/configuration client
	- node.json.bak:
		a backup that the last known good node configuration.
	- seq_num:
		File containing next sequence number to use
	- seq_num.bak:
		Backup of the sequence number. This may be larger than the
		actual sequence number being used at runtime, to prevent re-use
		of sequence numbers in the event of an unexpected restart.
	- ./rpl/:
		Directory to store the sequence numbers of remote nodes, as
		required by Replay Protection List (RPL) parameters.
		- xxxx:
			Files named for remote Unicast addresses, and contain
			last received iv_index + seq_num from each SRC address.
	- ./dev_keys/:
		Directory to store remote Device keys. This is only created/used
		by Configuration Client (Network administration) nodes.
		- xxxx:
			Files named for remote Unicast addresses, and contains
			16 octet key.
	- ./net_keys/:
		Directory to store network subnet keys. This is only
		created/used by Configuration Client (Network administration)
		nodes.
		- xxx:
			Files named for subnet index, and contains key refresh
			phase, and old/new versions of the key.
	- ./app_keys/:
		Directory to store application keys. This is only created/used
		by Configuration Client (Network administration) nodes.
		- xxx:
			Files named for application index, and contains bound
			subnet index, and old/new versions of the key.

The node.json and node.json.bak are in JSON format. All other files are stored
in little endian binary format.

Known Issues
============

Bluetooth Mesh makes heavy usage of AEAD-AES_CCM encryption, which is
implemented in the Linux kernel on most platforms. Some platforms, including
those with kernel versions including and prior to v4.8, did *not* correctly
implement the AEAD encryption routines. If Mesh is to be ported to such a
system, it will be the responsibility of the vendor to provide support for
AEAD-AES_CCM encryption by some other method.

Support for the required AEAD routines can be determined by running the unit
tests provided with the ELL libraries used by Mesh. Specifically, the tests
found in .../ell/unit/test-cipher.c

Information
===========

Mailing lists:
	linux-bluetooth@vger.kernel.org

For additional information about the project visit BlueZ web site:
	http://www.bluez.org