Repository navigation
Replace JSON MAC vendor database with compact binary lookup - #17
Merged
Merged
Conversation
juriyivanov
had a problem deploying
to
github-pages
September 17, 2026 22:36 — with
GitHub Pages
Error
juriyivanov
had a problem deploying
to
github-pages
September 17, 2026 22:46 — with
GitHub Pages
Error
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Что изменено
oui-db.json(5,636,609 байт) на компактныйoui-db.bin.gz(503,496 байт), то есть примерно на 91.1% меньше исходной JSON-базы;/36 -> /28 -> /24, отсортированные бинарные prefix-records и бинарный поиск прямо поArrayBuffer;/24= 3+2 байта,/28= 4+2,/36= 5+2, где последние 2 байта этоuint16 vendor_id;DecompressionStream('gzip'); перед распаковкой проверяется gzip magic, поэтому код нормально переживает и хостинг/CDN, который уже распаковал тело сам;app-core.js, аapp.jsстал компактным loader/compatibility layer;app-core.jsпослеDOMContentLoaded, обнаруженная на GitHub Pages, и добавлен regression-тест;3.16;oui-db.bin.gzи обновлён доipcalc-pwa-v25;tools/build-oui-db.pyпо умолчанию собираетoui-db.bin.gzс gzip level 9 и умеет также писать raw binary при другом расширении;Формат v2
После распаковки
IPCOUI02, header 96 bytes:/24: 3-byte big-endian prefix + LEuint16 vendor_id/28: 4-byte big-endian prefix + LEuint16 vendor_id/36: 5-byte big-endian prefix + LEuint16 vendor_iduint32), затемuint16 common_prefix_len + uint16 suffix_len + suffixПоведение MAC Vendor / Formats и longest-prefix matching для пользователя не меняется.