core/java/android/os/BytesMatcher.java
0 → 100644
+248
−0
+133
−0
Loading
Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more
As part of an upcoming feature, we're anticipating the need to match arbitrary byte sequences, such as Bluetooth UUIDs or MAC addresses, so this change adds a new BytesMatcher similar in spirit to the existing PatternMatcher. It supports a reasonably compact serialization format which can be used to transport a server-pushed deny-list. The choice to support both "accept" and "reject" rules in an ordered list means that very complex matching rules can be expressed efficiently. Bug: 181812624 Test: atest FrameworksCoreTests:android.os.BytesMatcherTest Change-Id: I55193051354278abaef8bef51413c632b07c7177