All those people who faith in sanatan dharma believes lord hanuman to be the troubleshooter and Shani deva is the god that punishes the wrong.
Father of Shanidev, surya dev, is the teacher of lord hanuman. He has a fight with his own father, but surya dev has given a lot of his powers to lord hanuman and made him Mahavir. Sharanya be a cruel and unforgiving nature. Hanuman had the rare blessings from him. As everybody knows, Ravana had won trilok and got a Var to be almost immortal. So Ravana had won all the nine planets also. Ravana had become invisible because of shiv and Brahma’s boons. Ravana was a great astrologer. When ravana’s son Meghnath was born, Ravana placed all the planets in his eleventh house so that so that he could also be invincible and immortal. Devtas were very afraid of this and looked at Shani. So he stretched his leg a little bit from raavan’s clutches towards his twelth house. Ravana knew that this will cause meghnath’s, so he imprisoned Shani in a dark tiny cell so that nobody could see shani’s face again.
After some time when hanuman was searching for Sita, he heard shani’s cries from a deep place then he found Shani imprisoned in a cell. He requested hanuman to free him then hanuman freed him. Shani looked at him and thus hanuman became the victim of shani’s gazed. Shani promised hanuman that those who would pray him on Saturday would be rescued from the painful effects of Shani. When hanuman was burning lanka, he found that he was not able to burn it properly. Then as he promised to hanuman to help him in degrading Ravana, he looked at lanka and turned into it black instead of a heap of gold.
It is the divine scheme of things and no one can escape from it. Hanuman wanted to know that sufferings he will have to face. Shani explained that I will come upon your head, will make you leave your home, wife and sons from suffering. Hanuman said that Shani can definitely come upon his head and he has no family he will not suffer much with regard to his family he was assured that the feet of lord ram would be able to tolerate that suffering also. So Shani took refuge on hanuman’s head and began to fight the demons that chased him lanka. In the process hanuman had to carry trees and rocks on his head. Shani was getting hurt and suffering in the process and started bleeding.
Finally, Shanidev got away from hanuman’s head and said that you are the only one who will have no effect on my inauspiciousness. I cannot trouble you. Since you have saved me from raavan’s prison I would like to give you a boon. As the boon, hanuman asked him not to trouble or cast evil eye on his devotees. Lord Shani not to trouble or cause hardships to Mahavir devotees. When he became free, he asked hanuman give me some oil to reliefs my wretched pain. Then Mahavir gave him some mustard oil and after the massage of that oil to Shani on his body, his pain was relieved immediately. Since then has been offer some mustard oil in the name of sharanya. It is symboling to sooth his pain. He feels satisfied who worship hanuman on Saturday is not affected by shani’s dosh.