A unified QCD formulation of leptoproduction of massive quarks in charged current and neutral current processes is described. This involves adopting consistent factorization and renormalization schemes which encompass both vector-boson-gluon-fusion (flavor creation) and vector-boson-massive-quark-scattering (flavor excitation) production mechanisms. It provides a framework which is valid from the threshold for producing the massive quark (where gluon-fusion is dominant) to the very high energy regime when the typical energy scale mu is much larger than the quark mass m_Q (where the quark-scattering should be prevalent). This approach effectively resums all large logarithms of the type (alpha_s(mu) log(mu^2/m_Q^2)^n which limit the validity of existing fixed-order calculations to the region mu ~ O(m_Q). We show that the (massive) quark-scattering contribution (after subtraction of overlaps) is important in most parts of the (x, Q) plane except near the threshold region. We demonstrate that the factorization scale dependence of the structure functions calculated in this approach is substantially less than those obtained in the fixed-order calculations, as one would expect from a more consistent formulation.