diff --git a/frontend/help-ru.html b/frontend/help-ru.html index 2ce7251..08fbc4a 100644 --- a/frontend/help-ru.html +++ b/frontend/help-ru.html @@ -35,10 +35,18 @@
localStorage и сохраняется между перезагрузками.Сборщик Immediate Action предлагает action indicator (81/82), структурированный сборщик проактивных команд (REFRESH, DISPLAY TEXT, PLAY TONE с авто-генерацией COMPREHENSION-TLV), или ручной hex-ввод.
Восстановление при ошибках по TS 102 226 §5.2.1.3 — одна из трёх форм:
+Восстановление при ошибках по TS 102 226 §5.2.1.3 — одна из четырёх форм:
82 00Результаты по каждой команде с деталями ошибок и контекстом цепочки:
-Входящие ответы Proof of Receipt декодируются сервером — формат expanded Remote Application response data (TS 102 226 §5.2.2) или компактный формат. Представление Secured Packet показывает результат после Send to Card (см. §3.1): статус PoR (TAR, счётчик, сырой PoR), а статусное слово и данные ответа последней команды подставляются на вкладку Response parser.
CLA = 80 (GlobalPlatform Card Specification v2.3.1). Команды удалённого управления приложениями. Строятся тем же сборщиком цепочки, что и SIM/USIM.
10 (счётчик больше) или 11 (счётчик +1) согласно TS 102 225 §5.1.2/§5.1.3.100 по умолчанию или FF)Кнопка «Verify vs pySim» сверяет собранный пакет с эталонной реализацией OtaDialectSms.encode_cmd. Кнопка «Send to Card» доставляет пакет через ENVELOPE SMS-PP-DOWNLOAD (при подключении к серверу).
Кнопка «Verify vs pySim» сверяет собранный пакет с эталонной реализацией OtaDialectSms.encode_cmd. Кнопка «Send to Card» доставляет пакет через ENVELOPE SMS-PP-DOWNLOAD (при подключении к серверу). Полученный Proof of Receipt декодируется и показывается строкой статуса PoR (статус, TAR, счётчик, сырой PoR); статусное слово и данные ответа последней команды подставляются на вкладку Response parser, а успешный PoR увеличивает счётчик повторов и очищает пакет.
Хранит предустановки карт локально в браузере (localStorage), чтобы представление Secured Packet могло автоматически подставлять ключи и параметры.
Export as JSON / Import JSON from clipboard для обмена предустановками. Выбранная предустановка автоматически заполняет форму Secured Packet.
+Обмен предустановками: Export as JSON и Export to file для выгрузки, Import from file, Paste & import или Import JSON from clipboard для загрузки. Выбранная предустановка автоматически заполняет форму Secured Packet.
Выполняет операции удалённого управления приложениями (Remote Application Management) как защищённые пакеты SCP80 через SMS-PP-DOWNLOAD ENVELOPE. Карта должна поддерживать SCP03 (AES или 3DES). Предустановка карты из подвкладки Cards обеспечивает SPI, ключи, TAR и счётчик.
@@ -301,7 +302,7 @@Декодирует raw-ответ команды: выберите отправленную команду, введите SW (например, 9000) и hex данных ответа, затем нажмите Decode.
Декодирует raw-ответ команды: выберите отправленную команду, введите SW (например, 9000) и hex данных ответа, затем нажмите Decode. Поля также автоматически заполняются статусным словом и данными ответа последней команды после успешного «Send to Card» (см. §3.1).
Подключение к локальному pysim-otaman-server для работы с картой. Подвкладки: File manager, Custom files, Profiler, pySim command line, Raw APDU и Proactive UICC.
+Подключение к локальному pysim-otaman-server для работы с картой: введите URL сервера (по умолчанию http://127.0.0.1:8080) и нажмите Connect. Область статуса показывает состояние ридера/карты, а Equip card (пере)инициализирует карту после вставки. Подвкладки: File manager, Custom files, Profiler, pySim command line, Raw APDU и Proactive UICC.
Дерево файловой системы отображается слева; выбор файла открывает панель деталей справа.
Добавление файлов, не покрытых моделью pySim. Сохраняется в localStorage; экспорт/импорт JSON.
Добавление файлов, не покрытых моделью pySim: введите полный путь (например, 3F00/7F20/6F46) и псевдоним (например, EF.SPN), затем нажмите Add; добавленные файлы появляются в дереве File manager. Список сохраняется в localStorage; обмен — Export as JSON / Export to file и Import from file / Paste & import / Import JSON from clipboard.
Выполнение любых команд pySim-shell с подсказками (300 мс) и автодополнением.
@@ -372,14 +374,14 @@Правила выполняются последовательно. Правило файловой системы задаётся:
+Правила выполняются последовательно. Редактор показывает символьное имя файла pySim (если известно) рядом с путём правила; Add rule добавляет правило, Save сохраняет изменения. Правило файловой системы задаётся:
MF (например, MF/7F10/6F3A) или с AID ADF (например, A0000000871002/6F07).'62' — выявляет изменения FID/AID, жизненного цикла, атрибутов безопасности и проприетарных параметров).? — шаблон на один полубайт (маска без ? — совпадение префикса, например 0891 для MCC/MNC из IMSI). Для record-файлов хранится список по записям.? — шаблон на один полубайт (маска без ? — совпадение префикса, например 0891 для MCC/MNC из IMSI). Для record-файлов хранится список по записям.Check выполняет каждое правило на подключённой карте и показывает строку прогресса и отчёт прохождения. Рядом с путём файла указывается, что именно проверялось (например, тип файла и размер, содержимое или точный FCI); если часть проверок прошла, а часть нет — каждый аспект помечается (тип файла ✓, размер ✗, содержимое ✓), а расхождения расписываются ниже. Для record-файлов при расхождении содержимого добавляется пометка совпадающие записи: 1-5, 7-10 со списком записей, которые совпали.
+Check выполняет каждое правило на подключённой карте и показывает строку прогресса и отчёт прохождения. Рядом с путём файла указывается, что именно проверялось (например, тип файла и размер, содержимое или точный FCI); если часть проверок прошла, а часть нет — каждый аспект помечается (тип файла ✓, размер ✗, содержимое ✓), а расхождения расписываются ниже. Несовпавшие сырые данные (FCI, содержимое, данные записей) показываются как поля только для чтения с моноширинным шрифтом — ожидаемое над фактическим, в одной и той же колонке — для удобного сравнения. Для record-файлов при расхождении содержимого добавляется пометка совпадающие записи: 1-5, 7-10 со списком записей, которые совпали.
Диалог сканирования запрашивает имя профиля и предлагает селектор «FCP/FCI check» (те же три режима, по умолчанию Filetype + size), применяемый ко всем создаваемым правилам, а также список «Ignore contents of» (все отмечены по умолчанию) часто перезаписываемых файлов, содержимое которых пропускается: EF.LOCI, EF.PSLOCI, EF.EPSLOCI, EF.5GS3GPPLOCI, EF.Keys, EF.KeysPS, EF.SMS, EF.Kc, EF.KcGPRS, EF.LOCIGPRS, EF.CBMID, EF.SMSS. Ещё две отмеченные по умолчанию опции «Match first 4 bytes for» EF.IMSI и EF.ICCID захватывают содержимое этих файлов как маску только первых 4 байт (снимите для точного сравнения). Строка прогресса показывает N / всего файлов с текущим путём файла во время сканирования; при сканировании опции скрываются, а кнопки блокируются. Правила создаются только для файлов, которые реально существуют на карте (возвращён FCP-шаблон); отсутствующие файлы пропускаются. Пользовательские файлы из подвкладки Custom files включаются с той же проверкой существования.
start.sh)pcscd, передаёт -p 0/dev/ttyUSB0, передаёт -d /dev/ttyUSB0-p 0 (PC/SC встроен в Windows)start.sh передаёт -p 0, если запущен демон pcscdstart.bat всегда использует -p 0 (PC/SC встроен в Windows)-d /dev/ttyUSB0 (Linux)Если ридер не обнаружен, сервер запускается без аргументов и показывает «Reader: none». Карту можно инициализировать позже кнопкой Equip на вкладке Card reader.
+Если карта отсутствует, вкладка Card reader показывает «No card detected». Вставьте карту и нажмите Equip card для инициализации.
# Создать и активировать venv diff --git a/frontend/help.html b/frontend/help.html index 886dd3b..440e822 100644 --- a/frontend/help.html +++ b/frontend/help.html @@ -35,10 +35,18 @@
localStorage and persist across reloads.The Immediate Action builder offers an action indicator (81/82), a structured proactive command builder (REFRESH, DISPLAY TEXT, PLAY TONE with auto-generated COMPREHENSION-TLV objects), or a freeform hex input.
Error recovery per TS 102 226 §5.2.1.3 — one of three forms:
+Error recovery per TS 102 226 §5.2.1.3 — one of four forms:
82 00Per-command results with error details and chaining context:
-Incoming Proof-of-Receipt responses are decoded by the server — expanded Remote Application response data (TS 102 226 §5.2.2) or the compact format. The Secured Packet view shows the outcome after Send to Card (see §3.1): the PoR status (TAR, counter, raw PoR), with the last command’s status word and response data filled into the Response parser tab.
CLA = 80 (GlobalPlatform Card Specification v2.3.1). Remote Application Management commands for card content management. Built with the same chain builder as SIM/USIM: add rows, fill fields, and the chain preview updates automatically.
10 (counter higher) or 11 (counter +1) per TS 102 225 §5.1.2/§5.1.3.100 default, or FF)A “Verify vs pySim” button cross-checks the assembled packet against pySim’s reference OtaDialectSms.encode_cmd. A “Send to Card” button delivers it via SMS-PP-DOWNLOAD ENVELOPE (when connected to the server).
A “Verify vs pySim” button cross-checks the assembled packet against pySim’s reference OtaDialectSms.encode_cmd. A “Send to Card” button delivers it via SMS-PP-DOWNLOAD ENVELOPE (when connected to the server). The returned Proof of Receipt is decoded and shown as a PoR status line (status, TAR, counter, raw PoR); the last command’s status word and response data are filled into the Response parser tab, and a successful PoR advances the replay counter and clears the packet.
Stores card presets locally in the browser (localStorage) so the Secured Packet view can auto-fill keys and parameters.
Export as JSON / Import JSON from clipboard share presets. The selected card preset auto-fills the Secured Packet form.
+Presets can be shared with Export as JSON and Export to file, and restored with Import from file, Paste & import, or Import JSON from clipboard. The selected card preset auto-fills the Secured Packet form.
Delivers Remote Application Management operations as SCP80 secured packets via SMS-PP-DOWNLOAD ENVELOPE. The card must support SCP03 (AES or 3DES). A saved card preset from the Cards sub-tab provides the SPI, keys, TAR, and counter.
@@ -301,7 +302,7 @@Decodes a raw command response: pick the command that was sent, enter the SW (e.g. 9000) and the response data hex, then press Decode.
Decodes a raw command response: pick the command that was sent, enter the SW (e.g. 9000) and the response data hex, then press Decode. The fields are also auto-filled with the last command’s status word and response data after a successful “Send to Card” (see §3.1).
Connects to a local pysim-otaman-server for live card operations. Sub-tabs: File manager, Custom files, Profiler, pySim command line, Raw APDU, and Proactive UICC.
+Connects to a local pysim-otaman-server for live card operations: enter the server URL (default http://127.0.0.1:8080) and press Connect. The status area shows the reader/card state, and Equip card (re)initializes the card after insertion. Sub-tabs: File manager, Custom files, Profiler, pySim command line, Raw APDU, and Proactive UICC.
The file system tree is displayed on the left; selecting a file opens its detail pane on the right.
Add files that pySim’s model does not cover. Persists in localStorage; JSON export/import.
Add files that pySim’s model does not cover: enter the full path (e.g. 3F00/7F20/6F46) and an alias (e.g. EF.SPN), then press Add; added files appear in the File manager tree. The list persists in localStorage and can be shared with Export as JSON / Export to file and restored with Import from file / Paste & import / Import JSON from clipboard.
Execute any pySim-shell command with usage hints (300 ms) and autocomplete.
@@ -372,14 +374,14 @@Rules run sequentially. A filesystem rule is defined by:
+Rules run sequentially. The editor shows the symbolic pySim name (when known) next to each rule’s path; use Add rule to append one and Save to keep the changes. A filesystem rule is defined by:
MF (e.g. MF/7F10/6F3A) or an ADF AID (e.g. A0000000871002/6F07).'62' — catching FID/AID, life-cycle status, security-attribute and proprietary-parameter changes).? is a per-nibble wildcard (a mask with no ? is a prefix match, e.g. 0891 for the IMSI MCC/MNC). Record files store a per-record list.? is a per-nibble wildcard (a mask with no ? is a prefix match, e.g. 0891 for the IMSI MCC/MNC). Record files store a per-record list.Check runs every rule against the equipped card and shows a live progress line plus a pass/fail report. Each row states exactly what was verified next to the file path (e.g. filetype and size, contents or exact FCI); when some checks pass and others fail, each aspect is marked (filetype ✓, size ✗, contents ✓) with the mismatches detailed below. For record files with a contents mismatch, a matching records: 1-5, 7-10 note lists the records that did match.
+Check runs every rule against the equipped card and shows a live progress line plus a pass/fail report. Each row states exactly what was verified next to the file path (e.g. filetype and size, contents or exact FCI); when some checks pass and others fail, each aspect is marked (filetype ✓, size ✗, contents ✓) with the mismatches detailed below. Mismatched raw data (FCI, contents, record data) is shown as read-only monospace fields — expected above actual, aligned in the same column — for easy comparison. For record files with a contents mismatch, a matching records: 1-5, 7-10 note lists the records that did match.
The scan dialog asks for a profile name and offers a “FCP/FCI check” selector (the same three modes above, default Filetype + size) applied to every generated rule, plus an “Ignore contents of” checklist (all checked by default) of frequently-overwritten files whose contents are skipped: EF.LOCI, EF.PSLOCI, EF.EPSLOCI, EF.5GS3GPPLOCI, EF.Keys, EF.KeysPS, EF.SMS, EF.Kc, EF.KcGPRS, EF.LOCIGPRS, EF.CBMID, EF.SMSS. Two further checked-by-default options “Match first 4 bytes for” EF.IMSI and EF.ICCID capture those files’ contents as a mask of only the first 4 bytes (uncheck for exact matching). A progress line shows N / total files with the current file path while scanning; during the scan the options are hidden and the buttons are locked. Rules are created only for files that actually exist on the card (a FCP template is returned); missing files are skipped. Custom files from the Custom files sub-tab are included under the same existence check.
start.sh)pcscd daemon is running, passes -p 0/dev/ttyUSB0 exists, passes -d /dev/ttyUSB0-p 0 (PC/SC is built into Windows)start.sh passes -p 0 when the pcscd daemon is runningstart.bat always uses -p 0 (PC/SC is built into Windows)-d /dev/ttyUSB0 (Linux)If no reader is detected, the server starts without reader arguments and shows “Reader: none”. The card can be initialized later via the Equip button in the Card reader tab.
+If no card is present, the Card reader tab shows “No card detected”. Insert the card and click Equip card to initialize it.
# Create and activate a venv
diff --git a/frontend/index.html b/frontend/index.html
index c8d43e4..18946f8 100644
--- a/frontend/index.html
+++ b/frontend/index.html
@@ -1002,7 +1002,7 @@ function cApduSwitchSubtab(name) {
const el = document.getElementById('c-apdu-sub-' + s);
if (el) el.classList.toggle('hidden', s !== name);
});
- setHelpAnchor({sim:'sim-rfm', usim:'usim-rfm', ber:'ber-tlv', ram:'ram-gp', parse:'c-apdu', httpota:'http-ota'}[name] || 'c-apdu');
+ setHelpAnchor({sim:'sim-rfm', usim:'usim-rfm', ber:'ber-tlv', ram:'ram-gp', parse:'c-apdu-parser', httpota:'http-ota'}[name] || 'c-apdu');
}
// ===== HTTP OTA constructor =====
@@ -5520,7 +5520,7 @@ function pysimSwitchSubtab(name) {
if (name === 'custom') pysimCustomRender();
if (name === 'proactive') { stkCheckMenu(); pysimEventsRender(); pysimProactiveLogRender(); pysimPliRender(); pysimPollStatusInit(); }
if (name === 'profiler') profilerSetView('list');
- pysimHelpAnchor = {cmd:'pysim-cmdline', apdu:'raw-apdu', files:'file-manager', custom:'custom-files', proactive:'proactive-uicc', profiler:'card-reader'}[name] || 'card-reader';
+ pysimHelpAnchor = {cmd:'pysim-cmdline', apdu:'raw-apdu', files:'file-manager', custom:'custom-files', proactive:'proactive-uicc', profiler:'profiler'}[name] || 'card-reader';
setHelpAnchor(pysimHelpAnchor);
}
diff --git a/frontend/sw.js b/frontend/sw.js
index 05d804f..5339652 100644
--- a/frontend/sw.js
+++ b/frontend/sw.js
@@ -1,4 +1,4 @@
-const CACHE = 'otaman-v60';
+const CACHE = 'otaman-v61';
const URLS = [
'index.html',
'help.html',