The U.S. Department of Justice issued long-awaited guidance Friday to clarify the hazy legal landscape over when financial institutions risk prosecution for providing services to marijuana-related businesses.

In a memo to U.S. attorneys, Deputy Attorney General James Cole said banks can handle the proceeds of drug sales from licensed marijuana businesses that follow the regulatory and enforcement systems in Colorado and Washington, the two states that legalized the drug last year.