Perhaps to show the level of privilege I enjoy as a software engineer with some level of seniority, I have had zero problem resigning from a position (more than once in fact) because I objected to something my employer was doing. It's been enough for me to filter potential opportunities exclusively to tech-for-good concerns.
Sure, I don't earn half a million a year total comp to kiss some billionaire's ass, but I still have a very comfortable lifestyle that is well above the median.