{"id":"CVE-2026-63188","kind":"vulnerability","aliases":["CVE-2026-63188","GHSA-rxjr-6c9q-h67x"],"related":[],"title":"logto-tunnel serves files outside `--experience-path` via path traversal","description":"### Summary\n\n`@logto/tunnel` serves custom sign-in experience files from the `--experience-path` directory. When the tunnel service is reachable, a requester can use `../` path segments in a static asset request to read files outside that directory that the CLI process can read.\n\n### Details\n\nThe tunnel command accepts `--experience-path` as the local folder path for custom sign-in experience assets. `packages/tunnel/src/commands/tunnel/index.ts` enables `createStaticFileProxy(path)` when that option is set and sends non-Logto, non-`--experience-uri` requests to that static proxy. The server is started with `server.listen(port)`.\n\n`packages/tunnel/src/commands/tunnel/utils.ts` builds the filesystem path as `path.join(staticPath, fallBackToIndex ? index : request.url)`. For file asset paths, `request.url` is used directly. A request URL such as `/../secret.txt` resolves outside `staticPath` and is then opened with `fs.open(requestPath, 'r')`. There is no URL normalization and no containment check that the resolved path remains under the configured static directory before the file is read and returned.\n\nThe proof boundary is the packaged CLI end-to-end run. The filesystem read primitive was validated with equivalent Node HTTP handling for the affected code path, including that Node preserves `/../secret.txt` in `request.url` and that bare `server.listen(port)` binds to all interfaces on this platform.\n\n### PoC\n\n1. Create a custom UI directory at `/tmp/logto-ui/static` with `/tmp/logto-ui/static/index.html`.\n2. Create a sibling file outside the static root, for example `/tmp/logto-ui/secret.txt`.\n3. Start the tunnel with `logto-tunnel --endpoint https://<tenant-id>.logto.app --port 9000 --experience-path /tmp/logto-ui/static`.\n4. Request `http://<host>:9000/../secret.txt`.\n5. The response body contains the contents of `/tmp/logto-ui/secret.txt`.\n\n### Impact\n\nThe observed result is arbitrary file read outside the configured custom UI static directory. If the tunnel port is reachable from another host, an unauthenticated network peer can read local files readable by the `logto-tunnel` process, including development secrets or credentials stored near the custom UI project.","summary":"The @logto/tunnel npm package serves custom sign-in UI files from a local folder but does not stop '../' segments in request URLs. A network peer can request a path like /../secret.txt and read any file the logto-tunnel process can read.","severity":"high","cvss":8.7,"epss":0.0054,"exploited":false,"exploited_at":null,"products":[{"name":"@logto/tunnel","fixed":["0.3.9"],"affected":"<= 0.3.8","ecosystem":"npm"}],"ecosystems":["npm"],"tags":["cwe-22","logto","node","npm","package","self-hosted"],"not_affected_if":["no-experience-path","tunnel-not-reachable","version-0.3.9-or-later"],"how_to_check":"- Check the installed version with `npm ls @logto/tunnel`; versions `0.3.8` and below are affected.\n- Check whether the tunnel was started with `--experience-path` and whether its port is reachable from other hosts.","fix":"- `@logto/tunnel` `0.3.9`","status":"open","published_at":"2026-08-19T20:17:20+00:00","first_seen_at":"2026-11-05T17:38:59+00:00","triaged_at":"2026-11-05T17:40:00+00:00","updated_at":"2026-11-05T17:40:05+00:00","category":"package","confidence":0.85,"triage":{"at":"2026-11-05T17:40:00Z","model":"claude-haiku-5-5","output":{"fix":"- `@logto/tunnel` `0.3.9`","reach":"network","title":"logto-tunnel: path traversal lets network peers read arbitrary local files","impact":"high","summary":"The @logto/tunnel npm package serves custom sign-in UI files from a local folder but does not stop '../' segments in request URLs. A network peer can request a path like /../secret.txt and read any file the logto-tunnel process can read.","audience":"developers","category":"package","nicknames":[],"who_cares":["logto","npm","node","self-hosted"],"confidence":0.85,"fix_status":"available","needs_auth":"no","worst_case":"unauthenticated peers read local files readable by the tunnel process","analyst_note":"","how_to_check":"- Check the installed version with `npm ls @logto/tunnel`; versions `0.3.8` and below are affected.\n- Check whether the tunnel was started with `--experience-path` and whether its port is reachable from other hosts.","plain_action":"","needs_analyst":false,"not_affected_if":["no-experience-path","tunnel-not-reachable","version-0.3.9-or-later"],"who_is_affected":"Teams running logto-tunnel with --experience-path to serve custom sign-in UI assets, where the tunnel port is reachable beyond the developer's own machine. Anyone not using the tunnel command or the experience-path option can skip it.","user_interaction":"no","needs_special_setup":"yes","severity_if_unknown":"high"},"cost_usd":0.000758,"input_tokens":5020,"output_tokens":511,"severity_before":"high"},"analyst_status":null,"analyst_note":null,"search":"'-2026':14A,22A '-22':26B '-63188':15A,23A '/../secret.txt':65B,195C,265C '/tmp/logto-ui/secret.txt':302C,330C '/tmp/logto-ui/static':288C,318C '/tmp/logto-ui/static/index.html':290C '1':281C '2':291C '3':303C '4':319C '5':322C '6c9q':19A '9000':314C '9000/../secret.txt':321C 'accept':125C 'affect':258C 'anoth':353C 'arbitrari':336C 'asset':107C,140C,184C 'bare':270C 'bind':273C 'bodi':325C 'boundari':235C 'build':172C 'check':215C 'cli':117C,239C 'code':259C 'command':124C 'configur':223C,341C 'contain':214C,326C 'content':328C 'creat':282C,292C 'createstaticfileproxi':143C 'credenti':374C 'custom':39B,80C,135C,284C,342C,378C 'cve':13A,21A 'cwe':25B 'detail':121C 'develop':371C 'direct':189C 'directori':91C,114C,225C,286C,345C 'enabl':142C 'end':241C,243C 'end-to-end':240C 'endpoint':311C 'equival':252C 'exampl':301C 'experi':8A,84C,89C,127C,139C,157C,316C 'experience-path':7A,88C,126C,315C 'experience-uri':156C 'fallbacktoindex':179C 'file':5A,44B,69B,85C,111C,183C,228C,295C,337C,362C 'filesystem':174C,246C 'folder':48B,132C 'fs.open':204C 'ghsa':17A 'ghsa-rxjr-6c9q-h67x':16A 'h67x':20A 'handl':255C 'host':33B,354C 'http':254C 'impact':331C 'includ':261C,370C 'index':180C 'interfac':276C 'like':64B 'local':47B,131C,361C 'logto':2A,27B,72B,154C,309C,367C 'logto-tunnel':1A,71B,308C,366C 'logto.app':312C 'logto/tunnel':24A,35B,78C 'near':376C 'network':58B,357C 'node':28B,253C,263C 'non':153C,155C 'non-logto':152C 'normal':211C 'npm':29B,36B 'observ':333C 'open':202C 'option':147C 'outsid':6A,112C,197C,296C,339C 'packag':30B,37B,238C 'packages/tunnel/src/commands/tunnel/index.ts':141C 'packages/tunnel/src/commands/tunnel/utils.ts':171C 'path':9A,11A,63B,90C,102C,128C,133C,144C,175C,185C,219C,260C,317C 'path.join':177C 'peer':59B,358C 'platform':279C 'poc':280C 'port':170C,272C,313C,349C 'preserv':264C 'primit':248C 'process':74B,118C,369C 'project':380C 'proof':234C 'proxi':163C 'r':206C 'reachabl':97C,351C 'read':67B,76B,110C,120C,230C,247C,338C,360C 'readabl':363C 'remain':220C 'request':55B,61B,99C,108C,159C,191C,320C 'request.url':181C,186C,267C 'requestpath':205C 'resolv':196C,218C 'respons':324C 'result':334C 'return':232C 'root':299C 'run':244C 'rxjr':18A 'secret':372C 'segment':53B,103C 'self':32B 'self-host':31B 'send':151C 'serv':4A,38B,79C 'server':165C 'server.listen':169C,271C 'servic':95C 'set':149C 'sibl':294C 'sign':41B,82C,137C 'sign-in':40B,81C,136C 'start':167C,304C 'static':106C,162C,224C,298C,344C 'staticpath':178C,198C 'stop':52B 'store':375C 'summari':77C 'travers':12A 'tunnel':3A,73B,94C,123C,306C,310C,348C,368C 'ui':43B,285C,343C,379C 'unauthent':356C 'uri':158C 'url':56B,192C,210C 'use':101C,188C 'valid':250C 'via':10A","nicknames":[],"mitigations":[],"who_affected":"Teams running logto-tunnel with --experience-path to serve custom sign-in UI assets, where the tunnel port is reachable beyond the developer's own machine. Anyone not using the tunnel command or the experience-path option can skip it.","tier":"B","verified":{},"analyst_revisit_at":null,"fix_status":"available","audience":"developers","plain_action":null,"pkeys":["tunnel"],"ptokens":["logto","tunnel"],"labels":["cwe22","high","logto","node","npm","package","selfhosted"],"campaign_type":null,"first_public_at":"2026-07-02T07:39:52+00:00","kev":null,"cvss_vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","cvss_by":"security-advisories@github.com","poc_count":0,"sources":[{"source":"ghsa","external_id":"GHSA-rxjr-6c9q-h67x","url":"https://github.com/advisories/GHSA-rxjr-6c9q-h67x","severity":"high","published_at":"2026-08-19T20:24:06+00:00","modified_at":"2026-11-05T17:34:51+00:00","first_seen_at":"2026-11-05T17:38:59+00:00","fetched_at":"2026-11-05T17:46:22+00:00","note":null},{"source":"nvd","external_id":"CVE-2026-63188","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-63188","severity":null,"published_at":"2026-08-19T20:17:20+00:00","modified_at":"2026-09-09T21:15:59+00:00","first_seen_at":"2026-11-05T17:40:05+00:00","fetched_at":"2026-11-05T17:40:05+00:00","note":null}],"documents":[{"id":78065,"url":"https://api.github.com/repos/logto-io/logto/security-advisories/GHSA-rxjr-6c9q-h67x","title":"Maintainer's advisory: api.github.com","kind":"vendor","source":"ghsa","publisher":"vendor","text":null,"published_at":null,"relation":"advisory","confidence":null,"note":"Maintainer's advisory: api.github.com"},{"id":78066,"url":"https://github.com/logto-io/logto/security/advisories/GHSA-rxjr-6c9q-h67x","title":"Maintainer's advisory: github.com","kind":"vendor","source":"ghsa","publisher":"vendor","text":null,"published_at":"2026-07-02T07:39:52+00:00","relation":"advisory","confidence":null,"note":"Maintainer's advisory: github.com"},{"id":78067,"url":"https://github.com/logto-io/logto/pull/9113","title":"Patch: github.com","kind":"other","source":"ghsa","publisher":"vendor","text":null,"published_at":null,"relation":"fix","confidence":null,"note":"Patch: github.com"},{"id":78068,"url":"https://github.com/logto-io/logto/commit/5686815955534f803d3d50738259efd0f741e62c","title":"Patch: github.com","kind":"other","source":"ghsa","publisher":"vendor","text":null,"published_at":null,"relation":"fix","confidence":null,"note":"Patch: github.com"},{"id":78069,"url":"https://github.com/logto-io/logto/releases/tag/@logto/tunnel@0.3.9","title":"Release: github.com","kind":"release","source":"ghsa","publisher":"vendor","text":null,"published_at":null,"relation":"fix","confidence":null,"note":"Release: github.com"}],"exploit_sources":[{"type":"epss","score":0.0054,"url":"https://api.first.org/data/v1/epss?cve=CVE-2026-63188"}],"notice":"Free to read, with fair use of about 60 pages a minute. For higher limits or API access: sales@infrastack.ai"}