DALLAS -- A writer linked to the online hacking collective Anonymous has been sentenced to prison for threatening an FBI agent and two other federal counts in a closely watched case. Barrett Lancaster Brown, 33, was sentenced to five years in prison Thursday in federal court in Dallas. He will be given credit for the more than two years he's already served. Brown is often quoted on the workings of Anonymous. He came under federal investigation for posting a link to data stolen from the Austin-based defense contractor Stratfor. He later admitted to posting threats against an FBI agent, obstructing a search warrant and being an accessory to an unauthorized access of a protected computer.

After his sentencing, according to The Dallas Morning News, Brown released a statement that read in part: "The U.S. government decided today that because I did such a good job investigating the cyber-industrial complex, they’re now going to send me to investigate the prison-industrial complex. For the next 35 months, I’ll be provided with free food, clothes, and housing as I seek to expose wrongdoing by Bureau of Prisons officials and staff and otherwise report on news and culture in the world’s greatest prison system." Brown's case has been watched by free-speech advocates who have criticized his prosecution.

IN-DEPTH

SOCIAL

Allocution Statement of Journalist Barrett Brown, As Prepared & Read into Court Record http://t.co/VM1KuuH5Lx #FreeBB pic.twitter.com/RllIDx2WdU — The Sparrow Project (@sparrowmedia) January 22, 2015

— The Associated Press and NBC News staff