A former soldier tried to meet a 13-year-old girl for sex after he was lured into a trap by paedophile hunters.
Gareth Walters, 38, from Gateshead, sent explicit messages to his victim on the social media site, Badoo.
However, while he thought he was talking to a teenager – in fact he was contacting a fake profile set up by vigilante group, Dark Justice.
After a series of messages, where he asked for naked pictures, he arranged to meet the girl in Newcastle city centre.
But when he turned up, he was met by members of Dark Justice armed with a camera.
Walters, who had been drinking, sprinted away but was later arrested at home.
He told officers he had only planned to warn the underage teen about internet dangers.
Prosecutor Tom Moran told Newcastle Crown Court: ‘He said he would have told her how dangerous it could be to meet someone.’
The court heard Walters had asked the girl if she ‘wanted some fun’, talked about sexual activities and asked her for photographs with ‘fewer clothes on’.
When his case got to court he and another man, also snared by Dark Justice, launched a landmark legal battle to stop investigations by the unofficial paedophile hunters.
Their defence teams claimed the activities of Dark Justice ‘diminished the integrity of the court process’ and said evidence gathered by them should not be permitted in court.
If the legal battle had succeeded, similar cases across the country would have collapsed.
But in a detailed ruling, Mr Justice Langstaff said there was no legal requirement for such groups to be controlled and said their evidence could continue to be used in court cases.
Walters pleaded guilty to attempting to incite a child to engage in sexual activity.
given a 21 month jail term at a court martial in 2013 for wounding and deserting.
Judge Tim Gittins sentenced Walters to 21 months imprisonment, suspended for two years, with programme requirements.
Walters was also ordered to sign the sex offenders register and abide by a sexual harm prevention order for seven years.
The judge told him: ‘A legal argument was raised on your behalf in relation to the method by which your offending was detected, recorded and reported by the self styled Dark Justice group.
‘The group purported to be a girl and told you she was 13 and that she had lied to get a profile on that website.
‘That did not discourage you from inviting her for alcohol at yours and thereafter asking if she was interested in sex.
‘You said you were going to warn her about the dangers of online behaviour and meeting strangers.
‘You recognise, in fact, in your state, you were the danger to that young person, had there been such a young girl.’
The judge said Walters had served his country at a time when he had mental health difficulties and now needs help to control drinking and protect the public.
Walters has been assessed as posing a low risk of re offending.
Jamie Adams, defending, said since his arrest her client had sought help and therapy for his ongoing issues, which has had a positive effect.