ALBANY — Gov. Andrew Cuomo signed into law Tuesday a bill banning the manufacture and possession of knives that fail to set off metal detectors.

“Undetectable knives are meant to be used by trained members of our police and military forces for covert operations — not regular civilians attempting to sneak weapons past metal detectors,” Cuomo said.

The weapons, some strong enough to pierce a steel drum or car door, are made with materials like carbon fiber, titanium and ceramic that can pass undetected through security systems.

“By signing this measure into law, we will keep these deadly knives out of dangerous hands and help ensure our airports, courtrooms and other public buildings are safe.”

The law, which takes effect Nov. 1, makes possession a Class A misdemeanor punishable by up to a year in jail.

Only military members and police officers are exempt.

“We know firsthand how the possession of a seemingly innocuous tool was used to hijack three planes and take thousands of lives,” the law’s sponsors, state Sen. Diane Savino (D-Staten Island/Brooklyn) and Assemblyman William Colton (D-Brooklyn) argued in their bill memo, noting the terrorists during the 9/11 attacks who carried box cutters.

Last week, Cuomo signed a similar measure banning guns that make it through metal detectors unnoticed.