-
Notifications
You must be signed in to change notification settings - Fork 491
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
IPFS UI + HTTPs API are always pointing to port 80 #611
Comments
Preliminary warning: Please do not expose your API to the public internet. It looks like this may have already been fixed (#602). We've recently updated the webui version in the go-ipfs master; would you mind building go-ipfs from git and trying that? |
I tried master (commit 3d8aa07) built as It seems to have the opposite problem now. I see Firefox blocking the AJAX requests like this:
Note port 443 but scheme http. |
Is it possible to define this value (port, protocol, domain/ip, hash of the UI) in a env variable or somewhere in the conf? That would solve the problem and allow us to test more versions easily |
@danc86 @koalalorenzo could you please try the branch api-local and let me know if it works correctly? |
I built commit b2dc3ad as QmZ8QuzSiF5mfJSYbAA6JWBENmYsYo3vzrSPtZxHKqPxSo. It still has the same problem, tries to access http://hostname:443/... It looks like you are intentionally slicing off the final char of window.location.protocol, what's up with that? Why not just use window.location.protocol as is? |
@danc86 the |
Oh I see, makes sense. So it looks like it should work... does that mean I did something wrong when I built QmZ8QuzSiF5mfJSYbAA6JWBENmYsYo3vzrSPtZxHKqPxSo ? I just re-ran |
All the js is minified and there are no source maps, so the browser debugger is useless :-( |
Fixed in #639 and the soon to be released Web UI v2 allows you to set your api address. |
salutations ipfs team! using https://dist.ipfs.io/go-ipfs/v0.4.17/go-ipfs_v0.4.17_linux-amd64.tar.gz able to load most of the webui, but it cant finish loading everything because its trying to pull from http://domain.tld:443/api/v0/ current relevant nginx config:
identical to ipfs/kubo#4488 (comment) |
👋 v2 of the Web UI is out, which is a significant re-write. It'll be released with v0.4.18 of go-ipfs. You can also try out a recent build at https://webui.ipfs.io In general, the Web UI expects accessed via 127.0.0.1, on the same port as the API. There is currently no access control or authentication for the http API, so it is not advised that you proxy access to it to the public internet. See #836 |
As Oli said, current Web UI (v2.1.1) should be accessed only from localhost. In case people with similar problem find this issue in the future, additional notes below. If you want to expose public HTTP gateway (similar to these), the nginx config from #611 (comment) does not look right:
If you want to use Web UI with remote node today: If you really know what you are doing and really want to expose API port to the internet:
|
Version information: 0.4.13
Type: Bug
Severity: Medium
Description:
When I am exposing the API behind a reverse proxy via HTTPS (nginx), the API call coming from the
/webui
interface are all failing as they are trying to get to port:80
. In the logs of the browser it looks like this:What should I do to allow the UI to talk to the HTTPS correctly?
If I am disabling HTTPS it works perfectly.
To reproduce you can spin up a container, set up nginx to point
:443
to:5001
. Even with a fake certificate you will see the problem by browsing tohttps://localhost/webui
.(clones ipfs/kubo#4488 as this probably is the right place to submit the issue)
The text was updated successfully, but these errors were encountered: