Is this a search for validation as to why the person cheated? I will admit my perception of relationships may be a bit out of left field... but seriously, people get horny.
The real question that should be asked is, if your boyfriend had sex with someone else, why did he feel the need to lie to you about it.
Let's say for the point of argument that said couple has agreed to be strictly monogamous. Partner A goes out one night, meets a guy who he finds attractive (how attractive is beside the point) and has sex with that guy. In my ideal relationship, Partner A would go back to Partner B, and say "Hey, I know we agreed to have a monogamous relationship, but last night I had sex with someone, and I am sorry." Partner B would then ask whether or not they were safe, take necessary steps and precautions accordingly, maybe have his feelings hurt for a while, and then get over it and move on.
This of course assumes a couple things. First, that the couple in question do actually love each other, and have a relationship built on multiple foundations. Second, that this is not a recurring event.
If it is a recurring event, then perhaps the relationship needs to be re-examined. Partner A and B need to COMMUNICATE with each other. Why does Partner A need sex outside of the relationship? Is it possible only one person in the relationship wants monogamy? What are the priorities in the relationship? Would an open relationship work? If not, would it be best for them to split up?
Maybe it is hard for people to be honest with themselves, which is why they can't be honest with each other, but the whole idea of soap opera relationships involving cheating, lying, finding out, going apeshit, bitching to all of your friends about how horrible the person was and how dare he cheat on you with someone who was or was not more attractive than you.... is not only annoying and juvenile, it is also dangerous. What if Partner A had unprotected sex with the guy and contracted something? In a relationship where the two people can be honest with each other, it can be dealt with. In a relationship where everything is being covered up, odd are Partner B is going to end up with it too.
Relationships do not have to fit a cookie cutter mold. Be honest up front about what you want in a relationship (This means you have to actually know what you want, and if you don't, be honest about that too) so you don't have to put yourself in a situation where you feel the need to cover up your tracks. AND if you screw up, then BOTH sides need to be able to have a mature and intelligent conversation about what it means for the relationship.