This is a neat and useful trick, and I will be borrowing it. Thanks!
40 karma · joined August 27, 2025
<p>Hello <scr<script>ipt>alert(1)</scr<script>ipt> World</p>
The program outputs: $ node .
<p>Hello <script>alert(1)</script> World</p>
{
sanitizedHTML: '<p>Hello <script>alert(1)</script> World</p>',
wasModified: true,
removedElements: [],
removedAttributes: []
}
Asking a chatbot to make a security function and then posting it for others to use without even reviewing it is not only disrespectful, but dangerous and grossly negligent. Please take this down.Edit: the flush example (2nd one) in the recap section does the same thing, when the text says that the records are supposed to be written to the file in sorted order.
Note: if you want to make ripgrep not do .gitignore filtering, set `RIPGREP_CONFIG_PATH` to point to a config file that contains `-uu`.
Sources:
- https://github.com/BurntSushi/ripgrep/blob/master/GUIDE.md#c...
- https://github.com/BurntSushi/ripgrep/blob/master/GUIDE.md#a...
Studio Ghibli producer, Suzuki: "So, what is your goal?"
ML Developer: "Well, we would like to build a machine that can draw pictures like humans do."
<jump cut>
Miyazaki VO: "I feel like we are nearing to the end of times."
"We humans are losing faith in ourselves."
Source: https://www.youtube.com/watch?v=ngZ0K3lWKRcOf course, the form of AI has changed over the years, but the claim that this quote could be tied to Miyazaki's general view on having machines create art is not totally baseless.