Masturbation is not forbidden in Islam. Adultery is (all the answered Hadiths/Quran reference point to Adultery).
Some scholars (like Imam Shafi) use the following Verses/Hadiths to say that it is haram:
And those who guard their chastity. Except from their wives or the captives and slaves that their right hands possess, - for them, they are free from blame. But whoever seeks beyond that, then those are the transgressors." [23:5-7]
And let those who find not the financial means for marriage keep themselves chaste, until Allah enriches them of His bounty.[24:33]
We were with the Prophet while we were young and had no wealth whatsoever. So Allah’s Messenger said, "O young people! Whoever among you can marry, should marry, because it helps him lower his gaze and guard his modesty, and whoever is not able to marry, should fast, as fasting diminishes his sexual power. [Bukhari:5066]
Tell the believing men to lower their gaze and protect their private parts. That is purer for them. Verily, Allah is all-aware of what they do. And tell the believing women to lower their gaze and protect their private parts. [24:30-31]
However, these do not speak of Masturbation but of sexual acts (Adultery) . This can be proven that if you are caught with a woman cuddling the Adultery rule does not apply unless there are four witnesses to an actual sexual penetration (between the male and female) as narrated by the prophet:
وروى مسلم (1498) عَنْ أَبِي هُرَيْرَةَ رضي الله عنه أَنَّ سَعْدَ بْنَ عُبَادَةَ رضي الله عنه قَالَ : يَا رَسُولَ اللَّهِ ، إِنْ وَجَدْتُ مَعَ امْرَأَتِي رَجُلًا أَؤُمْهِلُهُ حَتَّى آتِيَ بِأَرْبَعَةِ شُهَدَاءَ ؟ قَالَ : (نَعَمْ) .
Muslim narrated from Abu Hurirah, that Said Ben Obada Asked the prophet (when the Ayah for the witnesses came down), if I find my wife having intercourse with another man, I have to leave them until I get 4 witnesses to catch them in the act? The prophet answered Yes.
Unless someone can prove to you that Masturbation == Adultery, it is not forbidden in Islam. You can deduce it is forbidden by wild speculations, but not clear as day.