Open Source / ALEAPP #1817

Network, radio and telephony state from bug reports

Which Wi-Fi networks did a phone know, which interfaces and apps carried data, what did Bluetooth, NFC and USB do, and which SIM and carrier settings were active? An Android bug report records all of it, in a dozen layouts. This contribution teaches ALEAPP to read those layouts into 37 tables.

  • Daniel Addai, SectraTEK Lab
  • Merged
  • CC BY 4.0

View the pull request on GitHub

Summary

  • ALEAPP now has 37 Bug Report artifacts for connectivity in four groups: Wi-Fi (6), network (14), Bluetooth, NFC and USB (10) and telephony (7). The pull request was merged on 27 October 2026.
  • Most timestamps in these dumps carry no year, and one list carries no date at all. The readers keep the printed text and add a UTC value only where the report holds enough to compute it.
  • Counts equal counts made from the raw text on every report that has the section. Five Wi-Fi and usage tables also equal a second parser, with one named difference.
  • Sections that a report does not print, and sections that are printed but not read, are listed, so an empty table is not mistaken for a quiet radio.
  • 37artifacts added in four groups
  • 245test baselines in 2 case folders
  • 60,684network usage rows on the larger of two reports, equal to a raw-text count
  • 4,241NFC driver log rows on one report; the other report prints none

Methodology note

Drafted with AI assistance and reviewed by the author before publication. Every figure uses synthetic example values or counts taken from the pull request.

The issue

An examiner is asked whether a phone had been on a particular Wi-Fi network, whether it had paired with a Bluetooth device, whether a USB connection was made, or which SIM and carrier configuration it used. A bug report prints the state of each of those services, but in a different layout for each service. Many of the timestamped lines carry month, day and clock time with no year, and one list, the private DNS log, carries only the time of day.

Small differences decide whether a reading is right. Android 10 builds print fewer pairs in a connection event, so two columns are empty there. Some builds print a network name in quotes, some shortened or masked. Bluetooth addresses are partly masked by the platform in three of the five early reports, and the Motorola report prints complete addresses. The network statistics can be printed twice, in the netstats dump and again in the CHECKIN NETSTATS section, so a report that prints both lists its buckets twice. The artifact says which section printed each row, so the two copies are visible and are not merged.

Absence is the third problem. One Android 16 report has no NFC section, so the NFC artifacts are empty for it, and another has no USB or telecom section. Without a record of which sections exist, those empty tables look like a quiet radio. The Lab's section index (LAB-TR-0001) keeps that record. Figure 1 shows how one event line becomes one row, including the missing year.

