Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp515887ybi; Wed, 3 Jul 2019 00:17:53 -0700 (PDT) X-Google-Smtp-Source: APXvYqwH2fUIo1nDdKLQMTRPNSxu6lJ/9rb9z1e2BYfKnRqjihW8pd7pIFYX0M3p/epfdQoOu3/i X-Received: by 2002:a17:90a:9a8d:: with SMTP id e13mr11015403pjp.77.1562138273573; Wed, 03 Jul 2019 00:17:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562138273; cv=none; d=google.com; s=arc-20160816; b=Vtbsb7NfE9oDSTN4aSdrP8u84oydLFoAiunraqN4Nzvv675NYDXkvzNQGEhD2o7yZZ LwKOr8NPx15JHIuIF0dFNDR+P1hL8UjnepW18bhR6vCxzcXDgfRqkOOBNeJv4eqwNLUN oU1bHrgofcPOuSh2fT+SEdtxCEV/TysUkSEYfnnH3J2uXN54I2JWcgEfpAfLAN2Qjnk9 q/nPKqpGXNfGRN/RZG2aYyu3i1Q2HTPivs8oXsbKWfjhsP9ZFgpYcvHbIbwhrN6cZ/DD HtACNdxEn5xP8PlXEaOwdFGSHzx/7wFCbt1CUOEo7XOU6BAATlkRopva95XUn64f2C3F FGCQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:to:from:dkim-signature; bh=B8Zkh3mNDdOpw0jIt3tQhu0ugaNbqE0N5/0eIGnZgGQ=; b=W777uurqNSuCkjodNEGYgYPtiYmiuPToz0dfVz9kfOmjAoGOgGffJMqP+oxSojzFtV mNHn+MeSSsouQ2eo0Zictqqh2elEwr3kZBcfjuzT2kyocca1n4kZBWLM9D9pPKJm3oKD 0VCXqwb4YD//6qm50fXslCgyjDrhbkGaCUBPU75WPMiCxaYzwxvxa8l8JyxE3ISByBGv uat5TpYtXS8niMEw/gvtxR026WwGSLv5nWFqVZDxWun60LA2oslTC2uIJvhGgKP11TMT 9PeU8cY9Vh+MuXXCtQsR7OKumRNj4jBsT9zCHAQ/usAwpxOgR8ARCenbm90SYw/W7B3g SV7A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@silvair-com.20150623.gappssmtp.com header.s=20150623 header.b=oTRAOxTi; spf=pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h15si1445026plr.23.2019.07.03.00.17.39; Wed, 03 Jul 2019 00:17:53 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@silvair-com.20150623.gappssmtp.com header.s=20150623 header.b=oTRAOxTi; spf=pass (google.com: best guess record for domain of linux-bluetooth-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727185AbfGCHRE (ORCPT + 99 others); Wed, 3 Jul 2019 03:17:04 -0400 Received: from mail-lj1-f195.google.com ([209.85.208.195]:46807 "EHLO mail-lj1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726490AbfGCHRD (ORCPT ); Wed, 3 Jul 2019 03:17:03 -0400 Received: by mail-lj1-f195.google.com with SMTP id v24so1183891ljg.13 for ; Wed, 03 Jul 2019 00:17:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=silvair-com.20150623.gappssmtp.com; s=20150623; h=from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=B8Zkh3mNDdOpw0jIt3tQhu0ugaNbqE0N5/0eIGnZgGQ=; b=oTRAOxTittJEKicG8zry7F32LHp/y0/pzVCHxZY1wT+H3pGgKRHPzPNV80yTjlNBmq WcOEm9CqIORxssZD8oQLOm53/8GT9GyW1YG7BORiQvkd91mPj53ucOVuSZFdB1YvsIPc BzRHFTDvi8JcUENWpMW/lIu55VauMV/epmXs/ypubLDB4fcJ8dIkFOJoQ1RIDICqv6g9 M03ns3Jx4jQNRoJdy6n+MclQ8nIvebz+tqVCKIKgjV96OXb1c7q5iFezA8a2+4lfDZG/ qCFurQV0oMlpDDLYhLggSogHC8Ce78DEu5Uvr2MD51juoegSJ2Iqo6ra0qgyQYYKapbE NOAA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=B8Zkh3mNDdOpw0jIt3tQhu0ugaNbqE0N5/0eIGnZgGQ=; b=fj8pREYxEs+PLSCS0ugtgesI7dZP/X3c70BDbNnQaeE4x2kE9RV9yhOUu/WSQflmgR t7jQeJtdEgj5BgTkHDND1Itg8cEkkRCfGxkUTIGwlXnsthUMPFu9zft7U5rYK3YUnTV9 tXxo9UoRxchdSJB00Ehckd55dsjWb7bGg8l7rJ1oLGCZiWEyyTHrEITvcmhoYFFJDOUX MlRo2/Z0DdqPohScXX5G4XeLeQWaYt+keZUBOr5tW66chyR7fHw3+4vlt7wBFUxdUP9u jZTZc8fqYqeDS32WzNpJtn/jcl0wQK0AZC6RVZyWWPBA9K2qeITRBkOD2KeINGK7IqNM qYrg== X-Gm-Message-State: APjAAAUgZyXB1CpP/xCKwao77HsF7ZHmjYi8XBDUzcSH2tJffcq6g8kk OrgrFIAQVU33U2oaVrBiIyyTCMA+9zY= X-Received: by 2002:a2e:89c8:: with SMTP id c8mr9802300ljk.70.1562138220491; Wed, 03 Jul 2019 00:17:00 -0700 (PDT) Received: from mlowasrzechonek2133.silvair.lan ([217.153.94.18]) by smtp.gmail.com with ESMTPSA id l11sm281364lfc.18.2019.07.03.00.16.59 for (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Wed, 03 Jul 2019 00:16:59 -0700 (PDT) From: =?UTF-8?q?Micha=C5=82=20Lowas-Rzechonek?= To: linux-bluetooth@vger.kernel.org Subject: [PATCH BlueZ v3 0/3] Add possibility to use remote device keys Date: Wed, 3 Jul 2019 09:16:53 +0200 Message-Id: <20190703071656.6342-1-michal.lowas-rzechonek@silvair.com> X-Mailer: git-send-email 2.19.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-bluetooth-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org +Fixed build/checkpatch errors +Removed unused APP_IDX_NET and APP_IDX_ANY This patchset adds support for sending and receiving messages encrypted with remote device keys. This plugs a 'leak' in the API where it was possible to exchange such messages using Send()/MessageReceived() API by using 0x7fff app key index. In order to allow the application to receive responses from a local Config Server model, messages originating from a local node and encrypted using local device key are also forwarded to the application via D-Bus (assuming they were not handled by one of internal models). MichaƂ Lowas-Rzechonek (3): mesh: Split APP_IDX_DEV into APP_IDX_DEV_LOCAL and APP_IDX_DEV_REMOTE mesh: Implement DevKeySend() method on Node interface mesh: Handle messages encrypted with a remote device key mesh/cfgmod-server.c | 15 +++---- mesh/model.c | 96 +++++++++++++++++++++++++++++++++++++------- mesh/net.h | 8 ++-- mesh/node.c | 59 ++++++++++++++++++++++++++- 4 files changed, 151 insertions(+), 27 deletions(-) -- 2.19.1