An "exceptionally dangerous" convicted rapist sexually assaulted a five-year-old girl as he travelled home from prison, police have said.
Darren Rothwell left HMP Forest Bank in Salford on 18 April and was on a train when he attacked the girl, who was with her mother, after asking for a hug.
The 42-year-old was jailed for 26 months at Bolton Crown Court on Friday.
British Transport Police (BTP) said he had shown "absolutely no desire to rehabilitate himself".
A BTP spokeswoman said Rothwell, of Scholes, Wigan, had been swearing aggressively, drinking brandy from the bottle and bragging about being released from prison on the train, which left the girl, her mother and their friends feeling "intimated".
He told the group he was on his way to see an ex-partner who had a restraining order against him and that he would be back in prison within two days, before making "uncomfortable comments" and asking the girl to take her top off and give it to him.
He then said he had a 2009 conviction for rape, sexual activity with a child and child abduction, telling them to do an online search to find more information about him.
The BTP spokeswoman said as the train approached Wigan, he asked the five-year-old for a hug and "went to pick her up, before sexually assaulting her in view of her horrified mum".
The girl's mother reported what happened to BTP and following an investigation, Rothwell was arrested on 20 April and returned to prison two days later after being charged.
Speaking after sentencing, Det Con Ian Grice said Rothwell was "clearly an exceptionally dangerous individual".
"Rothwell clearly had absolutely no desire to rehabilitate himself after prison, but to sexually assault a 5-year-old child before he'd even made it home is beyond reprehensible."