The vulnerability is a classic authentication bypass in the web application's request handling logic. PaperCut uses the Apache Tapestry framework, and the exploit leverages a weakness in how 'complex-direct' requests are handled. The application correctly checks for authentication on the page being rendered to the user but fails to check authentication for the backend component being invoked. This allows an unauthenticated attacker to call administrative functions by routing their request through a public page. The exploit specifically targets the 'ConfigEditor' to modify the 'external user lookup' settings to point to a malicious JDBC URL. Then, by triggering a user search via the 'UserList' page, the application attempts to connect to the malicious database, leading to remote code execution. The vulnerable functions are therefore the administrative components that can be accessed without authentication and the database connection function that is subsequently abused.