The big question in this would be the USSR. In the event of war there's at least a moderate risk of Soviet intervention, which would be made easier if the Iranians were the ones to declare war. Iraq and the USSR were fairly close at this stage, so at least some military assistance is a given. An outright invasion of Iran is something that the Soviet Union would also consider (they did so in tandem with the UK during WWII), especially given presumed US support for the Iranians.
If the Soviets stayed out and Iran was victorious, that would absolutely shore up the reign of the Shah, particularly if the Shiite majority took control of the Iraqi government to some degree. It would rally the population around the Shah, temporarily appease the Ayatollahs, and make the so-called white revolution that much smoother. It would also massively increase tensions between Iran and the Arab world, as well as potentially accelerating the sectarian conflicts we all know and love today.
As for Vietnam, don't really know, though victory in this area (the oil rich middle east) might make it politically less painful to withdraw from Vietnam and Indochina generally.