One Wi-Fi connection event in the report text and the row it becomesLeft: an invented connection event line with no year, the report time and the zone property. Right: the fields of the Wi-Fi Connection Events row, with the year taken from the report time and the time converted to UTC.In the report text (synthetic example)In the artifact (one row)== dumpstate: 2026-03-14 10:00:00[persist.sys.timezone]: [Europe/Paris]mConnectionEvents:startTime=03-14 09:26:53.589, SSID="ExampleNet",  durationMillis=4120, roamType=1,  connectionResult=1, signalStrength=-61The event is one line in the report, wrapped here.Report time and zone are printed in two other places.SSID"ExampleNet"Duration (ms)4120Roam Type1Connection Result1Signal Strength-61Start Time As Printed03-14 09:26:53.589Time (UTC)2026-03-14 08:26:53.589No year is printed. The latest year (the report's, or the one before) that does not put the line more than a dayafter the report time is used, and then the zone of the report is applied. Connection Result is shown as stored.
Show this figure as a table
Fields of the row in Figure 1
FieldValue (synthetic example)
SSID"ExampleNet"
Duration (ms)4120
Roam Type1
Connection Result1
Signal Strength-61
Start Time As Printed03-14 09:26:53.589
Time (UTC)2026-03-14 08:26:53.589
Figure 1A connection event line carries month, day and clock time only. The year comes from the report time; the numbers keep their printed form. Source: the notes of Wi-Fi Connection Events in scripts/artifacts/bugreportNetwork.py and the year rule of Location Events. Values are invented (synthetic example).

The essence

The pull request adds 37 artifacts that read the Wi-Fi, network, Bluetooth, NFC, USB and telephony sections of the report text. Each row is what the dump printed for one entry: a saved network, a connection event, a usage bucket, a paired device, a SIM subscription, a carrier setting. Numbers such as connection results and class codes are shown as stored, with no meaning attached. A row says that the service listed or logged that entry. It does not say what a person did.

Two choices keep the tables honest. Where a time has a date but no year, the year follows a stated rule. Where a time has no date, no UTC value is made.

Artifacts added by the pull request
GroupArtifactsReport sections read
Wi-Fi (6)Saved Networks, Connection Events, Current State, Scan Results, State Machine Records, Service Logwifi, wifiscanner, wifip2p
Network (14)Usage Buckets, Policy UID Entries, Policy Settings, Policy Events, Connected Networks, Interfaces, Interface Counters, DNS Servers, Private DNS Log, Open Sockets, Unix Domain Sockets, Socket Details, Tethering Log, Tethering Statenetstats and CHECKIN NETSTATS, netpolicy, connectivity, interface, DNS, socket and tethering sections
Bluetooth, NFC and USB (10)Bluetooth Adapter Status, Devices, Events, Link Key Types; NFC State, Card Emulation Services, Events, Driver Log; USB Manager State, USB Logbluetooth_manager, nfc, usb, the NFC and USB log sections
Telephony (7)Telephony State, SIM Subscriptions, Carrier Config Values, Telephony Service Logs, State Machine Records, Telecom Phone Accounts, Radio Log State Linesphone, isub, carrier_config, telecom, RADIO LOG

Our methodology

We read each service from the text of the reports we hold and write down its layout by Android version and vendor before writing a reader. For Wi-Fi, the saved networks are in one block of the wifi dump; a second block that follows repeats the same networks and is not read, so each network is listed once. The readers plug into the single-pass reader of LAB-TR-0001: the report is streamed once, each open section goes only to its registered readers (Figure 2), and every section, read or not, is entered in the index.

Time is handled in three ways. A wall time with month and day gets a year by the rule in Figure 1 and is converted with the zone the report records. A time of day without a date, as in the private DNS log, gets no UTC value, because any date would be a guess. A count of seconds on the kernel clock, as in the NFC and USB logs, is kept as printed; about one NFC log line in 20 also prints a wall time, and only those lines get a UTC value, left empty with a note when the wall time is earlier than the device start.

Pipeline from the bug report text to the network and radio columnsFive steps: the report file, the section index, readers for network and radio sections, bounded tables and 37 artifacts. Below, columns of two artifacts.From the report text to the report columnsBug report textdumpstate.txt,bugreport-*.txt orbugreport-*.zip(path set of #1809)Section indexevery section entered:name, lines, durationDUMP TIMEOUT keptSection readerswifi, wifiscanner,netstats, netpolicy,connectivity, DNS,NETSTAT, tethering,bluetooth_manager,nfc, usb, isub,carrier_config, telecomBounded tablesrows kept as printedtext cut at set sizesrow caps per table,logged when reached37 artifacts4 groupsHTML, TSV and LAVAoutputUTC where possibleColumns of two of the 37 artifactsWi-Fi Connection Events: SSID | BSSID | Duration (ms) | Roam Type | Connection Result | Signal Strength |   Start Time As Printed | Time (UTC) | Other FieldsBluetooth Events: Event Source | Event | Detail | Address | Time As Printed | Time (UTC)
Show this figure as a table
Steps of Figure 2
StepWhat happens
1. Find the fileThe same path set as the earlier bug report artifacts.
2. Index the sectionsEvery section is entered with kind, name, lines and duration; a time-limit marker is stored on a cut service.
3. Hand over the linesReaders registered for wifi, wifiscanner, wifip2p, netstats, CHECKIN NETSTATS, netpolicy, connectivity, dnsresolver, interface and socket commands, tethering, bluetooth_manager, nfc, usb, isub, carrier_config, telecom and the radio log.
4. Keep bounded rowsRows as printed, text cut at set sizes, row caps with a logged warning.
5. Present37 artifacts in four groups; UTC added where the printed time allows it.
Figure 2The same single pass as the earlier bug report artifacts; only the readers and tables are new. Section and column names are from the pull request. Source: dumpstate_network.py, dumpstate_radios.py, bugreportNetwork.py and bugreportRadios.py in the pull request; LAB-TR-0001, section 3 (diagram).

Checking follows the same layers as the earlier artifacts in the stack. First, synthetic fixtures with invented values: cases per Android layout (a10, a16), a cut dump, an empty report, a file that is not a report, odd bytes, two reports in one run and a zip kept on the device. The two modules have 245 baselines in two case folders, and all pass under TZ=UTC.

Second, an independent recount. On the five older research reports, the Wi-Fi saved networks, connection events, scan results and state machine records, and the network usage buckets, equal a second parser written separately. One field differs on 5 saved-network entries of one report, and the notes name it. For the radio artifacts, counts equal a raw-text count on every report that has the section. Field values of the radio artifacts were checked by eye on samples and not against a second parser, and the limits table says so.

Third, two newer Android 16 reports went through the whole tool with no failed artifact, and counts made with our own line rules equalled the artifact rows for Network Usage Buckets (26,131 and 60,684), Radio Log State Lines (7,983 and 5,804) and NFC Driver Log (none and 4,241) (Figure 3). The 295 bug report unit tests of the stack so far pass, and the changed files score 10.00 of 10 on pylint.

Missing and large data are handled in the open. One large Samsung Wi-Fi section is read to a cap of 20,000 lines and the cut is logged. A list of what the reports print but no artifact reads is in the pull request: two NFC vendor dumps, the GATT scanner map, the telephony registry registrations and lsusb.

Rows per artifact on the two newest Samsung bug reportsGrouped horizontal bars on a logarithmic scale for twelve of the 37 artifacts, from none (Bluetooth Devices and NFC Driver Log on one report) to 60,684 rows (Network Usage Buckets).Rows per artifact on two bug reports (logarithmic scale)Report 1Report 21101001,00010,000100,000Rows (each gridline is ten times the one before)Wi-Fi Saved Networks511Wi-Fi Connection Events2106Wi-Fi State Machine Records3121,174Network Usage Buckets26,13160,684Network Policy UID Entries477589Unix Domain Sockets713771Tethering Log1,0001,000Bluetooth Devices0199NFC Driver Log04,241USB Log1,6932,285Carrier Config Values6765Radio Log State Lines7,9835,804
Show every artifact of this pull request as a table
Rows per artifact on two bug reports
ArtifactReport 1 rowsReport 2 rows
Wi-Fi Saved Networks (Wi-Fi)511
Wi-Fi Connection Events (Wi-Fi)2106
Wi-Fi Current State (Wi-Fi)36
Wi-Fi Scan Results (Wi-Fi)016
Wi-Fi State Machine Records (Wi-Fi)3121,174
Wi-Fi Service Log (Wi-Fi)1,3971,892
Network Usage Buckets (Network)26,13160,684
Network Policy UID Entries (Network)477589
Network Policy Settings (Network)2523
Network Policy Events (Network)1,2031,203
Connected Networks (Network)12
Network Interfaces (Network)5259
Network Interface Counters (Network)5259
DNS Servers (Network)11
Private DNS Log (Network)58100
Open Sockets (Network)6119
Unix Domain Sockets (Network)713771
Socket Details (Network)5812
Tethering Log (Network)1,0001,000
Tethering State (Network)118126
Bluetooth Adapter Status (Bluetooth, NFC and USB)1614
Bluetooth Devices (Bluetooth, NFC and USB)0199
Bluetooth Events (Bluetooth, NFC and USB)2266
Bluetooth Link Key Types (Bluetooth, NFC and USB)03
NFC State (Bluetooth, NFC and USB)030
NFC Card Emulation Services (Bluetooth, NFC and USB)09
NFC Events (Bluetooth, NFC and USB)0100
NFC Driver Log (Bluetooth, NFC and USB)04,241
USB Manager State (Bluetooth, NFC and USB)360
USB Log (Bluetooth, NFC and USB)1,6932,285
Telephony State (Telephony)11720
SIM Subscriptions (Telephony)73
Carrier Config Values (Telephony)6765
Telephony Service Logs (Telephony)1,157687
Telephony State Machine Records (Telephony)5656
Telecom Phone Accounts (Telephony)60
Radio Log State Lines (Telephony)7,9835,804
Figure 3Rows per artifact on two Android 16 bug reports; twelve of the 37 artifacts are drawn, all are in the table. Zero rows means the report prints no such section or list. The scale is logarithmic. Source: pull request description, table of rows per artifact for the two newest Samsung reports (counts only, not synthetic values).

The value

For an examiner this turns several questions into table lookups. Which Wi-Fi networks does the phone know, whether it ever connected to each, how many times it associated, and with which key management. Which connection events the Wi-Fi service logged, with duration and result. Which apps have data restrictions in the network policy, and which usage buckets the statistics hold where a build prints them. Which Bluetooth devices are bonded, and when the adapter was enabled or a connection started. Whether NFC was on and which card emulation services exist. When a USB port connected or disconnected, with the vendor and product identifiers where the line prints them. Which SIM subscriptions and carrier settings were active.

The limits are part of the answer. A saved network shows that the phone knows it, not that it was joined at a given time. The private DNS log is older than the dump by an unstated amount. The open sockets table is a snapshot of the moment the command ran. The NFC and USB logs are printed by some Samsung builds only. Nothing here gives network destinations, message bodies or call content; the telephony tables hold state and the radio layer's own log lines. Bluetooth bond events were not on any research report that prints the list, so that reader is tested only on a synthetic fixture.

The tool shows subscriber identifiers such as ICCID, IMSI and phone numbers, and the adapter address, exactly as printed, because it runs on the examiner's own evidence. This page shows none; every value in the figures is invented.

What the evidence for this pull request coversThree columns: what was checked on research bug reports, what exists only as a synthetic fixture, and what was not examined or not read.What the evidence coversChecked on research reports-Five Wi-Fi and usage tables equal asecond parser on five reports (one fielddiffers on 5 saved networks of onereport, named in the notes)-Radio counts equal raw-text counts onevery report that has the section-Network Usage Buckets, Radio Log StateLines and NFC Driver Log equal raw-textcounts on two more reportsSynthetic fixtures only-Time zones other than UTC+0-A second Android user-Bluetooth bond event lines-HCE-F service entries-A dump cut by the time limit-A call in progressNot examined or not read-Android 11 to 14 and other vendors-Radio field values: checked by eye onsamples, not against a second parser-Present but not read: two NFC vendordumps, the GATT scanner map, telephonyregistry registrations, lsusb
Show this figure as a table
Evidence coverage
ColumnItems
Checked on research reportsFive Wi-Fi and usage tables equal a second parser on five reports (one field differs on 5 saved networks of one report, named in the notes); Radio counts equal raw-text counts on every report that has the section; Network Usage Buckets, Radio Log State Lines and NFC Driver Log equal raw-text counts on two more reports
Synthetic fixtures onlyTime zones other than UTC+0; A second Android user; Bluetooth bond event lines; HCE-F service entries; A dump cut by the time limit; A call in progress
Not examined or not readAndroid 11 to 14 and other vendors; Radio field values: checked by eye on samples, not against a second parser; Present but not read: two NFC vendor dumps, the GATT scanner map, telephony registry registrations, lsusb
Figure 4Evidence ladder. All seven research reports record UTC+0, so every other zone is synthetic. Source: the 'Proven on real reports', 'Constructed only' and 'Not examined' paragraphs of the pull request description (counts only, not synthetic values).

Where this sits in the Lab's research

No Lab report is about the network and radio sections as such, so the method on this page comes from the pull request and its notes. Two Lab reports apply. LAB-TR-0001, Making Silent Failures Visible: A Single-Pass Section Reader for Android Bug Reports (Zenodo, version 1.1, 10.5281/zenodo.23719508), describes the reader and the section index that make an absent section visible. LAB-TR-0041, Attributing Interior Gaps in Phone Logs to Restarts, Log Rotation and Clock Steps, is in preparation and not yet on Zenodo; it treats the event and radio logs of bug reports as event-driven streams, in which a quiet period is normal and is not a hole.

The categories follow Android bug reports, category by category, which also records that per-app network counters were present only in the two Samsung reports of its five-report sample.

Sources

Every number and claim on this page, with where it came from. Figure values are either synthetic examples (marked) or counts from the pull request.

Sources of the numbers and claims
Number or claimWhere it came from
37 artifacts in 4 groups (6, 14, 10, 7)Pull request description, 'What this changes'; artifact list in bugreportNetwork.py (20) and bugreportRadios.py (17)
Merged on 27 October 2026Pull request state and merge time (mergedAt); the review and comment lists are empty
245 baselines in 2 case folders, all pass; 295 cumulative unit tests; pylint 10.00/10Pull request description, 'Test record' table
Fixture case names (a10, a16, cut, empty, not_a_report, odd_bytes, two_reports, zip_on_device)File names under admin/test/cases/data/ in the pull request file list
Five Wi-Fi and usage tables equal a second parser on five reports; one field differs on 5 saved-network entries of one reportPull request description, 'Proven on real reports'
Network Usage Buckets 26,131 and 60,684; Radio Log State Lines 7,983 and 5,804; NFC Driver Log 0 and 4,241; other counts in Figure 3Pull request description, table of rows per artifact (two newest Samsung reports)
Constructed only, not examined and present-but-not-read lists (Figure 4)Pull request description, 'Constructed only' and 'Not examined'
Seven reports in four vendor families, Android 10, 15 and 16; whole tool exit 0 in 20 to 55 s per reportPull request description; device classes only
The ConfigurationMap block repeats the saved networks and is not readNotes of Wi-Fi Saved Networks in bugreportNetwork.py
Start times carry month, day and clock time without a year; year rule and zoneNotes of Wi-Fi Connection Events and Bluetooth Events; year rule in the notes of Location Events (bugreportSensorsMedia.py)
Private DNS Log has no date: no UTC value; entries are older than the dump by an unstated amountNotes of Private DNS Log in bugreportNetwork.py
A report that prints a netstats table in both sections lists its buckets twice; Source Section says whichNotes of Network Usage Buckets in bugreportNetwork.py
NFC log: about 1 line in 20 prints a wall time; USB and NFC logs come from some Samsung buildsNotes of NFC Driver Log and USB Log in bugreportRadios.py
One report has no nfc section; another has no usb or telecom section; sem_wifi is read to a 20,000-line cap and the cut is loggedPull request description, 'Anything reviewers should know'
Bluetooth addresses are partly masked by the platform in three of five early reports; SIM and adapter identifiers are shown as printedNotes of Bluetooth Devices and SIM Subscriptions; pull request description
Event and radio logs are event-driven streams: quiet periods, not holes (counted, not tested)LAB-TR-0041, Table 3
Per-app counters were in only the two Samsung reports of the five-report sample; no message bodies or call contentLab article LAB-0002, categories 'Network and connectivity' and 'Telephony and messaging'
2 million lines; HTML, TSV and LAVA output; section indexLAB-TR-0001, abstract and section 3.3