I don’t know if this is the right place to ask, but StackOverflow seems to only accept coding related questions, so this is the next best place I can find.
In UX Design, there is the concept of ‘deceptive pattern’ where the user can be intentionally led to do something that may be harmful to them without their knowledge. Of course, this surfaces as a design decision that is implemented in code and on the interface (which drives the user’s actions).
However, I read this example about Grammarly’s Browser Extension implementation, where some code is inserted without user knowledge that impacts the way the website or application behaves. So I wonder if there is an equivalent of this in coding (i.e. a deceptive programming) that can be picked up through normal software testing processes? Is this an area of research and practice in software QA?