Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
bayhaqi:21747al-Shāfiʿī > ʿAbdullāh b. al-Ḥārith > Ibn Jurayj

[Machine] I said to Ata', a man died leaving behind two sons and some letters. The letters went to one of them, then he divided his inheritance according to what was written in the letters. After that, the man who had the letters died. Who will inherit him? He said, both of them will inherit him. Amr ibn Dinar said that Ata' changed his opinion and returned it to the one who wrote the letters. I repeated it to him and he said it more than once. Al-Shafi'i, may Allah have mercy on him, said the same as Ata' and Amr ibn Dinar, we say about the letters that the man writes them and then the master dies. Then the letters are fulfilled according to the writing, and he is freed by the writing. Verily, his loyalty is to the one who contracted the writing. The sheikh, may Allah have mercy on him, did not say about the division of the letters that it is permissible. He said, "Previously, the division is a sale, and the sale of the letters is not permissible."  

البيهقي:٢١٧٤٧وَبِإِسْنَادِهِ أَخْبَرَنَا الشَّافِعِيُّ أنبأ عَبْدُ اللهِ بْنُ الْحَارِثِ عَنِ ابْنِ جُرَيْجٍ قَالَ

قُلْتُ لِعَطَاءٍ رَجُلٌ تُوُفِّيَ وَتَرَكَ ابْنَيْنِ لَهُ وَتَرَكَ مُكَاتَبًا فَصَارَ الْمُكَاتَبُ لِأَحَدِهِمَا ثُمَّ قَضَى كِتَابَتَهُ لِلَّذِي صَارَ لَهُ فِي الْمِيرَاثِ ثُمَّ مَاتَ الْمُكَاتَبُ مَنْ يَرِثُهُ؟ قَالَ يَرِثَانِهِ جَمِيعًا وَقَالَهَا عَمْرُو بْنُ دِينَارٍ قَالَ عَطَاءٌ رَجَعَ وَلَاؤُهُ إِلَى الَّذِي كَاتَبَهُ فَرَدَدْتُهَا عَلَيْهِ وَقَالَ ذَلِكَ غَيْرَ مَرَّةٍ قَالَ الشَّافِعِيُّ رَحِمَهُ اللهُ وَبِقَوْلِ عَطَاءٍ وَعَمْرِو بْنِ دِينَارٍ نَقُولُ فِي الْمُكَاتَبِ يُكَاتِبُهُ الرَّجُلُ ثُمَّ يَمُوتُ السَّيِّدُ ثُمَّ يُؤَدِّي الْمُكَاتَبُ فَيُعْتَقُ بِالْكِتَابَةِ إِنَّ وَلَاءَهُ لِلَّذِي عَقَدَ كِتَابَتَهُ قَالَ الشَّيْخُ رَحِمَهُ اللهُ وَلَمْ يَقُلْ بِقَوْلِهِ فِي قِسْمَةِ الْمُكَاتَبِ قَالَ مِنْ قَبْلُ إِنَّ الْقَسْمَ بَيْعٌ وَبَيْعُ الْمُكَاتَبِ لَا يَجُوزُ