We discuss the eigenvalue problem for a perfectly conducting hollow cavity under a strict functional analytic point of view. We make use of a variant of the classical spectral theorem for compact selfadjoint operators and we pay extra attention on the null space of the Maxwell operator. We also discuss the corresponding inhomogeneous problem, where currents are present, even when they may depend on the fields.