An enzyme that catalyzes the transfer of a phosphate group to the 5'-terminal hydroxyl groups of DNA and RNA. EC 2.7.1.78.