Received: by 2002:a25:824b:0:0:0:0:0 with SMTP id d11csp2398452ybn; Thu, 26 Sep 2019 11:15:40 -0700 (PDT) X-Google-Smtp-Source: APXvYqxIxlCHlSERo/Di6yJWw5tLOOfO1FIHKmJE4f6i84BI8+hRyx73oPuobxHnyEooVITPSnDU X-Received: by 2002:a50:f152:: with SMTP id z18mr97209edl.141.1569521740272; Thu, 26 Sep 2019 11:15:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1569521740; cv=none; d=google.com; s=arc-20160816; b=LdQ4vWkRZYePE7uJ97YJo9Mqh07Tuis7apGWhsydY+j44mnsKE54JYKiODze9gCnJd G/MumYq92woVF+FcV7nCnB9LjBg0893mosEktaBSXpbKYM4o/ZcpGpWYYFF7Od7AYRJV VIjTcamQq8pnVBWB9HuPs2AM7mmuiwTOahi3Xw26nOfIy2+qu5CqGvWEl+qYSe7gQx2j jrWDWIG1jEHF9zhxgtSSZIIQ/L5AJXTqXqcin9I+IohVrTbgW3bX0/11TGWpRqtuD/1A WEQjrVJAjeD8XT+Zchwe/cB26BL/Y0bMvS24kIlDYXjEUVwyx69wlse63c7/8zzl+XFW uc8Q== 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:cc:to:from; bh=//Cx1FN9SaKyUUDL08OcQqk3VAUFkAIfMWN5Wyet4Q4=; b=sCAPuuyXbYOqcbgohJoB/lp+7eT7FXvI0qaEvHy2BII+71/uyyQ72su/OxBM3PXYmF RIPoR6apzmX+kYTx6VITnZ/c8fORDTcm3CXUG/jK+Qo2GkuBsrMR7q/XnFwKU6sX9OuG G28W75yuLgTbalBEyb2PySoDENhJClQivnx9RLgtH57okaKoJRtTsIuIOf9x3JwzbG9z wAjvx0ewXyppdWm8+knrXTXYFvvDVqBGQ0tfdRMmfL7qxW0/gat69EFJ70TOTbeBw8dQ vesXLXAm0Wb/BqHKaZLcjY2lY3jCkGxRphtnCaLPdvc3HYuan/KoMltSAv3uiHLUeE9P uujg== ARC-Authentication-Results: i=1; mx.google.com; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e48si45652eda.130.2019.09.26.11.15.01; Thu, 26 Sep 2019 11:15:40 -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; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727502AbfIZSOz (ORCPT + 99 others); Thu, 26 Sep 2019 14:14:55 -0400 Received: from mga03.intel.com ([134.134.136.65]:23148 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726029AbfIZSOy (ORCPT ); Thu, 26 Sep 2019 14:14:54 -0400 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by orsmga103.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 26 Sep 2019 11:14:54 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.64,552,1559545200"; d="scan'208";a="196460992" Received: from bgi1-mobl2.amr.corp.intel.com ([10.251.25.152]) by FMSMGA003.fm.intel.com with ESMTP; 26 Sep 2019 11:14:53 -0700 From: Brian Gix To: linux-bluetooth@vger.kernel.org Cc: brian.gix@intel.com, inga.stotland@intel.com, michal.lowas-rzechonek@silvair.com Subject: [PATCH BlueZ v3 0/3] mesh: Fix Remote/Local dev key usage Date: Thu, 26 Sep 2019 11:14:41 -0700 Message-Id: <20190926181444.4916-1-brian.gix@intel.com> X-Mailer: git-send-email 2.21.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-bluetooth-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org V3: By popular demand, the name "remote" is now used for both DevKeySend() and DevKeyMessageReceived(). In DevKeySend(), setting remote == true means that the Key Ring *must* be used to encrypt the outgoing message, and a failure will be returned if the requested destination address does not include a device key in the local key ring. For remote == false requests, the request will be rejected if the destination is an element on the local node. In DevKeyMessageReceived(), the remote boolean will be set == true if it required the key ring to decrypot the message. If remote == false, this means that the local nodes Device Key successfully decrypted the message, and the message may be used to change or query privileged states. Brian Gix (3): mesh: Add local/remote bools to DevKey transactions mesh: Use explicit Local vs Remote Device key usage mesh: Fix Key Ring permissions for local nodes doc/mesh-api.txt | 17 ++++++++++++++--- mesh/manager.c | 5 ----- mesh/model.c | 11 +++++++---- mesh/node.c | 40 +++++++++++++++------------------------- 4 files changed, 36 insertions(+), 37 deletions(-) -- 2.21.0