It is narrated from Sayyiduna Abdullah bin Umar (may Allah be pleased with them both) that he used to say: It is permissible for a man to have intercourse with a slave woman over whom he has complete authority; if he wishes, he may sell her, if he wishes, he may gift her, if he wishes, he may keep her, he may do whatever he wants.
Imam Malik (may Allah have mercy on him) said: If a person buys a slave woman on the condition that he will not sell her, or will not gift her, or any similar condition is stipulated, then it is not permissible to have intercourse with that slave woman, because when he does not have the authority to sell or gift her, then his ownership is not complete, and the requirements of ownership remain in the control of another, and such a sale is disliked.
Malik said regarding someone who buys a slave girl on the condition that he does not sell her, nor give her as a gift, or similar conditions: It is not appropriate for the buyer to have intercourse with her, because it is not permissible for him to sell her nor to give her as a gift. If he does not have ownership of these rights over her, then he does not possess complete ownership of her, because what he owns has been excepted for another’s hand. So when this condition is included, it is not valid, and it is a disliked sale.
Hadith Referenceموطا امام مالك رواية يحييٰ / كتاب البيوع / 1308