They would go to a 1 game playoff, like the M's did a number of years ago. Now, I can't tell you what would happen if it was a 3-way tie.
But, the Sox are going to win both games so it won't matter.

Or more appropriately, the Yankees are going to LOSE, I don't care who wins. I just REALLY want the Yankees to lose.