Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Email validation page is stuck after clicking link in the email #26968

Closed
antonengelhardt opened this issue Feb 3, 2024 · 20 comments
Closed
Labels
A-Registration O-Occasional Affects or can be seen by some users regularly or most users rarely S-Major Severely degrades major functionality or product features, with no satisfactory workaround T-Defect X-Needs-Info This issue is blocked awaiting information from the reporter

Comments

@antonengelhardt
Copy link

Steps to reproduce

  1. Where are you starting? What can you see?
  • I am trying to register a new account on my self-hosted Element Web instance running on v1.11.57.
  • When i enter my username, password and email i get the email through my configured email settings.
  • When i click the link in the email, i see a success page and it tells me to close the tab.
  • The initial page where the flow was started, does not change.
  1. What do you click?

The link in the email

  1. More steps

Outcome

What did you expect?

I expected to see the screen where i choose the purpose of how i plan to use Element (Friends, Company, etc.)

What happened instead?

Nothing

Additional information

I am deploying Matrix, Coturn and Element through Kubernetes and with this helm chart.

The interesting thing is that the whole flow works when i do it in the iOS App (not X) or in the Mac App. Just the browser version seems to have Problems or misconfiguration ...

I am requiring the email PID for every registration and define a set of domains that the email is allowed to be sent to.

Operating system

MacOS

Browser information

Arc Version 1.27.3 (45706)

URL for webapp

v1.11.57

Application version

Version 1.11.57 (1.11.57)

Homeserver

synapse v1.97.0

Will you send logs?

Yes

@antonengelhardt
Copy link
Author

Matrix logs

The only logs that instantly appear after clicking the link is:

2024-02-03 18:24:29,466 - synapse.rest.client.register - 537 - WARNING - POST-145 - Ignoring initial_device_display_name without password

Element logs

/docker-entrypoint.sh: /docker-entrypoint.d/ is not empty, will attempt to perform configuration
/docker-entrypoint.sh: Looking for shell scripts in /docker-entrypoint.d/
/docker-entrypoint.sh: Launching /docker-entrypoint.d/10-listen-on-ipv6-by-default.sh
10-listen-on-ipv6-by-default.sh: info: can not modify /etc/nginx/conf.d/default.conf (read-only file system?)
/docker-entrypoint.sh: Sourcing /docker-entrypoint.d/15-local-resolvers.envsh
/docker-entrypoint.sh: Launching /docker-entrypoint.d/20-envsubst-on-templates.sh
/docker-entrypoint.sh: Launching /docker-entrypoint.d/30-tune-worker-processes.sh
/docker-entrypoint.sh: Configuration complete; ready for start up
10.244.0.187 - - [03/Feb/2024:18:58:30 +0000] "GET / HTTP/1.1" 200 7534 "-" "kube-probe/1.29" "-"
10.244.0.187 - - [03/Feb/2024:18:58:30 +0000] "GET / HTTP/1.1" 200 7534 "-" "kube-probe/1.29" "-"
10.244.1.74 - - [03/Feb/2024:18:58:37 +0000] "GET /config.json?cachebuster=1706986716225 HTTP/1.1" 200 731 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36" "10.114.0.3"
2024/02/03 18:58:37 [error] 22#22: *4 open() "/usr/share/nginx/html/config.element.mydomain.json" failed (2: No such file or directory), client: 10.244.1.74, server: localhost, request: "GET /config.element.mydomain.json?cachebuster=1706986716225 HTTP/1.1", host: "element.mydomain"
10.244.1.74 - - [03/Feb/2024:18:58:37 +0000] "GET /config.element.mydomain.json?cachebuster=1706986716225 HTTP/1.1" 404 555 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36" "10.114.0.3"
10.244.1.74 - - [03/Feb/2024:18:58:38 +0000] "GET /version HTTP/1.1" 200 8 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36" "10.114.0.3"
10.244.1.74 - - [03/Feb/2024:18:58:38 +0000] "GET /sw.js HTTP/1.1" 200 40 "https://element.mydomain/sw.js" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36" "10.114.0.3"
10.244.1.74 - - [03/Feb/2024:18:58:40 +0000] "GET /img/matrix.d1fcad6.svg HTTP/1.1" 200 16010 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36" "10.114.0.3"
10.244.0.187 - - [03/Feb/2024:18:58:40 +0000] "GET / HTTP/1.1" 200 7534 "-" "kube-probe/1.29" "-"
10.244.1.74 - - [03/Feb/2024:18:58:40 +0000] "GET /welcome/images/icon-sign-in.svg HTTP/1.1" 200 54455 "https://element.mydomain/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36" "10.114.0.3"
10.244.1.74 - - [03/Feb/2024:18:58:40 +0000] "GET /welcome/images/icon-create-account.svg HTTP/1.1" 200 587 "https://element.mydomain/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36" "10.114.0.3"
10.244.0.187 - - [03/Feb/2024:18:58:50 +0000] "GET / HTTP/1.1" 200 7534 "-" "kube-probe/1.29" "-"

Screenshot of the issue

Screenshot-Arc-005597

@antonengelhardt
Copy link
Author

antonengelhardt commented Feb 3, 2024

One last note: The times in the logs differ because i didnt find the logs of the previous attempt in the Element pod anymore, so i did it again and just copied those ones in. The matrix logs were the same.

@dbkr dbkr added Z-Platform-Specific S-Major Severely degrades major functionality or product features, with no satisfactory workaround A-Registration X-Needs-Investigation O-Occasional Affects or can be seen by some users regularly or most users rarely labels Feb 6, 2024
@t3chguy t3chguy added X-Needs-Info This issue is blocked awaiting information from the reporter and removed X-Needs-Investigation labels Feb 12, 2024
@t3chguy
Copy link
Member

