Changing the port of the web interface

kumarullal

Renowned Member
Jun 17, 2009
184
0
81
LA, USA
Hi,
Is there a way to change the port of the web interface? This is because If someone on the LAN knows the internal ip address of the Proxmox server and types in the web browser, it should not take them directly to the login page.
So if I can change it to a unique port say 7777, then only if they type https://192.168.1.100:7777 it should go to the login page.
Is there a way to archive this?
Thanks in advance.
 
If they do not know the root password, then I do not see why this would be a problem. Hiding pve on a different port will not stop someone who is determined to hack the application.

However, if you are determined to change to port that apache listens on, you will have to change at least two files: /etc/apache2/ports.conf and /etc/apache2/sites-available/pve.conf. In ports.conf you will have to delete the lines for listening on 80 and 443 and add one for your custom port. Then in the pve.conf you will need to adjust the virtualhost configuration for port 443.

Keep in mind that any changes you make may be overwritten with any update that proxmox applies.

In addition, if you are worried about someone hacking 443, then you should also be worried about someone hacking ssh. After all, both logins are exactly the same. So you would probably want to change the port ssh is bound to and maybe even the vnc port that proxmox uses.

I would recommend that you install denyhosts. It monitors the auth.log file for possible breakins and block the intruder's ip address after a configurable number of failed attemps. You can also set it to sync with the denyhost's server which will pull down ips that have attacked other computers as well. Take a look at their website for more info: http://denyhosts.sourceforge.net/
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!