All perfect praise be to Allah the Lord of The Worlds. May His peace and blessings be upon our Prophet Mohammad and upon all his family and companions.
With regard to inserting the finger into the anus, this is forbidden for two reasons:
1- The anus is the site of uncleanliness (Najaasah) and faeces, and, in principle, a Muslim must avoid such sites.
Al-Shirbini says: "It is forbidden to marinate in najaasah." {Moghni Al-Mohtaaj,vol.1/pp.194}. This was also stated in {Nehayat Al-Mohtaaj, vol.1/pp.185}. Late Shafie scholars who wrote footnotes on [Al-Menhaaj] have restricted this prohibition to cases in which such an act (marinating in najaasah) is committed unnecessarily. It was stated in the book [Boghyat Al-Mostarshideen, pp.33]: "It is forbidden to marinate in najasaah for no need and it must be washed off instantly. However, this is permissible in case of Istinja` (It is the Arabic term for cleaning away whatever has been passed from the urethra or anus with clean water), washing off najaasah, using it as fertilizer or for treatment when there is no pure alternative.
2- Inserting the finger in the wife`s anus causes serious diseases, such as hemorrhoids.
Maliki scholars-as stated in "Hasheyat Al-Adawi (vol.1/pp.175): "It is forbidden to insert the finger into the back passage of males and females. Hanafi scholars have also stated-as in [Baryqah Mahmoodiah, vol.1/pp. 84]: "The same thing excluding Istinjaa` for other than this is considered from the sins of the hand. And Allah the Almighty Knows Best.