{"containers":{"cna":{"affected":[{"collectionURL":"https://repo.hex.pm","cpes":["cpe:2.3:a:phoenixframework:phoenix_live_view:*:*:*:*:*:*:*:*"],"defaultStatus":"unaffected","modules":["'Elixir.Phoenix.LiveView.Channel'"],"packageName":"phoenix_live_view","packageURL":"pkg:hex/phoenix_live_view","product":"phoenix_live_view","programFiles":["lib/phoenix_live_view/channel.ex"],"programRoutines":[{"name":"'Elixir.Phoenix.LiveView.Channel':authorize_session/3"}],"repo":"https://github.com/phoenixframework/phoenix_live_view","vendor":"phoenixframework","versions":[{"lessThan":"1.0.20","status":"affected","version":"0.16.0","versionType":"semver"},{"lessThan":"1.1.34","status":"affected","version":"1.1.0-rc.0","versionType":"semver"},{"lessThan":"1.2.14","status":"affected","version":"1.2.0-rc.0","versionType":"semver"}]},{"collectionURL":"https://github.com","cpes":["cpe:2.3:a:phoenixframework:phoenix_live_view:*:*:*:*:*:*:*:*"],"defaultStatus":"unaffected","modules":["'Elixir.Phoenix.LiveView.Channel'"],"packageName":"phoenixframework/phoenix_live_view","packageURL":"pkg:github/phoenixframework/phoenix_live_view","product":"phoenix_live_view","programFiles":["lib/phoenix_live_view/channel.ex"],"programRoutines":[{"name":"'Elixir.Phoenix.LiveView.Channel':authorize_session/3"}],"repo":"https://github.com/phoenixframework/phoenix_live_view","vendor":"phoenixframework","versions":[{"changes":[{"at":"049b2b10bb051467639c8cf6f3f7ee13df401a74","status":"unaffected"},{"at":"5dc8459da3d5f7f1ba11d2fe351ea97e7a46c99f","status":"unaffected"},{"at":"71b114d75e1ed615bbe8db7474a215536163eabb","status":"unaffected"},{"at":"ec47eaac9e440ca7e8664ef64c8377cd2579c40c","status":"unaffected"}],"lessThan":"*","status":"affected","version":"3d1eb6752399060eebdaa7112f959ee81e7d630d","versionType":"git"}]}],"configurations":[{"lang":"en","supportingMedia":[{"base64":false,"type":"text/html","value":"<p>The application enforces authentication or authorization in <code>on_mount</code> hooks of a <code>live_session</code>, and the LiveView does not do the same check itself. The LiveView must also mount without a route: it does not define <code>handle_params/3</code>, its <code>mount/3</code> accepts <code>:not_mounted_at_router</code> as its params, and it does not read assigns that the skipped hooks set.</p>"},{"base64":false,"type":"text/markdown","value":"The application enforces authentication or authorization in `on_mount` hooks of a `live_session`, and the LiveView does not do the same check itself. The LiveView must also mount without a route: it does not define `handle_params/3`, its `mount/3` accepts `:not_mounted_at_router` as its params, and it does not read assigns that the skipped hooks set."}],"value":"The application enforces authentication or authorization in on_mount hooks of a live_session, and the LiveView does not do the same check itself. The LiveView must also mount without a route: it does not define handle_params/3, its mount/3 accepts :not_mounted_at_router as its params, and it does not read assigns that the skipped hooks set."}],"cpeApplicability":[{"nodes":[{"cpeMatch":[{"criteria":"cpe:2.3:a:phoenixframework:phoenix_live_view:*:*:*:*:*:*:*:*","versionEndExcluding":"1.0.20","versionStartIncluding":"0.16.0","vulnerable":true},{"criteria":"cpe:2.3:a:phoenixframework:phoenix_live_view:*:*:*:*:*:*:*:*","versionEndExcluding":"1.1.34","versionStartIncluding":"1.1.0-rc.0","vulnerable":true},{"criteria":"cpe:2.3:a:phoenixframework:phoenix_live_view:*:*:*:*:*:*:*:*","versionEndExcluding":"1.2.14","versionStartIncluding":"1.2.0-rc.0","vulnerable":true}],"negate":false,"operator":"OR"}],"operator":"AND"}],"credits":[{"lang":"en","type":"finder","value":"Alexander Koutmos"},{"lang":"en","type":"reporter","value":"Alexander Koutmos"},{"lang":"en","type":"coordinator","value":"Jonatan Männchen / EEF"},{"lang":"en","type":"remediation developer","value":"Steffen Deusch"},{"lang":"en","type":"remediation reviewer","value":"José Valim"}],"dateAssigned":"2026-11-17T03:32:27.000Z","descriptions":[{"lang":"en","supportingMedia":[{"base64":false,"type":"text/html","value":"<p>Incorrect Authorization vulnerability in phoenixframework phoenix_live_view allows an authenticated user to mount a router-mounted LiveView without the <code>on_mount</code> hooks of its <code>live_session</code> via a <code>phx_join</code> message that carries neither a <code>\"url\"</code> nor a <code>\"redirect\"</code> key.</p>\n<p>The catch-all clause of the private <code>Phoenix.LiveView.Channel.authorize_session/3</code> in <code>lib/phoenix_live_view/channel.ex</code> accepts a join without a URL for any session, including a root LiveView mounted at the router. The channel then mounts the LiveView with no route, and only a route adds the <code>live_session</code> hooks to the mount lifecycle. Checks that those hooks perform on the connected mount do not run, and event checks that they attach through <code>attach_hook/4</code> are never attached. The attacker needs a valid session token for the LiveView, which only the HTTP render issues, after the hooks pass there. <code>on_mount</code> hooks declared in the LiveView module still run.</p>\n<p>This issue affects phoenix_live_view: from 0.16.0 before 1.0.20, from 1.1.0-rc.0 before 1.1.34, and from 1.2.0-rc.0 before 1.2.14.</p>"},{"base64":false,"type":"text/markdown","value":"Incorrect Authorization vulnerability in phoenixframework phoenix_live_view allows an authenticated user to mount a router-mounted LiveView without the `on_mount` hooks of its `live_session` via a `phx_join` message that carries neither a `\"url\"` nor a `\"redirect\"` key.\n\nThe catch-all clause of the private `Phoenix.LiveView.Channel.authorize_session/3` in `lib/phoenix_live_view/channel.ex` accepts a join without a URL for any session, including a root LiveView mounted at the router. The channel then mounts the LiveView with no route, and only a route adds the `live_session` hooks to the mount lifecycle. Checks that those hooks perform on the connected mount do not run, and event checks that they attach through `attach_hook/4` are never attached. The attacker needs a valid session token for the LiveView, which only the HTTP render issues, after the hooks pass there. `on_mount` hooks declared in the LiveView module still run.\n\nThis issue affects phoenix_live_view: from 0.16.0 before 1.0.20, from 1.1.0-rc.0 before 1.1.34, and from 1.2.0-rc.0 before 1.2.14."}],"value":"Incorrect Authorization vulnerability in phoenixframework phoenix_live_view allows an authenticated user to mount a router-mounted LiveView without the on_mount hooks of its live_session via a phx_join message that carries neither a \"url\" nor a \"redirect\" key.\n\nThe catch-all clause of the private Phoenix.LiveView.Channel.authorize_session/3 in lib/phoenix_live_view/channel.ex accepts a join without a URL for any session, including a root LiveView mounted at the router. The channel then mounts the LiveView with no route, and only a route adds the live_session hooks to the mount lifecycle. Checks that those hooks perform on the connected mount do not run, and event checks that they attach through attach_hook/4 are never attached. The attacker needs a valid session token for the LiveView, which only the HTTP render issues, after the hooks pass there. on_mount hooks declared in the LiveView module still run.\n\nThis issue affects phoenix_live_view: from 0.16.0 before 1.0.20, from 1.1.0-rc.0 before 1.1.34, and from 1.2.0-rc.0 before 1.2.14."}],"impacts":[{"capecId":"CAPEC-1","descriptions":[{"lang":"en","supportingMedia":[{"base64":false,"type":"text/html","value":"<p>An authenticated user can send events that the <code>live_session</code> hooks would deny. A user whose access was revoked after the page loaded can still mount the LiveView and send events while the LiveView session token is valid.</p>"},{"base64":false,"type":"text/markdown","value":"An authenticated user can send events that the `live_session` hooks would deny. A user whose access was revoked after the page loaded can still mount the LiveView and send events while the LiveView session token is valid."}],"value":"An authenticated user can send events that the live_session hooks would deny. A user whose access was revoked after the page loaded can still mount the LiveView and send events while the LiveView session token is valid."}]}],"metrics":[{"cvssV4_0":{"Automatable":"NOT_DEFINED","Recovery":"NOT_DEFINED","Safety":"NOT_DEFINED","attackComplexity":"LOW","attackRequirements":"PRESENT","attackVector":"NETWORK","baseScore":6,"baseSeverity":"MEDIUM","privilegesRequired":"LOW","providerUrgency":"NOT_DEFINED","subAvailabilityImpact":"NONE","subConfidentialityImpact":"NONE","subIntegrityImpact":"NONE","userInteraction":"NONE","valueDensity":"NOT_DEFINED","vectorString":"CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:L/VI:H/VA:N/SC:N/SI:N/SA:N","version":"4.0","vulnAvailabilityImpact":"NONE","vulnConfidentialityImpact":"LOW","vulnIntegrityImpact":"HIGH","vulnerabilityResponseEffort":"NOT_DEFINED"},"format":"CVSS","scenarios":[{"lang":"en","value":"GENERAL"}]}],"problemTypes":[{"descriptions":[{"cweId":"CWE-863","description":"CWE-863 Incorrect Authorization","lang":"en","type":"CWE"}]}],"providerMetadata":{"dateUpdated":"2026-11-20T14:44:41.639Z","orgId":"6b3ad84c-e1a6-4bf7-a703-f496b71e49db","shortName":"EEF"},"references":[{"name":"Joining a LiveView without `\"url\"` skips its `live_session` `on_mount` hooks","tags":["vendor-advisory","related"],"url":"https://github.com/phoenixframework/phoenix_live_view/security/advisories/GHSA-v4p7-3pm2-wq6c"},{"name":"EEF CNA record for CVE-2026-126334","tags":["related"],"url":"https://cna.erlef.org/cves/CVE-2026-126334.html"},{"name":"OSV record EEF-CVE-2026-126334","tags":["related"],"url":"https://osv.dev/vulnerability/EEF-CVE-2026-126334"},{"name":"Introducing commit 3d1eb67 in phoenixframework/phoenix_live_view","tags":["related"],"url":"https://github.com/phoenixframework/phoenix_live_view/commit/3d1eb6752399060eebdaa7112f959ee81e7d630d"},{"name":"Fix commit 049b2b1 in phoenixframework/phoenix_live_view","tags":["patch"],"url":"https://github.com/phoenixframework/phoenix_live_view/commit/049b2b10bb051467639c8cf6f3f7ee13df401a74"},{"name":"Fix commit 5dc8459 in phoenixframework/phoenix_live_view","tags":["patch"],"url":"https://github.com/phoenixframework/phoenix_live_view/commit/5dc8459da3d5f7f1ba11d2fe351ea97e7a46c99f"},{"name":"Fix commit 71b114d in phoenixframework/phoenix_live_view","tags":["patch"],"url":"https://github.com/phoenixframework/phoenix_live_view/commit/71b114d75e1ed615bbe8db7474a215536163eabb"},{"name":"Fix commit ec47eaa in phoenixframework/phoenix_live_view","tags":["patch"],"url":"https://github.com/phoenixframework/phoenix_live_view/commit/ec47eaac9e440ca7e8664ef64c8377cd2579c40c"}],"source":{"discovery":"EXTERNAL"},"title":"Joining a LiveView without `\"url\"` skips its `live_session` `on_mount` hooks","workarounds":[{"lang":"en","supportingMedia":[{"base64":false,"type":"text/html","value":"<p>Move the security-relevant <code>on_mount</code> hooks from the <code>live_session</code> to the LiveView module with <code>Phoenix.LiveView.on_mount/1</code>, for example in the <code>live_view</code> definition that <code>use MyAppWeb, :live_view</code> expands. Hooks declared in the module run on every mount.</p>\n<p>Alternatively, make <code>mount/3</code> match its first argument as a map (<code>%{} = params</code>), or define <code>handle_params/3</code> in the LiveView. In both cases a mount without a route raises, and the join fails.</p>"},{"base64":false,"type":"text/markdown","value":"Move the security-relevant `on_mount` hooks from the `live_session` to the LiveView module with `Phoenix.LiveView.on_mount/1`, for example in the `live_view` definition that `use MyAppWeb, :live_view` expands. Hooks declared in the module run on every mount.\n\nAlternatively, make `mount/3` match its first argument as a map (`%{} = params`), or define `handle_params/3` in the LiveView. In both cases a mount without a route raises, and the join fails."}],"value":"Move the security-relevant on_mount hooks from the live_session to the LiveView module with Phoenix.LiveView.on_mount/1, for example in the live_view definition that use MyAppWeb, :live_view expands. Hooks declared in the module run on every mount.\n\nAlternatively, make mount/3 match its first argument as a map (%{} = params), or define handle_params/3 in the LiveView. In both cases a mount without a route raises, and the join fails."}],"x_proofOfConcept":[{"lang":"en","supportingMedia":[{"base64":false,"type":"text/html","value":"<p>The target application has a <code>live_session</code> whose <code>on_mount</code> hook halts the mount for a suspended account and attaches a <code>:handle_event</code> hook with <code>attach_hook/4</code> that denies the <code>delete_post</code> event to users who are not admins. The LiveView at <code>/posts</code> does not define <code>handle_params/3</code>.</p>\n<ol>\n<li>Sign in as a user without the admin role and load <code>/posts</code> over HTTP. Keep the session cookie, the CSRF token from the page, and the <code>id</code>, <code>data-phx-session</code>, and <code>data-phx-static</code> attributes of the element that has <code>data-phx-main</code>.</li>\n<li>Open the LiveView websocket at <code>/live/websocket</code> with the session cookie and the CSRF token.</li>\n<li>Send a <code>phx_join</code> message on the topic <code>lv:&lt;id&gt;</code>. The payload has <code>\"params\"</code> (with <code>\"_csrf_token\"</code> and <code>\"_mounts\": 0</code>), <code>\"session\"</code>, and <code>\"static\"</code>. It has no <code>\"url\"</code> key and no <code>\"redirect\"</code> key.</li>\n<li>The server replies with status <code>ok</code>. The LiveView is mounted without the <code>live_session</code> hooks.</li>\n<li>Send an <code>event</code> message of type <code>click</code> for the event <code>delete_post</code>. The LiveView handles the event, and the post is deleted.</li>\n</ol>\n<p>The same join with the <code>\"url\"</code> key set to the page URL runs the hooks, and the <code>delete_post</code> event is denied. If the account is suspended after step 1, the join with <code>\"url\"</code> is refused, and the join without <code>\"url\"</code> still succeeds.</p>"},{"base64":false,"type":"text/markdown","value":"The target application has a `live_session` whose `on_mount` hook halts the mount for a suspended account and attaches a `:handle_event` hook with `attach_hook/4` that denies the `delete_post` event to users who are not admins. The LiveView at `/posts` does not define `handle_params/3`.\n\n1. Sign in as a user without the admin role and load `/posts` over HTTP. Keep the session cookie, the CSRF token from the page, and the `id`, `data-phx-session`, and `data-phx-static` attributes of the element that has `data-phx-main`.\n2. Open the LiveView websocket at `/live/websocket` with the session cookie and the CSRF token.\n3. Send a `phx_join` message on the topic `lv:<id>`. The payload has `\"params\"` (with `\"_csrf_token\"` and `\"_mounts\": 0`), `\"session\"`, and `\"static\"`. It has no `\"url\"` key and no `\"redirect\"` key.\n4. The server replies with status `ok`. The LiveView is mounted without the `live_session` hooks.\n5. Send an `event` message of type `click` for the event `delete_post`. The LiveView handles the event, and the post is deleted.\n\nThe same join with the `\"url\"` key set to the page URL runs the hooks, and the `delete_post` event is denied. If the account is suspended after step 1, the join with `\"url\"` is refused, and the join without `\"url\"` still succeeds."}],"value":"The target application has a live_session whose on_mount hook halts the mount for a suspended account and attaches a :handle_event hook with attach_hook/4 that denies the delete_post event to users who are not admins. The LiveView at /posts does not define handle_params/3.\n\n* Sign in as a user without the admin role and load /posts over HTTP. Keep the session cookie, the CSRF token from the page, and the id, data-phx-session, and data-phx-static attributes of the element that has data-phx-main.\n* Open the LiveView websocket at /live/websocket with the session cookie and the CSRF token.\n* Send a phx_join message on the topic lv:<id>. The payload has \"params\" (with \"_csrf_token\" and \"_mounts\": 0), \"session\", and \"static\". It has no \"url\" key and no \"redirect\" key.\n* The server replies with status ok. The LiveView is mounted without the live_session hooks.\n* Send an event message of type click for the event delete_post. The LiveView handles the event, and the post is deleted.\n\nThe same join with the \"url\" key set to the page URL runs the hooks, and the delete_post event is denied. If the account is suspended after step 1, the join with \"url\" is refused, and the join without \"url\" still succeeds."}],"x_technicalAnalysis":[{"lang":"en","supportingMedia":[{"base64":false,"type":"text/html","value":"<p><strong>1. Join authorization.</strong> The private <code>Phoenix.LiveView.Channel.authorize_session/3</code> in <code>lib/phoenix_live_view/channel.ex</code> has three clauses. The <code>\"redirect\"</code> clause resolves the route and checks that it stays in the same <code>live_session</code>. The <code>\"url\"</code> clause requires, for a session where <code>Phoenix.LiveView.Session.main?/1</code> is true, that the route for the URL matches the view and the <code>live_session</code> of the session. The third clause matches any other join parameters and returns the session with no route and no URL. Nested LiveViews need this clause because they have no URL. The clause does not call <code>Phoenix.LiveView.Session.main?/1</code>, so it also accepts a root LiveView that was mounted at the router.</p>\n<p><strong>2. Mount with no route.</strong> With no route, <code>mount/3</code> receives <code>:not_mounted_at_router</code> as its params. The private <code>load_lifecycle/2</code> adds the <code>on_mount</code> hooks of the <code>live_session</code> only when it receives a <code>%Phoenix.LiveView.Route{}</code>. Without a route it returns the lifecycle of the LiveView module alone. The <code>live_session</code> layout is skipped in the same way.</p>\n<p><strong>3. Result.</strong> The signed session token, the static token, the CSRF token, and the session cookie are all valid, so the join succeeds. The LiveView runs without the <code>live_session</code> hooks. Hooks that halt the mount do not run, and hooks attached with <code>attach_hook/4</code> for <code>:handle_event</code> or <code>:handle_info</code> are never attached.</p>\n<p><strong>Conditions that stop the mount.</strong> A LiveView that defines <code>handle_params/3</code> raises on a mount without a route. A LiveView whose <code>mount/3</code> matches its params as a map raises. A LiveView that reads an assign that a skipped hook sets raises. In these cases the join fails.</p>\n<p>The official JavaScript client always sends <code>\"url\"</code> or <code>\"redirect\"</code> for a root LiveView. Only nested views join without either key.</p>"},{"base64":false,"type":"text/markdown","value":"**1. Join authorization.** The private `Phoenix.LiveView.Channel.authorize_session/3` in `lib/phoenix_live_view/channel.ex` has three clauses. The `\"redirect\"` clause resolves the route and checks that it stays in the same `live_session`. The `\"url\"` clause requires, for a session where `Phoenix.LiveView.Session.main?/1` is true, that the route for the URL matches the view and the `live_session` of the session. The third clause matches any other join parameters and returns the session with no route and no URL. Nested LiveViews need this clause because they have no URL. The clause does not call `Phoenix.LiveView.Session.main?/1`, so it also accepts a root LiveView that was mounted at the router.\n\n**2. Mount with no route.** With no route, `mount/3` receives `:not_mounted_at_router` as its params. The private `load_lifecycle/2` adds the `on_mount` hooks of the `live_session` only when it receives a `%Phoenix.LiveView.Route{}`. Without a route it returns the lifecycle of the LiveView module alone. The `live_session` layout is skipped in the same way.\n\n**3. Result.** The signed session token, the static token, the CSRF token, and the session cookie are all valid, so the join succeeds. The LiveView runs without the `live_session` hooks. Hooks that halt the mount do not run, and hooks attached with `attach_hook/4` for `:handle_event` or `:handle_info` are never attached.\n\n**Conditions that stop the mount.** A LiveView that defines `handle_params/3` raises on a mount without a route. A LiveView whose `mount/3` matches its params as a map raises. A LiveView that reads an assign that a skipped hook sets raises. In these cases the join fails.\n\nThe official JavaScript client always sends `\"url\"` or `\"redirect\"` for a root LiveView. Only nested views join without either key."}],"value":"1. Join authorization. The private Phoenix.LiveView.Channel.authorize_session/3 in lib/phoenix_live_view/channel.ex has three clauses. The \"redirect\" clause resolves the route and checks that it stays in the same live_session. The \"url\" clause requires, for a session where Phoenix.LiveView.Session.main?/1 is true, that the route for the URL matches the view and the live_session of the session. The third clause matches any other join parameters and returns the session with no route and no URL. Nested LiveViews need this clause because they have no URL. The clause does not call Phoenix.LiveView.Session.main?/1, so it also accepts a root LiveView that was mounted at the router.\n\n2. Mount with no route. With no route, mount/3 receives :not_mounted_at_router as its params. The private load_lifecycle/2 adds the on_mount hooks of the live_session only when it receives a %Phoenix.LiveView.Route{}. Without a route it returns the lifecycle of the LiveView module alone. The live_session layout is skipped in the same way.\n\n3. Result. The signed session token, the static token, the CSRF token, and the session cookie are all valid, so the join succeeds. The LiveView runs without the live_session hooks. Hooks that halt the mount do not run, and hooks attached with attach_hook/4 for :handle_event or :handle_info are never attached.\n\nConditions that stop the mount. A LiveView that defines handle_params/3 raises on a mount without a route. A LiveView whose mount/3 matches its params as a map raises. A LiveView that reads an assign that a skipped hook sets raises. In these cases the join fails.\n\nThe official JavaScript client always sends \"url\" or \"redirect\" for a root LiveView. Only nested views join without either key."}]}},"cveMetadata":{"assignerOrgId":"6b3ad84c-e1a6-4bf7-a703-f496b71e49db","assignerShortName":"EEF","cveId":"CVE-2026-126334","datePublished":"2026-11-20T14:44:41.639Z","dateReserved":"2026-11-13T11:19:46.893Z","dateUpdated":"2026-11-20T14:44:41.639Z","state":"PUBLISHED"},"dataType":"CVE_RECORD","dataVersion":"5.2"}