United Nations Security Council resolution
United Nations Security Council resolution 598 S/RES/0598 (1987), (UNSC resolution 598) adopted unanimously on 20 July 1987, after recalling Resolution 582 and 588, called for an immediate ceasefire between Iran and Iraq and the repatriation of prisoners of war, and for both sides to withdraw to the international border. The resolution requested Secretary-General Javier Pérez de Cuéllar to dispatch a team of observers to monitor the ceasefire while a permanent settlement was reached to end the conflict. 
As regards "neutral shipping and civil aircraft" in the region, the Resolution was enforced by the US Navy, the French Navy and the British Navy as well as other navies local to the Persian Gulf. In an interview on 4 October 1987 aboard the flagship of the US forces, USS La Salle, Rear Admiral Harold Bernsen said "Of course we talk with them (the other navies), and we cooperate, but we don't have a joint command, what I would call a combined or coordinated military operation."
The Resolution became effective on 8 August 1988, ending all combat operations between the two countries and the Iran–Iraq War. Khomeini had been quoted about his opinion on the ceasefire where he stated "Happy are those who have departed through martyrdom. Unhappy am I that I still survive.… Taking this decision is more deadly than drinking from a poisoned chalice. I submitted myself to Allah's will and took this drink for His satisfaction" after announcing that Iran had signed a ceasefire with Iraq, 20 July 1988.
After acceptance of Resolution 598.
Both Iran and Iraq had accepted Resolution 598 on 8 August 1988.
Both sides eventually withdrew to the international border in the coming weeks. Resolution 598 became effective on 8 August, ending all combat operations between the two countries. UN peacekeepers belonging to the UNIIMOG mission took the field, remaining on the Iran–Iraq border until 1991.
References.
 ;templatestyles src="Reflist/styles.css" / ;