Probably a legend.
There is a documented case from the 19th century of a railroad worker who had a tamping rod(1/2inch diameter steel rod) driven through the bottom of his chin and out the top of his skull. He was expected to die, but after several weeks of good nursing care, he recovered from the wound. The story says his personality was drastically changed. He had been a crew supervisor but could no longer organize or plan for more than a few minutes at a time. He apparently became an Elwood P. Dowd type character, well liked or just tolerated, but a peaceful happy person.
Phineas Gage, probably the most famous brain injury. Before the injury, he was a pleasant, reliable guy but the injury made him kind of a bastard, although he eventually adapted fairly well.
Here is a case of a brain tumor apparently causing uncontrollable pedophilia, which disappeared on removal of the tumor. http://www.newscientist.com/article...-uncontrollable-paedophilia.html#.VELc5vnF-So
Human sexuality is probably the most complex of all human behaviors. It is nearly impossible to classify or judge someone by the things they don't do. I know a few men who I believe are homosexual. I have known them for more than 30 years and in that time, I don't believe they have ever had a relationship with another man. One never really knows. However, they all approach late middle age without ever forming a long term emotional partnership relationship with a woman. When I was in school, it was popular to label such friends as "Asexuals." An Asexual was a nice person who could have had sex within their circle of friends, but for some reason, never did.
There are plenty of apparently well adjusted heterosexuals who have a very low sex drive and simply don't pursue sex, even when they have an available, willing and perhaps eager partner. We see this all the time.
Imagine a pedophile who happens to have a low libido. If this sort of thing were combined with a consciousness of the risks of their desires, or even a repulsion or repression of it, it's not a great leap to imagine a brain injury victim exhibit a sudden predilection which was never seen before. The brain injury did not cause the pedophilia. It removed the inhibitions which kept it hidden.