t3chguy commented Feb 12, 2024

Element logs

@antonengelhardt Element is an SPA, the logs needed are from the browser, not the web server

@antonengelhardt
Copy link
Author

@t3chguy
Screenshot-Arc-005713@2x

interactive-auth.ts:348 Uncaught (in promise) TypeError: Failed to construct 'URL': Invalid URL
    at u.poll (interactive-auth.ts:348:43)
    at InteractiveAuth.tsx:136:32
poll @ interactive-auth.ts:348
(anonymous) @ InteractiveAuth.tsx:136
setInterval (async)
d @ InteractiveAuth.tsx:135
yo @ react-dom.production.min.js:135
Zs @ react-dom.production.min.js:181
$a @ react-dom.production.min.js:269
Dl @ react-dom.production.min.js:250
Fl @ react-dom.production.min.js:250
Tl @ react-dom.production.min.js:250
yl @ react-dom.production.min.js:243
(anonymous) @ react-dom.production.min.js:123
t.unstable_runWithPriority @ scheduler.production.min.js:18
qi @ react-dom.production.min.js:122
$i @ react-dom.production.min.js:123
Hi @ react-dom.production.min.js:122
pl @ react-dom.production.min.js:237
enqueueSetState @ react-dom.production.min.js:133
f.setState @ react.production.min.js:12
(anonymous) @ Registration.tsx:311
doSubmit @ RegistrationForm.tsx:168
(anonymous) @ RegistrationForm.tsx:157
await in (anonymous) (async)
ze @ react-dom.production.min.js:52
$e @ react-dom.production.min.js:52
(anonymous) @ react-dom.production.min.js:53
Tr @ react-dom.production.min.js:100
Fr @ react-dom.production.min.js:101
(anonymous) @ react-dom.production.min.js:113
Pe @ react-dom.production.min.js:292
(anonymous) @ react-dom.production.min.js:50
Nr @ react-dom.production.min.js:105
Xt @ react-dom.production.min.js:75
Qt @ react-dom.production.min.js:74
t.unstable_runWithPriority @ scheduler.production.min.js:18
qi @ react-dom.production.min.js:122
Oe @ react-dom.production.min.js:292
Wt @ react-dom.production.min.js:73
Show 36 more frames
Show less

Copy link

dosubot bot commented Feb 13, 2024

🤖

Hello @antonengelhardt! 👋 I'm Dosu, a bot here to help you solve bugs, answer questions, and become a contributor while you're waiting for a human maintainer. I'm here to assist you, so let's dive into your issue and I'll get back to you with a full answer shortly!

@t3chguy
Copy link
Member

t3chguy commented Feb 13, 2024

What homeserver are you using?

@antonengelhardt
Copy link
Author

antonengelhardt commented Feb 13, 2024

Synapse v1.97.0

@antonengelhardt
Copy link
Author

It looks like it cannot poll some URL that it most likely managing the validation 🤔

@t3chguy
Copy link
Member

t3chguy commented Feb 13, 2024

This seems like a misconfiguration, and invalid URL is given for the identity server which forms part of your email verification. Is this a self-hosted setup?

@antonengelhardt
Copy link
Author

Yes, I am using Helm and kubernetes to deploy. In the issue description is the chart I used. Can you tell me what variable is most likely wrong?

@t3chguy
Copy link
Member

t3chguy commented Feb 13, 2024

The identity server, without seeing the full config it won't be possible to chase this any further

@antonengelhardt
Copy link
Author

I am not using any identity server...

In my matrix config i have required email 3pid. Then i have also configured smtp settings to send the emails which also arrive.

I can send you the config via email (or some other channel) because there are too many secrets and confidential stuff to post it on here.

@t3chguy
Copy link
Member

t3chguy commented Feb 13, 2024

I believe Element Web's implementation relies on older spec (for wider compatibility) and requires an IS for email verification - similar issue to #26172

@t3chguy
Copy link
Member

t3chguy commented Feb 13, 2024

Emailing it to me won't do much good, I'm just triaging the issue. Anyone can work on it, its an open source project. But if isn't reproducible in a public server or trivial example then it is quite unlikely to be picked up

@antonengelhardt
Copy link
Author

Reading through the ticket, that you linked, it looks like i have to use vector.im as the identity server? Correct?

@t3chguy
Copy link
Member

t3chguy commented Feb 13, 2024

Hosting your own is an option, you're not forced to use a centralised service at any point

@antonengelhardt
Copy link
Author

antonengelhardt commented Feb 13, 2024

I tried that once, and it was not really trivial... So i decided to keep my hands off it.

For some reason, registration works flawlessly on MacOS and iOS, just not on Web

@t3chguy
Copy link
Member

t3chguy commented Feb 13, 2024

If by MacOS you mean Element Desktop, that'll because it indeed uses vector.im by default in its config unless you build it yourself/override the config manually. https://github.com/element-hq/element-desktop/blob/develop/element.io/release/config.json#L8-L10

@antonengelhardt
Copy link
Author

Ok, thanks for your help. I will turn off Element Web and just use the native clients.

wj25czxj47bu6q added a commit to ArcticFoxes-net/Synapse-Ubuntu-ZFS that referenced this issue Feb 17, 2024
@t3chguy
Copy link
Member

t3chguy commented Nov 20, 2024

Fixed by matrix-org/matrix-js-sdk#4200

@t3chguy t3chguy closed this as completed Nov 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Registration O-Occasional Affects or can be seen by some users regularly or most users rarely S-Major Severely degrades major functionality or product features, with no satisfactory workaround T-Defect X-Needs-Info This issue is blocked awaiting information from the reporter
Projects
None yet
Development

No branches or pull requests

3 participants