Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into map/decimalize
Browse files Browse the repository at this point in the history
  • Loading branch information
maplant committed Jul 10, 2024
2 parents 07a8349 + ff0d2ba commit 235e85f
Show file tree
Hide file tree
Showing 3 changed files with 52 additions and 5 deletions.
4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,11 @@ members = ["beacon"]
# Pin to 0.10 to avoid issues with tls and solana dalek deps
tonic = { version = "0.10" }
bytes = "1"
prost = "0"
prost = "0.12"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
tonic-build = { version = "0.10" }
prost-build = "0"
prost-build = "0.12"

[features]
default= []
Expand Down
5 changes: 2 additions & 3 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,8 @@ pub use prost::{DecodeError, EncodeError, Message};
#[cfg(feature = "services")]
pub mod services {
use crate::{
BlockchainRegionParamsV1, BlockchainTokenTypeV1, BlockchainTxn, BoostedHexInfoV1,
BoostedHexUpdateV1, DataRate, EntropyReportV1, GatewayStakingMode, MapperAttach, Region,
RoutingAddress, ServiceProvider,
BlockchainRegionParamsV1, BlockchainTokenTypeV1, BlockchainTxn, BoostedHexInfoV1, DataRate,
EntropyReportV1, GatewayStakingMode, MapperAttach, Region, RoutingAddress, ServiceProvider,
};

pub mod iot_config {
Expand Down
48 changes: 48 additions & 0 deletions src/service/poc_mobile.proto
Original file line number Diff line number Diff line change
Expand Up @@ -286,6 +286,9 @@ service poc_mobile {
rpc submit_invalidated_threshold_report(
invalidated_radio_threshold_report_req_v1)
returns (invalidated_radio_threshold_report_resp_v1);
rpc submit_sp_boosted_rewards_banned_radio(
service_provider_boosted_rewards_banned_radio_req_v1)
returns (service_provider_boosted_rewards_banned_radio_resp_v1);
}

message file_info {
Expand Down Expand Up @@ -372,6 +375,8 @@ enum seniority_update_reason {
seniority_update_reason_heartbeat_not_seen = 0;
// A new coverage object replaces the old seniority
seniority_update_reason_new_coverage_claim_time = 1;
// A service provider marked the radio banned from boosted rewards
seniority_update_reason_service_provider_ban = 2;
}

message speedtest_avg {
Expand Down Expand Up @@ -616,3 +621,46 @@ message oracle_boosting_hex_assignment {
// Landtype assignment
assignment landtype = 5;
}

message service_provider_boosted_rewards_banned_radio_req_v1 {
enum sp_boosted_rewards_banned_radio_reason {
unbanned = 0;
no_network_correlation = 1;
}
// pubkey of signer
bytes pubkey = 1;
oneof key_type {
// For CBRS radio
string cbsd_id = 2;
// For WiFi radio
bytes hotspot_key = 3;
}
sp_boosted_rewards_banned_radio_reason reason = 4;
// Timestamp in seconds since epoch of when ban ends
uint64 until = 5;
bytes signature = 6;
}

message service_provider_boosted_rewards_banned_radio_resp_v1 { string id = 1; }

message service_provider_boosted_rewards_banned_radio_ingest_report_v1 {
// Timestamp in milliseconds since the epoch
uint64 received_timestamp = 1;
service_provider_boosted_rewards_banned_radio_req_v1 report = 2;
}

enum service_provider_boosted_rewards_banned_radio_verification_status {
sp_boosted_rewards_ban_valid = 0;
sp_boosted_rewards_ban_invalid_carrier_key = 1;
}

message
verified_service_provider_boosted_rewards_banned_radio_ingest_report_v1 {
// The verified report
service_provider_boosted_rewards_banned_radio_ingest_report_v1 report = 1;
// The status determined by the verification
service_provider_boosted_rewards_banned_radio_verification_status status = 2;
// Timestamp at which verification was determined, in milliseconds since unix
// epoch
uint64 timestamp = 3;
}

0 comments on commit 235e85f

Please sign in to comment.