Involved in the biosynthesis of the iron-molybdenum cofactor (FeMo-co or M-cluster) found in the dinitrogenase enzyme of the nitrogenase complex in nitrogen-fixing microorganisms. NifB catalyzes the crucial step of radical SAM-dependent carbide insertion that occurs concomitant with the insertion of a 9th sulfur and the rearrangement/coupling of two [4Fe-4S] clusters into a [8Fe-9S-C] cluster, the precursor to the M-cluster