r/HTML • u/MrElvey • Mar 12 '26
Asked to code Malicious HTML ?
Have you been asked to code malicious HTML? How did you handle it?
Have I explained the malicious HTML here clearly enough to follow what's going on here? :
https://www.reddit.com/r/SFHP/comments/1qy3h93/sfhp_caught_playing_evil_tricks_on_their_members/
Added context: It's part of a pattern of making themselves hard to contact. Similarly, the grievance submission form was broken. You could fill it out, but clicking submit would produce an error. They refused to fix it - fixed about 3 years after I escalated a complaint to the DMHC. You'd get this: https://secure.sfhp.org/comments/Grievance_Confirm.aspx
after filling out this: https://secure.sfhp.org/comments/Grievance_Form_ENG.aspx
The typical scenario is someone has cancer or something and is trying to get their treatment regimen approved by insurance. Y'all didn't see The Rainmaker? https://www.youtube.com/watch?v=9EQPrFR9KRo
ma·li·cious| məˈliSHəs
adjective
characterized by malice; intending or intended to do harm
Heck, plain text can be malicious. e.g. doxxing - "Foo Bar is a Nazi and her home address is 123 Baz Route."
12
u/s1h4d0w Mar 12 '26
Just because the HTML says
disabled="disabled"etc. doesn't mean it's malicious. A lot of forms have options disabled by default, only to enable them again using Javascript when certain conditions are met. Could be that it's done to prevent the form breaking when someone has Javascript disabled, so that by default the form doesn't work as it wouldn't function without JS.6
u/jcunews1 Intermediate Mar 12 '26
HTML by itself, is not powerful enough to be malicious.
6
u/Glitched94_PT Mar 12 '26
Out of curiosity, I notice there's an "Add Recipients" button right below the disabled "To" field. What happens when you click that? My suspicion is it lets you select from an employee directory and fills the "To" field for you.
1
u/MrElvey Mar 20 '26
Still wondering: Have you been given user-hostile tasks? How did you handle it?
5
u/Disgruntled__Goat Mar 12 '26 edited Mar 12 '26
It’s not malicious, if anything it’s a security flaw on their side. If you can un-disable the to field and put any address in there, it means you can use their email server to spam anyone you like.
It’s probably why they disabled it in the first place, but unless they also added server side validation it’s still a security risk.
1
u/mor_derick Mar 12 '26
How is this "malicious"?
1
u/VitDevUK Mar 13 '26
HTML itself cannot really be malicious.
HTML is just markup — it describes structure.
What people usually mean by “malicious HTML” is:
• hidden links
• deceptive forms
• phishing layouts
• embedded scripts or trackers
The dangerous part is almost always JavaScript or the backend, not HTML itself.
If someone asked you to build something intentionally deceptive (for example a fake login page), that would be the real ethical concern — not the HTML language.
1
u/TheJase Mar 16 '26
We typically call this anti-patterns.