WR 株式会社WR 松戸のホームページ制作・社内システム・IT相談

株式会社WR

千葉県松戸市
松戸・柏・市川・流山・船橋 対応

ホーム›脆弱性情報›Django›CVE-2026-61599

重要 CVSS 8.8 Django CVE-2026-61599 公表 2026年9月16日

djustに任意モジュール読み込みの脆弱性

Django — CVE-2026-61599

自分のサイトが該当するか無料診断 → 原文を見る(NVD(米国 脆弱性データベース))↗

どんな問題か

djustで、利用者が指定したモジュールをそのまま読み込んでしまう問題があります。認証より先に読み込みが起きるため、攻撃者が任意のモジュールの処理を動かせるおそれがあります。

放置するとどうなるか

外部からサーバー上のコードを動かされ、情報流出や改ざんにつながるおそれがあります。WebSocketやSSE経由で被害が広がる可能性があります。

今すぐやること

djustを1.0.7へ更新してください。認証前に読み込まれる設定がないか確認し、公開中の機能は一時的に制限しましょう。

自分のサイトが該当するかの確認手順

  1. お使いのサーバー・プログラムに Django が使われているか、制作会社・保守会社・サーバー会社に確認します(管理画面やサーバーのバージョン表示でも分かります)。
  2. バージョンが「Prior to version 1.0.7」に当てはまるか確認します。
  3. 当てはまる場合は、修正版へのアップデートを依頼します。レンタルサーバーの場合はサーバー会社側で対応済みのこともあるので、お知らせを確認してください。
原文(英語)を表示
djust provides Phoenix LiveView-style reactive server-side rendering for Django with Rust-powered performance. Prior to version 1.0.7, the djust live transport resolves the LiveView to mount from a client-supplied dotted path by calling `__import__(module_path, ...)`. The module is imported — running its top-level code (import side effects) — before the framework checks that the resolved object is a `LiveView` subclass and before any per-view authentication. The `LIVEVIEW_ALLOWED_MODULES` allowlist that should contain this is fail-open (`if allowed_modules:` — skipped when the setting is unset, the framework default) and uses loose `startswith` matching. An unauthenticated WebSocket client (the WS handshake does not require auth; per-view auth runs only after import + instantiate) can therefore send a `mount` / `live_redirect_mount` / `url_change` frame (or an SSE mount) with `view = "<any.importable.module>.AnyName"` and cause the server to import — and execute the top-level code of — any importable Python module by name. Version 1.0.7 fixes the issue with a fail-closed resolution gate (`djust._view_resolution.is_view_import_allowed`): a client view path resolves only if (a) its module is already loaded (`sys.modules` — so resolving runs no new code; URL-routed views loaded by URLconf at startup keep working with zero config) or (b) it matches `LIVEVIEW_ALLOWED_MODULES` on a module-segment boundary (explicit opt-in for lazily-imported views). The gate runs before `__import__` at all three sinks (+ defense-in-depth inside `_instantiate_view`). As a workaround, set `LIVEVIEW_ALLOWED_MODULES` to the narrow list of modules that contain your mountable LiveView classes. (Note: pre-patch the allowlist is `startswith`-matched and the import still precedes the subclass check, so this is mitigation, not a complete fix.)

※ 解説は NVD(米国 脆弱性データベース) の公表内容をもとにAIが生成しています。対象バージョン・修正版などの正確な情報は、必ず原文をご確認ください。

無料で相談する →