HTTP still active on port 8082 after HTTPS configured

Daryl Sargent5 years ago

Hi - I have followed the instructions here: https://www.traccar.org/secure-connection/ and now have HTTPS working correctly. I have also set up so HTTP on port 80 redirects to HTTPS.

My problem is I can still browse unencrypted using HTTP on port 8082. Have I missed something or is this how it works?

Daryl Sargent5 years ago

Ok - I worked out a way to achieve this - not sure if it is the recommended way but if so may be worth adding to the above linked article:

iptables -A INPUT -p tcp -s localhost --dport 8082 -j ACCEPT
iptables -A INPUT -p tcp --dport 8082 -j DROP

This blocks any external attempts from accessing port 8082 while allowing the Apache proxy to still access it via localhost.

Slawek5 years ago

maybe /opt/traccar/conf/default.xml

<entry key='web.port'>8082</entry>
Alex T5 years ago

Change host to listen only local:

<entry key='web.address'>127.0.0.1</entry>
Daryl Sargent5 years ago

Thanks that would probably work too - will try later.