It was a rape
I find it rather worrying that so many people are convinced it wasn't, or at they very least are trying to convince others (and themselves?) that it wasn't.
Is it because this is a Clint Eastwood movie and a Clint Eastwood character that people have a hard time seeing it as rape?
I mean, it's not the usual sort of thing your screen idol does in a movie, is it? So surely it can't be happening here, right? I hate to be patronising but seeing how wafer thing some people's arguments are that it was not rape, I think there might be at least a little of that going on ... sorry to say.
But that's the whole point, people!
It's NOT the usual thing your screen idol does in a movie which is precisely why it's included here! The Stranger is NOT a nice man; he might be the protagonist but he's still a villain. He's a Bad Guy. This rape scene, so early in the movie, is a clear demonstration of that fact and is intended to demonstrate right from the word go that you are NOT watching a "lovable rogue" "anti-hero" like The Man With No Name. The Stranger is a completely different character, on a completely different moral scale.
You're not supposed to like him.
That's why this rape is shown. So that you don't like the main character. He's a villain. He's as big a villain as those he takes revenge upon if not more so; their crimes were to stand still and not help, his crimes are rape and murder.
He's the villain. It is rape.