The issue arises from the `sanitize string` function not properly sanitizing HTML tags, allowing remote attackers to perform a cross-site scripting (XSS) attack. This can be achieved by wrapping a payload in malformed HTML tags, such as "<<script></script>script>payload<script></script></script>", or by using an image tag with the payload as the `onerror` event.