One soldier was killed during one of the raids, the BBC reported.
The military "conducted two special operations supported by Nigerian Airforce helicopter gunship[s] to dislodge Boko Haram training camps" in the Ruwa forest and the Sambisa Game Reserve, said Lt. Col. Sagir Musa said in a statement.
"The camp was properly ... fortified and had training facilities, an armory, accommodation, a drug store, kitchen, vehicle holding area, latrine and water points," Musa said.
Both operations were supported by the Nigerian Air Force, Leadership Newspapers reported.
Musa said: "Efforts by JTF troops to destroy the camps led to fierce exchange of fire that resulted in the death of 17 Boko Haram terrorists with one JTF personnel killed. The camps were destroyed and are being monitored."
Boko Haram did not comment on the report.