Running PaperCut NG on port 80 (or another port)
Last modified on 29 September 2017 05:46 PM
By default, PaperCut listens to ports 9191 and 9192 for HTTP and HTTPS communication respectively. These ports have been selected as they’re generally unused by other applications. Because PaperCut is a web application it may be desirable to have the interface available on the standard HTTP and HTTPS ports (80 and 443 respectively). One reason for doing so may be to simplify URLs communicated verbally (as the user will not have to supply a port number).
Another would be to facilitate PaperCut NG and PaperCut MF’s support for HSTS, or HTTP Strict Transport Security, introduced in version 17.1. HSTS relies upon port 443 being available for secure HTTPS connections, as this is the port that supported web browsers will automatically redirect to when unwanted access over cleartext HTTP is attempted. If port 443 is not enabled for the application when HSTS is turned on, this would result in these redirections failing.
The configuration procedure is different for each operating system. See below for instructions.
Important: Before you begin, first ensure no other applications (such as IIS, or Apache) are currently installed and using ports 80 or 443 on the server hosting PaperCut.
Important: If PaperCut appears unresponsive on port 80 or 443 after enabling this, test access from the server itself. If you can access the web interface from the server, check that you do not have a firewall restriction in place for inbound connections on port 80 or 443.
Use iptables (or ipchains on old systems) to port-forward 80 to 9191. The following commands provide an example:
/sbin/iptables -t nat -I PREROUTING —src 0/0 —dst <server_ip>
(the two commands above should each be a single line)
Place these in a rc init script or the iptables startup config script as provided by your distribution.
Remapping port 80 to 9191 is recommend over changing the port in
Advanced Admins Only
Modify the Mac firewall (ipfw) with the following command:
sudo /sbin/ipfw add 102 fwd 127.0.0.1,9191 tcp from any to any 80 in
See ipfw man page for all the scary details!
PaperCut version 12.5 and later:
1) First ensure no other programs such as IIS are using ports 80 and 443.
2) Temporarily “Stop” the PaperCut Application Server service, under Control Panel → Administrative Tools → Services
3) Open the file:
4) Modify these lines (set to
5) Finally start the PaperCut Application Server service again.
Note: For those who have upgraded from previous versions of the software to 12.5 or newer, these lines will not be present. They can simply be added to the [app path]\server\server.properties file.
PaperCut version 12.4 and below:
IMPORTANT: We highly recommend leaving PaperCut on these ports as many areas of the application assume these ports are open. Changing ports will cause future problems. For example, you may upgrade PaperCut and new features or components will default to the standard ports. Some organizations however have a preference for the standard port 80. This is an option, however first you must ensure that no other programs such as IIS or Apache are using the port on the same system.
Where possible we recommend forwarding or port redirection rather than remapping the application’s own port (e.g. port 80 maps through to 9191 so it may be accessed both on port 80 and the standard 9191)
Prior to 12.5, you will need to change the ports defined in the file:
then restart the PaperCut Application Server” service under Control Panel → Administrative Tools → Services′
On Windows port forwarding is not supported by PaperCut unless you are running a third party web server such as Apache that supports HTTP request proxies (see below). For this reason administrators can configure PaperCut to use ports 9191/9192 and/or 80/443.
IMPORTANT: On all PaperCut versions. Ensure the port numbers are also updated in the following other areas:
Other methods (all platforms):
If you are running IIS or Apache, you can set up a forward or redirect in the webs server. Forward say /user through to :9191/user, etc. For example, Apache mod_proxy could be used to accomplish this.
Important: Do not override the Host header when setting up a proxy in front of PaperCut MF or PaperCut NG, as it will conflict with HTTP header origin checks (CSRF) security checks, rely on “X-Forwarded-Host” instead. For example, when using mod_proxy with Apache, do not use “mod_rewrite” to change the HOST header.
If you really have to rewrite the Host header, then the CSFR checks can be disabled using the “server.csrf-check.validate-request-origin” configuration in server.properties.