Department of Homeland Security John Kelly on Tuesday took a tough line on marijuana by saying it can lead people to use harder drugs, after downplaying the importance of marijuana in the drug war just days earlier.

"And let me be clear about marijuana. It is a potentially dangerous gateway drug that frequently leads to the use of harder drugs," Kelly said Tuesday in a speech at the George Washington University Center for Cyber and Homeland Security.

Kelly added that DHS will continue to "investigate marijuana's illegal pathways along the network into the U.S., its distribution within the homeland, and will arrest those involved in the drug trade according to federal law."

That's a tougher stance compared to what he said on NBC Sunday, when Kelly was asked whether legalizing marijuana would help or hurt his fight in stopping the flow of illegal drugs into the United States from Central America and Mexico.

"Yeah, marijuana is not a factor in the drug war," Kelly responded. "It's three things. Methamphetamine. Almost all produced in Mexico. Heroin. Virtually all produced in Mexico. And cocaine that comes up from further south."

Kelly said the solution to fighting drug use in America is "not arresting a lot of users" but rather a "comprehensive drug demand reduction program."

Marijuana is still illegal under federal law, though 26 states and the District of Columbia have laws legalizing the drug in some form.

Attorney General Jeff Sessions has signaled the Justice Department will crack down on marijuana. Sessions has appointed a task force to review "existing policies in the areas of charging, sentencing and marijuana and to "ensure consistency" the Trump administration's broader goals and priorities of boosting public safety.

White House press secretary Sean Spicer has also said separately to expect "greater enforcement" of federal marijuana laws.