Swearing by graves and shaykhs

Q: Many people here in Sudan swear by shaykhs and shrines. This may also happen inside the Shar‘y (Islamic legal) courts, because when the judge asks the defendant to swear on the Qur’an, they, without hesitation, make a false oath. However, if the judge asks them to swear by a shrine, they abstain from swearing and confess their guilt, believing that swearing by the shrine can cause harm, because in their view shrines can cause harm or benefit. What is the ruling on this act and is it permissible for a judge to ask someone to swear by a shaykh or a shrine? (Part No. 1; Page No. 357) One of the scholars even gave us a Fatwa that it is permissible to swear by a shrine instead of the Qur’an. He argued that it is permissible to do so to restore the right of a wronged person if necessity called for it. To what degree is this Fatwa correct?We hope that you will explain this with evidence, and may Allah reward you for your efforts in helping Muslims.

A: It is Haram (prohibited) to swear by a shrine or a shaykh. It is also unlawful for a judge to ask someone to swear by them, based on what is authentically reported from the Prophet (peace be upon him), who said, “Anyone who swears by other than Allah has committed Kufr (disbelief) or Shirk (associated others with Allah in His Divinity or in worship).” A lawful oath is to swear by Allah, or by His Beautiful Names or by His Attributes.May Allah grant us success. May peace and blessings be upon our Prophet Muhammad, his family, and Companions.