Cannot use Web Admin on remote host

Bug reports and questions about running Virtual Radar Server on Linux
Post Reply
mgunther
Posts: 17
Joined: Sun Aug 21, 2016 6:45 pm

Cannot use Web Admin on remote host

Post by mgunther » Mon Aug 22, 2016 6:29 pm

OK.. only playing with this here. This is my test and situation:
- AWS Ubuntu VM, no GUI installed
- VRS and Web Admin plugin installed, both version 2.4
- can ssh into the VM remotely (i.e. from my laptop)
- did mono VirtualRadar.exe -nogui -createAdmin:name -password:password
- VRS starts fine with: mono VirtualRadar.exe
- can access http://<AWS VM host>:8080/VirtualRadar/desktop.html (this displays nothing obviously but at least I'm getting there)

My problem is that I cannot access the Web Admin page at: http://<AWS VM host>:8080/VirtualRadar/WebAdmin/Index.html

I think this may be because the plugin does not allow access from the Internet. But in order to allow access from the Internet, I need to log into the Web Admin page and configure it. But what to do if I cannot get there in the first place? Is there a config file that can be written or edited?

Just to demonstrate the issue further:
From the AWS Ubuntu VM console I get this:
wget http://<AWS VM host>:8080/VirtualRadar/WebAdmin/Index.html
HTTP request sent, awaiting response... 401 Unauthorized
Username/Password Authentication Failed.
(meaning I get the page but I did not specify the correct Username/Password)

But from an external source, i.e. a Raspberry Pi I get:
wget http://<AWS VM host>:8080/VirtualRadar/WebAdmin/Index.html
HTTP request sent, awaiting response... 403 Forbidden
(meaning I cannot get the the requested page because I'm not allowed to connect to it from an external location)

If anyone has any idea how to get around this and allow external access, let me know please :)

mgunther
Posts: 17
Joined: Sun Aug 21, 2016 6:45 pm

Re: Cannot use Web Admin on remote host

Post by mgunther » Mon Aug 22, 2016 9:24 pm

Update:
I configured the Web Admin plugin for open access on my laptop (Mac/OSX) and then copied ~.local/share/VirtualRadar/PluginsConfiguration.txt file from the laptop to the same location on the AWS Ubuntu VM. Restarted VRS and bingo, I can now access the Web Admin remotely :D
For future reference, the contents of the file with just open access configured for Web Admin (and nothing else) looks like this:

Code: Select all

VirtualRadar.Plugin.WebAdmin.Options=%7b%22DataVersion%22%3a2%2c%22Enabled%22%3atrue%2c%22Access%22%3a%7b%22DefaultAccess%22%3a0%2c%22Addresses%22%3a%5b%5d%7d%7d

agw
Posts: 2130
Joined: Fri Feb 17, 2012 3:20 am

Re: Cannot use Web Admin on remote host

Post by agw » Tue Aug 23, 2016 1:37 am

By default the web admin plugin is configured to block all access unless it's from the local loopback or a LAN address. If you're using SSH then you could create an SSH tunnel mapping local port 8080 to the remote port 8080 (or whatever VRS is listening to) and then browse to http://127.0.0.1:8080/WebAdmin/Index.html. That way you can continue to keep it restricted to LAN and local loopback but still use it remotely. I've been doing that with a remote installation of VRS that I've got running on a Pi2.

mgunther
Posts: 17
Joined: Sun Aug 21, 2016 6:45 pm

Re: Cannot use Web Admin on remote host

Post by mgunther » Tue Aug 23, 2016 8:22 am

Thanks! I'll give that a go when I get a chance. In the meantime I got over the hurdle by copying the config file as above. But yeah that means the Web Admin access is currently not restricted (except for the password which I should update...).

ktul_adsb
Posts: 3
Joined: Thu Sep 28, 2017 1:06 pm

Re: Cannot use Web Admin on remote host

Post by ktul_adsb » Thu Sep 28, 2017 2:04 pm

mgunther wrote:Update:
I configured the Web Admin plugin for open access on my laptop (Mac/OSX) and then copied ~.local/share/VirtualRadar/PluginsConfiguration.txt file from the laptop to the same location on the AWS Ubuntu VM. Restarted VRS and bingo, I can now access the Web Admin remotely :D
For future reference, the contents of the file with just open access configured for Web Admin (and nothing else) looks like this:

Code: Select all

VirtualRadar.Plugin.WebAdmin.Options=%7b%22DataVersion%22%3a2%2c%22Enabled%22%3atrue%2c%22Access%22%3a%7b%22DefaultAccess%22%3a0%2c%22Addresses%22%3a%5b%5d%7d%7d
Just wanted to say thanks for this, I am trying to get VRS running on a VPS, and spent an hour trying to figure out how to access the webadmin site from my external ip. :D

philhyde
Posts: 7
Joined: Tue Oct 13, 2015 7:26 pm

Re: Cannot use Web Admin on remote host

Post by philhyde » Mon Jun 18, 2018 10:42 pm

mgunther wrote:
Mon Aug 22, 2016 9:24 pm
Update:
I configured the Web Admin plugin for open access on my laptop (Mac/OSX) and then copied ~.local/share/VirtualRadar/PluginsConfiguration.txt file from the laptop to the same location on the AWS Ubuntu VM. Restarted VRS and bingo, I can now access the Web Admin remotely :D
For future reference, the contents of the file with just open access configured for Web Admin (and nothing else) looks like this:

Code: Select all

VirtualRadar.Plugin.WebAdmin.Options=%7b%22DataVersion%22%3a2%2c%22Enabled%22%3atrue%2c%22Access%22%3a%7b%22DefaultAccess%22%3a0%2c%22Addresses%22%3a%5b%5d%7d%7d
Sorry, old post.... but wanted to thank the user for posting this! Works a treat. 8-)

Post Reply