As we said above (23:11), wine is considered the most important beverage. Not only does it cheer people up, it helps them relax and bond with each other. For this reason, the Torah commanded us to pour wine on the altar with offerings, allowing us to tap into its special power and to strengthen our attachment with God. This is also why the Sages required reciting a blessing over a cup of wine at every religious celebration, including Kiddush and Havdala on Shabbat and holidays. At the same time, this power is also dangerous. Intemperate people become addicted to it and do abominable things while drunk. Furthermore, idolaters poured wine in the service of their idols. Therefore, the Sages were very strict, decreeing that a Jew may not drink wine touched by an idolator, nor may anyone benefit from it. To make sure no one mistakenly benefits from such wine, it must be spilled out.
In our times, most non-Jews do not bow down to idols or offer them wine libations, so there is no concern their wine was used for idolatrous purposes. Nevertheless, the fear of assimilation is very real, so if wine was produced by a non-Jew, a Jew may not drink it. However, a Jew may benefit from it. Similarly, if a Jew prepared wine, but a non-Jew touched it or drank from it, a Jew may not drink it, but may derive benefit from it. If a non-Jew did not touch the wine itself, but simply opened the bottle, the wine is permissible. If he poured the wine from the bottle into a glass, some permit it and some forbid it. After the fact, since the non-Jew is not an idol worshiper, we may be lenient. Nevertheless, we do not hire non-Jews to pour wine, both because they might end up touching it, and because all else being equal, it is preferable to follow the stringent position.
Pasteurized or cooked wine is not included in the prohibition, since such wine would not have been offered to an idol. Some are stringent even in such a case. But if being stringent is likely to offend, one should be lenient.