A Cross-site Scripting (XSS) vulnerability exists in the gateway component of aap-gateway. This flaw allows a malicious user to perform actions that impact users by using the "?next=" in a URL, which can lead to redirecting, injecting malicious script, stealing sessions and data. The vulnerability exploits the `?next=` parameter in a URL.