Sayyiduna Abdullah bin Mas'ud (may Allah be pleased with him) narrates: The Prophet Muhammad (peace and blessings be upon him) said: "Envy is permissible only towards two types of people: one is the person whom Allah has granted wealth and given him the ability to spend it in the path of truth; the other is the person whom Allah has granted wisdom, and he judges according to it and teaches it to others."