The blockchain may just be the perfect ally in Canada’s move towards responsible cannabis use.

The Government of Canada has plans to legalize non-medical marijuana by July 2018, under the Cannabis Act. According to the government of British Columbia (BC), they are given jurisdiction over how they will handle legislation in their province: “While the proposed Cannabis Act provides for the federal government to regulate commercial production, provinces and territories will have authority to regulate certain aspects like distribution, retail and a range of other matters – as they do for tobacco and liquor.”

In preparation for this, BC’s government sent out an open call for proposals on how the substance will be regulated within their territory. And in response, IBM published their proposal, stating the use of blockchain technology to audit cannabis, “from seed to sale.”

IBM says that putting cannabis up on a blockchain will allow complete traceability and visibility of legal sources, and optimize the supply chain. Detection of illegal sources can also help keep potentially unsafe sources out of the supply, “and if poor product does enter the system, the controls, methods and ability to quickly identify its’ path is in place.”

Although cannabis enthusiasts would see this as a big and joyful win, the Cannabis Act is an effort to take responsibility and regulate the substance to keep it out of reach from young people, ensure safety, as well as lower black market sales and collect taxes from it.

“The objectives of the Act are to prevent young persons from accessing cannabis, to protect public health and public safety by establishing strict product safety and product quality requirements and to deter criminal activity by imposing serious criminal penalties for those operating outside the legal framework. The Act is also intended to reduce the burden on the criminal justice system in relation to cannabis.”

Smoking and driving—just like drinking and driving, remains a big no-no. “The B.C. government’s goals are protecting young people, making health and safety a priority, keeping criminals out of cannabis, and keeping our roads safe,” BC Minister Mike Farnworth says.

In fact, the Canadian government is dedicating $161 million to tighten law enforcement and equip officers to detect, screen, and implement the law against drug-impaired driving. The budget also covers research, policy development, and public awareness campaigns against driving under the influence. A total of $274 million overall is being allocated to support the Cannabis Act.