BOSTON (CBS) – Federal agents had been watching Usaamah Rahim for months and had him under 24 hour surveillance for the past few weeks.

So what does it take get on the FBI’s radar?

READ MORE: Arsenal Reportedly Make 'Strong Bid' For Revolution Goalkeeper Matt Turner

“Yeah I think if you’re talking about beheading police on social media that’s a good way to get on the list,” former federal prosecutor Brian Kelly says of the terror watchlist.

Usaamah Rahim had worked his way up to rare, 24/7 surveillance in recent weeks before he was shot dead by the officers he tried to stab in Roslindale on Tuesday.

Usaama Rahim was shot and killed by the Joint Terrorism Task Force in Roslindale, June 2, 2015. (WBZ-TV)

Usaamah Rahim was shot and killed by the Joint Terrorism Task Force in Roslindale, June 2, 2015. (WBZ-TV)

“If someone is put on a 24/7 watch that someone is in their view, extremely dangerous,” Kelly said.

Indeed, the Joint Terrorism Task Force has limited resources and a 24/7 watch means they felt pretty sure a violent strike from Rahim was imminent.

“It’s judgement that law enforcement has to exercise hopefully appropriately and use that information to protect the rest of us,” Kelly said.

The watchlist has its roots in 9/11, but has grown dramatically in recent years as investigators scour social media, snatch names off wiretaps and work sources worldwide.

READ MORE: Alvin Gaston Charged In Fitchburg Hit-And-Run That Left Young Mother Seriously Hurt

“They have a lot of different sources telling them different things and they have to vet that and see what’s credible, what isn’t,” Kelly said.

But most names on the list get only cursory attention as investigators sift and funnel the incoming info to target the biggest emerging threats.

“The scrutiny gets higher and higher and the person is presumably unaware of it,” Kelly said.

This is why the list is shrouded in secrecy; so targets don’t change course, cover tracks, or accelerate their evil plots.

“The more information they gather about particular people on the list, they can now focus on people who might actually pose a danger,” Kelly said.

And that’s clearly what police thought about Usaamah Rahim when they closed in Tuesday, even as authorities puzzled over why he’d tip his hand on social media.

“A lot of people let their guard down and think no one’s watching, but occasionally, law enforcement is,” Kelly said.

MORE NEWS: Man Accused Of Assaulting Transit Police Officer After Being Asked To Wear Mask

In a civil lawsuit filed last summer, the government estimated that more than 1.5 million names had been added to the terror watch list in the last five years.

Ken MacLeod