diff --git a/index.bs b/index.bs index a9b97b3..3406fe9 100644 --- a/index.bs +++ b/index.bs @@ -512,6 +512,20 @@ might also help mitigate certain threats, thus user agents should not provide unnecessarily verbose readouts of sensors data. +Implementations of concrete sensors may define a [=threshold check algorithm=] +so that new readings that do not differ enough from the [=latest readings=] are +discarded. + +Implementations of concrete sensors may define a [=reading quantization +algorithm=] to reduce the accuracy of the [=sensor readings=] received from a +[=device sensor=]. + +Note: these two mitigation measures often complement each other. An +implementation that only executes the [=threshold check algorithm=] might +expose readings that are too precise, while an implementation that only rounds +readings up may provide attackers with information about more precise readings +when raw readings are rounded to different values. + Note: Inaccuracies will further increase for operations carried out on the [=sensor readings=], or time deltas calculated from the [=reading timestamp|timestamps=]. So, this mitigation strategy can affect certain use cases. @@ -711,19 +725,6 @@ define ways to uniquely identify each one. -## Reading change threshold ## {#concepts-reading-change-threshold} - -A [=platform sensor=] reports [=sensor readings|readings=] to the user agent considering -the [=reading change threshold=]. - -The reading change threshold refers to a value which indicates whether or -not the changes in the [=device sensor=]'s measurements were significant enough to -update the corresponding [=sensor readings=]. - -The [=reading change threshold|threshold=] value depends on the surrounding software and hardware -environment constraints, e.g., software power consumption optimizations or the underlying -[=device sensor=]'s accuracy. - ## Sampling Frequency and Reporting Frequency ## {#concepts-sampling-and-reporting-frequencies} For the purpose of this specification, sampling frequency for a [=platform sensor=] is @@ -739,8 +740,12 @@ can support it. The [=sampling frequency=] differs from the [=requested sampling frequency=] in the following cases: - the [=requested sampling frequency=] exceeds upper or lower [=sampling frequency=] bounds supported by the underlying platform. - - the [=reading change threshold|threshold=] value is significant so that some of the - [=device sensor=]'s measurements are skipped and the [=sensor readings=] are not updated. + - the operating system and/or the [=device sensor=] automatically discard + readings that do not differ enough (in absolute or relative terms) from the + previously reported ones via a hardware or operating system filter. + - the [=platform sensor=]'s associated [=sensor type=]'s [=threshold check + algorithm=] fails and the [=platform sensor=]'s [=latest readings=] are not + updated. The reporting frequency for a concrete {{Sensor}} object is defined as a frequency at which the "reading" event is [=fire an event|fired=] at this object. @@ -803,11 +808,23 @@ A [=sensor type=] has a [=permission request algorithm=]. A [=sensor type=] has a [=set/is empty|nonempty=] [=ordered set|set=] of associated [=policy-controlled feature=] tokens referred to as sensor feature names. +A [=sensor type=] may have an associated threshold check +algorithm, which takes as arguments two separate [=sensor readings=] and +determines if they differ enough to cause a [=platform sensor=]'s [=latest +reading=] map to be updated. + +A [=sensor type=] may have an associated reading quantization +algorithm, which takes a [=sensor reading=] and returns a less accurate +[=sensor reading=]. +