The Wind God's eldest son born to a female monkey, Anjana, was crazy enough as a child to think that Sun was actually a fruit. He made a leap towards the sun to eat it. Now, Mr Sun saw this upstart monkey and asked Indra for help. Mr Indra - not known for too much valour anyway - hurled his weapon (Vajra) towards this leaping monkey and KO'ed him. Our friend's jaw - hanu - was badly swollen even after Indra withdrew his weapon (thanks to the Wind God's asphyxiating boycott of the world).
And he became famous as The One With The Jaw - Hanuman.
Being the Wind God's son, he is also known Pavanputra and Maruti (son of Marut, another name for Vaayu). Anjana's son makes him Anjaneya. His thunderous strength makes him Bajrangbali. And his box-office clout makes The Return of Hanuman.
He has forty names like these, which are reverentially recited by bachelors and wrestlers among others.
That a child could be as naughty as to make a beeline for the Sun was quite unprecedented. In honour of this feat, naughty children are called Hanuman even today. (At least in Bengali. Am not sure of other languages.)
You would think that a god's fist on the jaw would reform him but Hanuman was a different kettle of fish altogether.
First things first, he was invincible and he knew that any attempt to harm him would mean an immediate boycott of the universe by his dad. Life without air can be really suffocating and people suffered Hanuman's mischiefs silently.
His favourite trick was apparently to disrupt yagnas and use his superpowers to leap out of sight. One of the sages (I forget the name) devised a ploy to stop him. He gave him a curse to forget his superpowers.
Now, this was really ingenious. No harm came to Hanuman and therefore it remained out of radar for Pavan. Since Hanuman himself forgot that he is capable of wielding a mean mace and leaping long distances, he never attempted any mischief that needed any of the above to escape from. So he became a simple monkey and generally hung around Sugreev around the monkey kingdom of Kishkindhya.
To cut a long story short, Hanuman was soon standing in front of a raging sea with a bunch of monkeys and two humans called Ram and Laxman. They knew that Ram's wife was abducted to an island beyond the sea but they wanted somebody to hop across and confirm it. Hanuman was whistling around the beach when a learned monkey (probably, Jambuban) realised he had made a leap for the Sun as a kid and jumping across Palk Strait would be a cakewalk for him!
So, he started reminding Hanuman about his prowess and egged him to take what was a small step for monkey and a giant leap for mankind. Hanuman had blissfully forgotten what he was capable of and only when Jambuban played the Karz theme on his guitar, did he remember!
The rest, as they say, is history!
Curses by the sages have been put to good use quite a few times in the epics.
There were these two blokes by the name of Nal and Neel - in the Monkey Army. When they were kids, they had the habit of - well - monkeying around. They used to attack yagnas, pick up the holy implements and utensils and throw them in the nearby rivers. The exasperated sages had to stop this sinking feeling and cursed them that anything they threw in the river would not sink!
Now, when the Bridge Over the Sea had to be constructed, this curse came to use. The Monkey Army used to go all over the place, uproot trees, collect boulders and hand them to these guys. They used to stand at the edge of the sea and throw all the stuff into it. True to their curse, nothing sank and the bridge got made!
A parallel story says that Nal and Neel were foster sons of Lord Vishwakarma (The Celestial Engineer) and had special expertise in construction and civil engineering. But I like the curse angle better!
Anyway, to get back to Hanuman, people would know that he is one of the 5 Immortals in Hindu mythology (along with Ashwathama, Balaram and two more Unforgettables whom I have forgotten). He continued his good work even in Mahabharat.