hermes-hub/tests
Hermes Team 11aa914fbb fix(security): токен сравнивался обычным !=, вопреки контракту
Раздел 3 контракта требует secrets.compare_digest, но в коде стояло
x_hub_token != required_token, а compare_digest не встречался в router/
вообще. Обычное сравнение строк выходит на первом несовпавшем символе и даёт
утечку по времени. Проверка стала уместной сейчас, когда хаб собираются
открыть по сети.

Сравнение идёт в БАЙТАХ, а не в строках: compare_digest со строками
запрещает не-ASCII и падает TypeError — токен с кириллицей давал бы 500
вместо честного отказа. Выяснено исполнением, а не чтением документации.

Проверено на живом приложении при web_api_host=0.0.0.0: без токена 401,
неверный 401, отличающийся одним символом 401, верный 200. Страница отдаётся
без токена (иначе его негде было бы ввести), в /api/settings токен не
попадает, в снапшоте нет access_token/refresh_token/client_secret.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-25 10:21:40 +07:00
..
fixtures fix(installer): ошибка 12 при установке — проверка требовала конфигурацию от 20 августа 2026-08-24 09:35:36 +07:00
conftest.py Fix UI test instability and clarify contract boundaries 2026-08-23 18:27:07 +07:00
test_a9_migration_quotas_models.py feat(router): integrate local LLM provider (llama.cpp/vLLM/Ollama) with zero quotas (A25) 2026-08-24 14:00:25 +07:00
test_account_modal_refresh.py fix(web): окно аккаунта не обновлялось и застревало на заглушке 2026-08-24 20:40:13 +07:00
test_accounts_tariffs_quotas.py feat(A11): интеграция с Hermes, токены Codex, честное обнаружение моделей 2026-08-23 15:27:28 +07:00
test_adapter_error_parsing.py fix(adapters): обработчик ошибок падал сам, скрывая настоящую причину 2026-08-24 14:54:39 +07:00
test_agy_native_login.py feat(antigravity): implement native agy login, profile isolation, and protect global ~/.gemini (A22) 2026-08-23 23:57:57 +07:00
test_agy_oauth_credentials.py fix(oauth): preserve complete credentials and sync oauth_creds.json for Antigravity profiles (A20) 2026-08-23 23:09:58 +07:00
test_antigravity_concurrency.py fix(agy): подстановка уровня усилия — gemini-3.7-flash работает как есть 2026-08-24 01:18:00 +07:00
test_codex_opencode_wizard.py fix(ui): repair startup crash in TeamView and tighten the headless guard 2026-08-20 23:22:19 +07:00
test_credential_isolation.py feat(security): isolate subprocess credentials, implement selection explanation matrix, and resolve installer registry isolation 2026-08-21 10:17:19 +07:00
test_dashboard_data.py fix(dashboard): unify LeaseManager, warm up initial CPU measurement, add live network speed, and clarify YAML comment support 2026-08-21 22:18:59 +07:00
test_data_truthfulness_and_oauth_security.py feat(state): harden snapshots quotas and routing 2026-08-21 00:03:50 +07:00
test_delete_credentials.py fix(accounts): удаление аккаунта рапортовало успех, ничего не удаляя 2026-08-24 19:17:51 +07:00
test_delete_without_provider.py fix(web): удаление аккаунта не работало из интерфейса 2026-08-24 20:19:58 +07:00
test_deployment_doctor.py feat(installer): implement P0-4bis reinstall detection, UI screen, and user data preservation 2026-08-22 21:25:39 +07:00
test_grok_device_flow.py fix(grok): опрос device-flow не различал отказ, просрочку и ожидание 2026-08-24 15:11:54 +07:00
test_grok_quota.py feat(grok): подписка вместо кредитов — квота и модели заработали 2026-08-24 20:29:08 +07:00
test_health_auth_recovery.py feat(router): profile auth self-healing, honest model validation, and manual model refresh (A23) 2026-08-24 02:02:28 +07:00
test_import_invariants.py style: normalize merged state tests 2026-08-21 00:11:16 +07:00
test_import_source_contract.py feat(state): harden snapshots quotas and routing 2026-08-21 00:03:50 +07:00
test_installer.py feat(security): isolate subprocess credentials, implement selection explanation matrix, and resolve installer registry isolation 2026-08-21 10:17:19 +07:00
test_installer_windows_and_linux.py feat(installer): самодостаточный exe для Windows 2026-08-24 09:21:08 +07:00
test_linux_port_paths.py feat(A15): веб-API, общий ActionExecutor и порт путей на Linux 2026-08-23 19:45:13 +07:00
test_local_llm_empty_answer.py Merge A24 (маршрутизация как центр управления) и A25 (локальная модель) 2026-08-24 14:33:16 +07:00
test_local_llm_provider_a25.py Merge A24 (маршрутизация как центр управления) и A25 (локальная модель) 2026-08-24 14:33:16 +07:00
test_model_choice_and_discovery.py feat(router): A18 — выбор модели, действие set_model, персистентный кэш и выбор в веб-клиенте 2026-08-23 22:08:08 +07:00
test_model_validation_a23.py feat(router): profile auth self-healing, honest model validation, and manual model refresh (A23) 2026-08-24 02:02:28 +07:00
test_multi_provider_router.py feat(router): integrate local LLM provider (llama.cpp/vLLM/Ollama) with zero quotas (A25) 2026-08-24 14:00:25 +07:00
test_oauth_lifecycle.py feat(web): вход Antigravity и Claude из браузера на любой машине 2026-08-25 09:52:53 +07:00
test_opencode_credentials.py fix(opencode): адаптер не читал сохранённый ключ — аккаунт не работал никогда 2026-08-23 21:45:32 +07:00
test_p0_release_gate.py fix: update canonical installer with dependency resolution and close release blockers 2026-08-20 18:17:08 +07:00
test_plan_a_stabilization_and_smart_routing.py feat(antigravity): implement native agy login, profile isolation, and protect global ~/.gemini (A22) 2026-08-23 23:57:57 +07:00
test_plugin_passthrough.py fix(plugin): отказ роутера больше не подменяет ответ модели в Hermes 2026-08-23 12:25:02 +07:00
test_readiness_counting.py fix(readiness): роль на резерве считается работающей 2026-08-24 10:19:33 +07:00
test_roadmap_features.py feat(state): harden snapshots quotas and routing 2026-08-21 00:03:50 +07:00
test_router_error_path.py fix(router): обработчик ошибок падал сам, уровень усилия не подставлялся 2026-08-24 08:51:01 +07:00
test_router_telemetry.py feat(telemetry): implement empirical call telemetry, metrics aggregates, user pricing, and update state contract 2026-08-21 16:57:57 +07:00
test_routing_control_center_a24.py feat(web): routing control center with drag-and-drop, inline models, and 7-view navigation (A24) 2026-08-24 10:53:57 +07:00
test_state_layer_and_event_driven_quota.py feat(release): close contract audit v1.2, release feed verification, diagnostic CLI, and failover event logging 2026-08-21 10:05:30 +07:00
test_state_layer_contract.py feat(state): harden snapshots quotas and routing 2026-08-21 00:03:50 +07:00
test_ui_claude_grok_connection.py fix(A15): восстановить десктоп и починить веб-API 2026-08-23 19:54:29 +07:00
test_ui_contract_v11.py Fix UI test instability and clarify contract boundaries 2026-08-23 18:27:07 +07:00
test_ui_design_system.py refactor(ui): centralize design tokens and complete the component library 2026-08-20 23:35:10 +07:00
test_ui_mockup_redesign.py Fix UI test instability and clarify contract boundaries 2026-08-23 18:27:07 +07:00
test_ui_model_discovery_reachability.py feat(ui): A12 — компактные карточки аккаунтов, доступность причин Н/Д, упорядочивание провайдеров и тест службы моделей 2026-08-23 13:30:20 +07:00
test_ui_phase2_6.py Fix UI test instability and clarify contract boundaries 2026-08-23 18:27:07 +07:00
test_ui_refinement.py fix(router): address review findings B1-B4 and S1-S9 with full regression suite 2026-08-20 17:04:49 +07:00
test_ui_routing_graph.py A17: Implement real network verification for profile test and update status snapshot 2026-08-23 22:13:24 +07:00
test_ui_screenshot_harness.py feat(ui): implement approved three-theme mockup redesign 2026-08-21 19:06:46 +07:00
test_ui_wizard_finish.py Fix UI test instability and clarify contract boundaries 2026-08-23 18:27:07 +07:00
test_unified_health.py feat(router): integrate local LLM provider (llama.cpp/vLLM/Ollama) with zero quotas (A25) 2026-08-24 14:00:25 +07:00
test_updater.py fix: update canonical installer with dependency resolution and close release blockers 2026-08-20 18:17:08 +07:00
test_view_startup_contract.py test(ui): keep the startup guard assertion after views stopped reading the store 2026-08-21 08:47:59 +07:00
test_web_api_security.py feat(A15): веб-API, общий ActionExecutor и порт путей на Linux 2026-08-23 19:45:13 +07:00
test_web_client_contract.py fix(security): токен сравнивался обычным !=, вопреки контракту 2026-08-25 10:21:40 +07:00
test_web_parity_a21.py feat(web): routing control center with drag-and-drop, inline models, and 7-view navigation (A24) 2026-08-24 10:53:57 +07:00
test_web_snapshot_freshness.py fix(web): квоты не подтягивались — прогрев кэша и пересбор снапшота 2026-08-23 21:32:26 +07:00