Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp9015093pxu; Mon, 28 Dec 2020 04:27:01 -0800 (PST) X-Google-Smtp-Source: ABdhPJyklkebVWthWYkmwZm3WNinvl1o1XSPtqstdn08glnkFkCT7WWvxVMz2btbBFUCt+jU2HN+ X-Received: by 2002:a17:906:e24f:: with SMTP id gq15mr42678151ejb.256.1609158421114; Mon, 28 Dec 2020 04:27:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1609158421; cv=none; d=google.com; s=arc-20160816; b=tbihM6K27ZXvgv3wE6Si3gl9xD6r8XIFB/nScGE8STDMw5haeWUYrqE0BZ57YKXedV y8mWOkG5Vs7gGzbXjBDysp03nsx9PH2tORRhe3ws1QUPSnghet3PQJfhcW2n8tqd4upl 3PsVlXysVEnD00mjEPeAHDRaxQRuzegLzzg8Xc3eOh21ugm5nEHort+7PslM8C7unaDV c6khFC45pb0q/A84Mh8k4ajqlRAn3A1VVyVy1uYqr5TDSBKBVPcDHlYzYMvJjOeBEUYH kMYt3sF0jVqGTmXdUuYxp6V6clSq4WFbd5/klDlOfmmeby6B8BKatW9KcqEjkjnLroKU JTRQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=Bux0fKYVircx26loAie6xLJ1PXjbaWFXzAdYLDEUatA=; b=HOYoVpqxwtkiT3Xuaw/7n/VgZPrEbWfHlbNhUXG4EIN/0TXYRZCwqZ105QJUB8sVus Fy7astk4BTdQNLziv+eUoy6ZXjR/OzHkq0vAjRQxP/Xkvp7xarpWQXZAFLoSNkhauqQR FofaYqJGATqobLw6xvcX3Ir7nLroRuuyMEZEx3OrQs4TeOynA7S7HjgBTbTnpThkNamC rohEozIWcLIR3PQVm5Ar5AE7T9PUYp8SoudZPcNzKllN9ZXMGPV01gbswf2ZKZV0R5TE f9qJOy8L2E0890wS6cnfJWnqCG8MMG9ftL4Ik3hTJjbXiZmiV0TUIRm4s2dYvbQXIPzs zJng== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@orcam.com header.s=google header.b="cm/+Q87+"; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f12si22959980edx.584.2020.12.28.04.26.28; Mon, 28 Dec 2020 04:27:01 -0800 (PST) Received-SPF: pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@orcam.com header.s=google header.b="cm/+Q87+"; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727448AbgL1MYy (ORCPT + 99 others); Mon, 28 Dec 2020 07:24:54 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42150 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727319AbgL1MYy (ORCPT ); Mon, 28 Dec 2020 07:24:54 -0500 Received: from mail-wr1-x42e.google.com (mail-wr1-x42e.google.com [IPv6:2a00:1450:4864:20::42e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D714DC061794 for ; Mon, 28 Dec 2020 04:24:13 -0800 (PST) Received: by mail-wr1-x42e.google.com with SMTP id c5so11174956wrp.6 for ; Mon, 28 Dec 2020 04:24:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=orcam.com; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=Bux0fKYVircx26loAie6xLJ1PXjbaWFXzAdYLDEUatA=; b=cm/+Q87+IGzzqubO4krXHtoujIzTGNseUTKVRNllXwKi0F6Y3Vg2W/eAImbHVZh7ef G0y96C3+mdZUrAe0ufQaA4g5OuzwkBbkZzl2/tPzwUfRnCVnpJy+DwrKWpgSowFv5foF hTK7UbQ1im5C4+225mRRNCRO8V58th9KFOuZU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=Bux0fKYVircx26loAie6xLJ1PXjbaWFXzAdYLDEUatA=; b=KOeQGNrB7buNFjYjCWnD71W9HWGG4DM9ONRt4M4uktffaYuwy7YzZS7oKyNqhLZKVx eyt1NmtGMYQxpn0LrQGHxo7BQ9ygy5jf7DEvDp2k9zrfuAmzSnpGmF2jUVHK7onl233/ UGuSjAMV05WD7HHu+qNw2Ro+2KWPgeLP3KLIkVVzF0L9PTaTBK3XO6w7kVUWoTyy3A6z 9NIrcnCEjiw3fIX9K6miPV7vS/IWtkmoW/ZuCsCWkgT4hY30E9D/NDn5qrEj+TBlvx8d SEWxBrt/dMj60bxF/2dYHDlmrmGT2v6RbE+SrthyCEmKLg26X6uMp20wGKWBMS4g/SCc ujMA== X-Gm-Message-State: AOAM532eWAijy0UYLA4lM2R3zdOOo1iBeXaiTWLU6KrtDHnreGJPhGID Rwx1doOEUnm1j4tJHTA5vydQlM8ZuvYVDdKH95txZCCYI7T9u6W1 X-Received: by 2002:adf:fdcb:: with SMTP id i11mr51741133wrs.349.1609158252412; Mon, 28 Dec 2020 04:24:12 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Ordit Gross Date: Mon, 28 Dec 2020 14:24:01 +0200 Message-ID: Subject: Re: getting address type from scan result To: linux-bluetooth@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org just to clarify, the needed information is: > HCI Event: LE Meta Event (0x3e) plen 37 #324 [hci0] 1064.855314 LE Advertising Report (0x02) Num reports: 1 Event type: Connectable undirected - ADV_IND (0x00) Address type: Random (0x01) Address: 5B:6C:86:BE:2C:40 (Resolvable) the only way I could think of is by opening an hci socket.. is there any other way? thanks for your help! On Fri, Dec 25, 2020 at 6:28 AM Ordit Gross wrote: > > hi, > > Up till now the peripheral device we worked against was configured > with public address, > now it might also be random (both BDADDR_LE_RANDOM, BDADDR_LE_PUBLIC). > The type of address is needed to connect correctly to the device > (using l2cap_connect). > > How can I get the address type from the scan report? > I'm currently using bluetoothctl, which seems not to expose this > information in Device1 interface. > thanks in advance! and happy holidays > > -- --