From 2fbed18f183bcb10652601e580f30976903e2ce4 Mon Sep 17 00:00:00 2001 From: Macpie Date: Thu, 12 Sep 2024 14:03:27 -0700 Subject: [PATCH 01/13] Start on radio_location_estimates --- src/service/poc_mobile.proto | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/src/service/poc_mobile.proto b/src/service/poc_mobile.proto index ff5b4094..b3962558 100644 --- a/src/service/poc_mobile.proto +++ b/src/service/poc_mobile.proto @@ -842,3 +842,30 @@ message verified_subscriber_verified_mapping_event_ingest_report_v1 { // Timestamp in milliseconds since unix epoch uint64 timestamp = 3; } + +enum EventType { + TOWER = 1; + DISCO_MAPPING = 2; + VERIFICATION_MAPPING = 3; +} + +message rle_event_v1 { + EventType type = 1; + uint64 timestamp = 2; +} + +message radio_location_estimate_v1 { + uint32 radius = 1; + uint32 confidence = 2; + repeated rle_event_v1 events = 3; +} + +message radio_location_estimates_v1 { + string radio_id = 1; + repeated radio_location_estimate_v1 estimates = 2; + // unix epoch timestamp in seconds + uint64 timestamp = 3; + // pubkey binary of the signing keypair + bytes signer = 4; + bytes signature = 5; +} From 8837de14498d26485ced25ae21e710fa4a0c5d02 Mon Sep 17 00:00:00 2001 From: Macpie Date: Thu, 12 Sep 2024 14:48:22 -0700 Subject: [PATCH 02/13] Remove event type --- src/service/poc_mobile.proto | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/service/poc_mobile.proto b/src/service/poc_mobile.proto index b3962558..883a3407 100644 --- a/src/service/poc_mobile.proto +++ b/src/service/poc_mobile.proto @@ -843,14 +843,8 @@ message verified_subscriber_verified_mapping_event_ingest_report_v1 { uint64 timestamp = 3; } -enum EventType { - TOWER = 1; - DISCO_MAPPING = 2; - VERIFICATION_MAPPING = 3; -} - message rle_event_v1 { - EventType type = 1; + string id = 1; uint64 timestamp = 2; } From 1a5ec41185a6ef6561afb6e2d423231c8022f16f Mon Sep 17 00:00:00 2001 From: Macpie Date: Fri, 13 Sep 2024 15:12:42 -0700 Subject: [PATCH 03/13] Add submit_radio_location_estimates api --- src/service/poc_mobile.proto | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/service/poc_mobile.proto b/src/service/poc_mobile.proto index 883a3407..3a8fcd3a 100644 --- a/src/service/poc_mobile.proto +++ b/src/service/poc_mobile.proto @@ -303,6 +303,8 @@ service poc_mobile { rpc submit_subscriber_verified_mapping_event( subscriber_verified_mapping_event_req_v1) returns (subscriber_verified_mapping_event_res_v1); + rpc submit_radio_location_estimates(radio_location_estimates_req_v1) + returns (radio_location_estimates_resp_v1); } message file_info { @@ -854,7 +856,7 @@ message radio_location_estimate_v1 { repeated rle_event_v1 events = 3; } -message radio_location_estimates_v1 { +message radio_location_estimates_req_v1 { string radio_id = 1; repeated radio_location_estimate_v1 estimates = 2; // unix epoch timestamp in seconds @@ -863,3 +865,5 @@ message radio_location_estimates_v1 { bytes signer = 4; bytes signature = 5; } + +message radio_location_estimates_resp_v1 { string id = 1; } From 6e79fcd0f16b9c27e50702b9e6bca5decaa0b729 Mon Sep 17 00:00:00 2001 From: Macpie Date: Tue, 17 Sep 2024 12:11:53 -0700 Subject: [PATCH 04/13] Update radius and confidence to Decimal --- src/service/poc_mobile.proto | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/service/poc_mobile.proto b/src/service/poc_mobile.proto index 3a8fcd3a..38d2f080 100644 --- a/src/service/poc_mobile.proto +++ b/src/service/poc_mobile.proto @@ -851,8 +851,8 @@ message rle_event_v1 { } message radio_location_estimate_v1 { - uint32 radius = 1; - uint32 confidence = 2; + Decimal radius = 1; + Decimal confidence = 2; repeated rle_event_v1 events = 3; } From be5e870cfb6bb328cbd87170113f992c1302361b Mon Sep 17 00:00:00 2001 From: Macpie Date: Tue, 1 Oct 2024 11:00:22 -0700 Subject: [PATCH 05/13] Add reports --- src/service/poc_mobile.proto | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/src/service/poc_mobile.proto b/src/service/poc_mobile.proto index 38d2f080..929a7954 100644 --- a/src/service/poc_mobile.proto +++ b/src/service/poc_mobile.proto @@ -852,6 +852,7 @@ message rle_event_v1 { message radio_location_estimate_v1 { Decimal radius = 1; + // TODO: lat long Decimal confidence = 2; repeated rle_event_v1 events = 3; } @@ -862,8 +863,26 @@ message radio_location_estimates_req_v1 { // unix epoch timestamp in seconds uint64 timestamp = 3; // pubkey binary of the signing keypair - bytes signer = 4; + bytes carrier_key = 4; bytes signature = 5; } message radio_location_estimates_resp_v1 { string id = 1; } + +message radio_location_estimates_ingest_report_v1 { + // unix epoch timestamp in seconds + uint64 received_timestamp = 1; + radio_location_estimates_req_v1 report = 2; +} + +enum radio_location_estimates_verification_status { + radio_location_estimates_verification_status_valid = 0; + radio_location_estimates_verification_status_invalid_key = 1; +} + +message verified_radio_location_estimates_report_v1 { + radio_location_estimates_ingest_report_v1 report = 1; + radio_location_estimates_verification_status status = 2; + // unix epoch timestamp in seconds + uint64 timestamp = 3; +} From f80db57b69c9ef47b41535b916ddda5d5c942181 Mon Sep 17 00:00:00 2001 From: Macpie Date: Wed, 2 Oct 2024 15:07:56 -0700 Subject: [PATCH 06/13] Add lat long to estimates --- src/service/poc_mobile.proto | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/service/poc_mobile.proto b/src/service/poc_mobile.proto index 929a7954..2d33831f 100644 --- a/src/service/poc_mobile.proto +++ b/src/service/poc_mobile.proto @@ -852,9 +852,10 @@ message rle_event_v1 { message radio_location_estimate_v1 { Decimal radius = 1; - // TODO: lat long - Decimal confidence = 2; - repeated rle_event_v1 events = 3; + Decimal lat = 2; + Decimal long = 3; + Decimal confidence = 4; + repeated rle_event_v1 events = 5; } message radio_location_estimates_req_v1 { From 87c7bbe8af4e95a108bc9b7138ed8f56a9a3ec7b Mon Sep 17 00:00:00 2001 From: Macpie Date: Mon, 14 Oct 2024 10:15:59 -0700 Subject: [PATCH 07/13] Make radio_id into entity so we can make diff between wifi and cbrs --- src/service/poc_mobile.proto | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/src/service/poc_mobile.proto b/src/service/poc_mobile.proto index 2d33831f..0230e25c 100644 --- a/src/service/poc_mobile.proto +++ b/src/service/poc_mobile.proto @@ -859,13 +859,16 @@ message radio_location_estimate_v1 { } message radio_location_estimates_req_v1 { - string radio_id = 1; - repeated radio_location_estimate_v1 estimates = 2; + oneof entity { + string cbrs_id = 1; + bytes wifi_pub_key = 2; + } + repeated radio_location_estimate_v1 estimates = 3; // unix epoch timestamp in seconds - uint64 timestamp = 3; + uint64 timestamp = 4; // pubkey binary of the signing keypair - bytes carrier_key = 4; - bytes signature = 5; + bytes carrier_key = 5; + bytes signature = 6; } message radio_location_estimates_resp_v1 { string id = 1; } From 600bfe1ac20f4fd35e00230ea25109e807574e65 Mon Sep 17 00:00:00 2001 From: Macpie Date: Wed, 16 Oct 2024 16:46:42 -0700 Subject: [PATCH 08/13] change long to lon --- src/service/poc_mobile.proto | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/service/poc_mobile.proto b/src/service/poc_mobile.proto index 0230e25c..8cc7e989 100644 --- a/src/service/poc_mobile.proto +++ b/src/service/poc_mobile.proto @@ -853,7 +853,7 @@ message rle_event_v1 { message radio_location_estimate_v1 { Decimal radius = 1; Decimal lat = 2; - Decimal long = 3; + Decimal lon = 3; Decimal confidence = 4; repeated rle_event_v1 events = 5; } From 4831c3afcc9821ef7f3c57bb659b0e9ff96d7f12 Mon Sep 17 00:00:00 2001 From: Michael Jeffrey Date: Fri, 25 Oct 2024 15:02:54 -0700 Subject: [PATCH 09/13] use a list of res12 hexes for estimates we use hexes in many places in the system, let's conform to that here as well --- src/service/poc_mobile.proto | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/service/poc_mobile.proto b/src/service/poc_mobile.proto index 8cc7e989..44f95457 100644 --- a/src/service/poc_mobile.proto +++ b/src/service/poc_mobile.proto @@ -851,9 +851,8 @@ message rle_event_v1 { } message radio_location_estimate_v1 { - Decimal radius = 1; - Decimal lat = 2; - Decimal lon = 3; + // The res12 h3 indexes of the estimated covered area + repeated uint64 hexes = 1; Decimal confidence = 4; repeated rle_event_v1 events = 5; } From 9604df6ca41f29fda6f2c41a908128a71b6eed81 Mon Sep 17 00:00:00 2001 From: Michael Jeffrey Date: Wed, 30 Oct 2024 14:36:38 -0700 Subject: [PATCH 10/13] Use center hex and grid distance for estimate event Enumerating all the possible valid hexes for a location estimate can create extremely large messages for estimates with large radius. Sending the center hex and grid distance does a few things. - Compacts the message - speaks in terms of hexes like most other things in the system - Provides an easy way to check locations using h3.grid_distance(center, target) <= grid_distance --- src/service/poc_mobile.proto | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/service/poc_mobile.proto b/src/service/poc_mobile.proto index 44f95457..85ff77a1 100644 --- a/src/service/poc_mobile.proto +++ b/src/service/poc_mobile.proto @@ -851,10 +851,12 @@ message rle_event_v1 { } message radio_location_estimate_v1 { - // The res12 h3 indexes of the estimated covered area - repeated uint64 hexes = 1; - Decimal confidence = 4; - repeated rle_event_v1 events = 5; + // The res12 h3 index representing the center of the estimate + uint64 hex = 1; + // h3 grid distance the location confidence applies to + uint32 grid_distance = 2; + Decimal confidence = 3; + repeated rle_event_v1 events = 4; } message radio_location_estimates_req_v1 { From 7716e9d854c8ed854d62378f6772ee84e6acfe27 Mon Sep 17 00:00:00 2001 From: Michael Jeffrey Date: Thu, 31 Oct 2024 14:48:10 -0700 Subject: [PATCH 11/13] update rle_event_v1 -> radio_location_correlation_v1 At this time, the most imformation we can expose about the events that led to the radio location estimate is an id and timestamp. There may be more information in the future, but this is enough information for someone to give us and we can fetch the underlying record for investigation. --- src/service/poc_mobile.proto | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/service/poc_mobile.proto b/src/service/poc_mobile.proto index 85ff77a1..90b89eb2 100644 --- a/src/service/poc_mobile.proto +++ b/src/service/poc_mobile.proto @@ -845,7 +845,7 @@ message verified_subscriber_verified_mapping_event_ingest_report_v1 { uint64 timestamp = 3; } -message rle_event_v1 { +message radio_location_correlation_v1 { string id = 1; uint64 timestamp = 2; } @@ -856,7 +856,7 @@ message radio_location_estimate_v1 { // h3 grid distance the location confidence applies to uint32 grid_distance = 2; Decimal confidence = 3; - repeated rle_event_v1 events = 4; + repeated radio_location_correlation_v1 radio_location_correlations = 4; } message radio_location_estimates_req_v1 { From 01960a84fad67adc3006febb6840d7b8b72d22b1 Mon Sep 17 00:00:00 2001 From: Michael Jeffrey Date: Wed, 13 Nov 2024 17:19:20 -0700 Subject: [PATCH 12/13] remove list of correlation ids This are stored in a table that can be fetched by the entity_id --- src/service/poc_mobile.proto | 6 ------ 1 file changed, 6 deletions(-) diff --git a/src/service/poc_mobile.proto b/src/service/poc_mobile.proto index 90b89eb2..ec23fef2 100644 --- a/src/service/poc_mobile.proto +++ b/src/service/poc_mobile.proto @@ -845,18 +845,12 @@ message verified_subscriber_verified_mapping_event_ingest_report_v1 { uint64 timestamp = 3; } -message radio_location_correlation_v1 { - string id = 1; - uint64 timestamp = 2; -} - message radio_location_estimate_v1 { // The res12 h3 index representing the center of the estimate uint64 hex = 1; // h3 grid distance the location confidence applies to uint32 grid_distance = 2; Decimal confidence = 3; - repeated radio_location_correlation_v1 radio_location_correlations = 4; } message radio_location_estimates_req_v1 { From acc47b190afd5b259108a691644b6d352a4e88d8 Mon Sep 17 00:00:00 2001 From: Michael Jeffrey Date: Wed, 13 Nov 2024 17:19:39 -0700 Subject: [PATCH 13/13] cbrs_id -> cbsd_id, Oracles only know about cbsd_id --- src/service/poc_mobile.proto | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/service/poc_mobile.proto b/src/service/poc_mobile.proto index ec23fef2..b12f43b9 100644 --- a/src/service/poc_mobile.proto +++ b/src/service/poc_mobile.proto @@ -855,7 +855,7 @@ message radio_location_estimate_v1 { message radio_location_estimates_req_v1 { oneof entity { - string cbrs_id = 1; + string cbsd_id = 1; bytes wifi_pub_key = 2; } repeated radio_location_estimate_v1 estimates = 3;