During a scene in the movie, while Ethan is looking at a bible with a Chicago stamp on it, he has a revelation that Jim Phelps is actually the mole.
How did he come to this idea and how did the Chicago stamp lead him to this?
Well, the bible is not just from Chicago, but especially from the Drake Hotel in Chicago, where Jim lived as he said earlier. This is quite a coincidence, considering that Jim wouldn't have any reason to steal a bible from the hotel. On the other hand Job surely needs a bible for the communication cypher with Max based on bible quotes.
So it is the mere coincidence, that the bible is exactly from the hotel Jim lived in and he probably took it with him. Together with the fact that he surprisingly survived it is a strong indication of Jim being the traitor.
I'm not sure he immediately believed Jim to be the traitor when reading the stamp, but he gets suspicious. Then seeing Jim alive (and denouncing Kittridge, which isn't that believable to Ethan, I guess) substantiates the suspicion.
Well either Max is a liar or the screenwriters didn't understand what they were doing because Max tells Ethan that Job never used script to communicate (so the bible is not needed) and that that's how she new she was dealing with someone else (Ehtan did use bible quotes)