ory / kratos-selfservice-ui-node

Apache License 2.0
321 stars 209 forks source link

KRATOS_BROWSER_URL not effective on webauthn script src #226

Open dbtek opened 1 year ago

dbtek commented 1 year ago

Preflight checklist

Describe the bug

Script src seems to use 127.0.0.1 origin to fallback.

image

Reproducing the bug

  1. Run Kratos with webauthn enabled.
  2. Run self-service with given docker-compose config (Kratos config stripped)
  3. Login and navigate to account settings.

Relevant log output

No response

Relevant configuration

# docker-compose.yml
version: '3.7'
services:
  selfservice:
    image: oryd/kratos-selfservice-ui-node
    environment:
    - KRATOS_PUBLIC_URL=http://kratos:4433/
    - KRATOS_BROWSER_URL=http://127.0.0.1:8001/authn/
    - BASE_PATH=/auth
    - PORT=4455
    - SECURITY_MODE=
    networks:
    - intranet
    restart: on-failure
    ports:
     - "4455:4455"

Version

0.11.0

On which operating system are you observing this issue?

macOS

In which environment are you deploying?

Docker Compose

Additional Context

I would happily drop a PR if guided, since I couldn't be sure where this issue fixed. I'm sorry if I missed or did something wrong.

Thanks!

aeneasr commented 1 year ago

Looks like your kratos public url is not configured correctly, it is http://localhost:4433/ (default) but should be http://127.0.0.1:8001/authn/