Bismillah ar-Rahmaan ar-Raheem
All Praise is for Allaah, the Lord of all creation, and may He extol and send blessings of peace upon our
Prophet Muhammad who delivered the clear message, and upon his true followers, his Companions, and those who follow them upon good until the Day of Requital.
Then many people are ignorant about many of the rulings concerning the Sujoodus-Sahw (prostration for forgetfulness) in the prayer.
Some of them leave the Sujoodus-Sahw when it is obligatory upon them; others perform the prostration in other than its correct place; some perform it before the salaam (salutation at the end of the prayer) even in cases when’ it has to be performed after the salaam; others prostrate after the salaam even when it should be performed before it.
Therefore, it is very important to become aware of its rulings, especially for the Imaams whom the people follow in their prayers, and who have therefore taken on the responsibility of following that, which is correct and prescribed in their prayers, and of leading the Muslims upon that.
GIVING SALUTATIONS (Salaam) BEFORE COMPLETION OF THE PRAYER
Giving salutation before the completion of the Prayer is a case of addition in the Prayer. So whoever gives them salutation before the completion of the Prayer deliberately, then his prayer is nullified. If, however, it is done due to forgetfulness, and he does not remember this until after a long time then he should repeat his prayer again.
If he remembers a short time later, such as after two or three minutes, then he should complete his prayer and salutation, and then prostrate for forgetfulness, and then give salutation (again).