kubetail-org / kubetail

Web-based, real-time log viewer for Kubernetes
https://www.kubetail.com/demo
Apache License 2.0
301 stars 16 forks source link

GraphQL WebSocket connections not working on Chromium Edge on Windows 10 #3

Closed nefarius closed 5 months ago

amorey commented 5 months ago

I have a PR that should fix this https://github.com/kubetail-org/kubetail/pull/5

Can you try out the kubetail/kubetail@0.1.9-rc2 helm chart? This should work:

helm upgrade kubetail kubetail/kubetail --namespace kubetail --version 0.1.9-rc2
nefarius commented 5 months ago

Does this need some time to work?

Error: chart "kubetail" matching 0.1.9-rc2 not found in kubetail index. (try 'helm repo update'): no chart version found for kubetail-0.1.9-rc2

EDIT: NVM, reading the bloody output helps 🤣

nefarius commented 5 months ago

Hey hey! 🎉

image

amorey commented 5 months ago

Nice!!! Thanks for testing it out. The PR changes the way that kubetail protects against cross-site WebSocket connection requests so I want to tread carefully and double check the code before publishing a new release. Will try to get it out asap. If you have some time, it'd be useful to get another set of eyes on this: https://github.com/kubetail-org/kubetail/pull/5. I'm using a cookie with SameSite=Strict to ensure that only same-site connections are allowed.

nefarius commented 5 months ago

Not sure how valuable my input is here, I see what you're trying to achieve here, however I am not well versed enough in Go and front-end development to make a fair judgment.

amorey commented 5 months ago

The fix is live in kubetail:0.1.3 (chart v0.1.9):

helm repo update kubetail
helm upgrade kubetail kubetail/kubetail --namespace kubetail --version 0.1.9

I changed the strategy from using a SameSite=Strict cookie to using CSRF token validation which is more secure. Let me know if you notice any issues.

nefarius commented 5 months ago

Just updated, everything is working 👍

amorey commented 5 months ago

Nice! Thanks again for your help debugging the problem.