We present a new theoretical approach to the study of second and third harmonic generation from metallic nanostructures and nanocavities filled with a nonlinear material, in the ultrashort pulse regime. We model the metal as a two-component medium, using the hydrodynamic model to describe free electrons, and Lorentz oscillators to account for core electron contributions to both the linear dielectric constant and to harmonic generation. The active nonlinear medium that may fill a metallic nanocavity, or be positioned between metallic layers in a stack, is also modeled using Lorentz oscillators and surface phenomena due to symmetry breaking are taken into account. We study the effects of incident TE- and TM-polarized fields and show that a simple re-examination of the basic equations reveals additional exploitable dynamical features of nonlinear frequency conversion in plasmonic nanostructures.