Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
すべてのタグがテキストから削除された場合、XSS 攻撃を実行することは可能ですか? パターン「<...>」(正規表現:/<.*?>/g)に一致するすべてを意味するタグによる。
/<.*?>/g
はい:
<img src=x onerror=alert(1)//
独自のフィルターを発明しないでください。OWASP XSS 防止チート シートで説明されているように、コンテキストをエンコードします。