Skip to content

Conversation

@techtasie
Copy link

It makes sense to allow connections from remote hosts if you want to run FlexBE on a robot and the WebUI on your PC.

@dcconner dcconner self-assigned this Apr 30, 2025
@Maik13579
Copy link

You must replace localhost in ros_subscriber.js. (line 6)
Without this change, you can modify behaviors but can't execute them.
Tested on the Jazzy branch.

https://github.com/FlexBE/flexbe_webui/blob/main/flexbe_webui/app/ros/ros_subscriber.js?plain=1#L6

@dcconner
Copy link
Member

dcconner commented Nov 8, 2025

@techtasie

Sorry for the delay, I'm getting back to this, and hope to get this merged this month.

Our normal mode is that the OCS (mirror + server + client) runs remote from the robot, but we should allow multiple computers on OCS network to run client, so I appreciate this PR.

I'm inclined to make 127.0.0.1 the default not 0.0.0.0 to make the default more secure and limit access by default.

For @Maik13579 's comment, ChatGPT suggests:

const wsProto = window.location.protocol === "https:" ? "wss:" : "ws:";
const wsHost = window.location.host;  // e.g., "192.168.1.20:8000" or "mydomain.com"
const ws = new WebSocket(`${wsProto}//${wsHost}/ws/${topic.replaceAll('/', '-')}`);

This is currently untested.

I need to run these changes by some folks more attuned to cybersecurity than I am.

@dcconner
Copy link
Member

dcconner commented Nov 8, 2025

See https://github.com/FlexBE/flexbe_webui/tree/pr/8 for latest code.

@Maik13579 or @techtasie can you test the branch pr/8 branch on your systems?

I'm keeping this PR open for discussion, but plan to close and merge from that branch if it checks out as pr/8 branch is rebased with latest changes .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants