If you can’t arrest them, why not go to work for them? That’s what some local and federal law enforcement officers are doing in Colorado and Washington, the nation’s first two states to legalize commercial marijuana.

Trained in special weapons tactics, Craig Kloppenberg used his 30 years on SWAT teams arresting pot dealers to become a private consultant for pot producers in Colorado.

He and another ex-cop, Joel Smith, work together to help about a dozen suppliers stay within the confines of the new law.

“If you could make more money, give a better life to your family, why not?” Kloppenberg told CNBC. “I believe it's going to be very lucrative.”

Even former Drug Enforcement Administration (DEA) agents are cashing in on the new industry.

Paul Schmidt worked for the DEA for 23 years, investigating more than 100 illegal marijuana operations.

Now, the retired federal agent teaches seminars to medical marijuana dispensaries on doing business and not violating the law.

Another ex-DEA man, Patrick Moen, joined Privateer Holdings, a venture capital firm in Seattle focused on the cannabis industry, as managing director of compliance and senior counsel.

Even ex-military are getting into the business.

Ted Daniels used his Army training to establish a private security firm, Blue Line Protection Group, which guards growers and dispensary owners during their deliveries. His vice president of operations is Leo Pavlushkin, a former member of the Soviet military who attended sniper school in Russia.

“In the business we're in, there is a very high and volatile threat for us,” Pavlushkin told CNBC.

-Noel Brinkerhoff

To Learn More:

Career Switch: From Pot Busters to Pot Protectors (by Dina Gusovsky, CNBC)

How Former DEA Agents Became Pot Proponents (by Dina Gusovsky, CNBC)

Top DEA Agent Lands Job as Legal Advisor to Marijuana Investment Firm (by Noel Brinkerhoff and Danny Biederman, AllGov)