The direct product of two-dimensional anti-de Sitter spacetime with a two-sphere is an exact solution of four-dimensional Einstein-Maxwell theory without a cosmological constant. In this paper, we analytically solve the coupled gravitational and electromagnetic perturbation equations of $AdS_2times S^2$ in Einstein-Maxwell theory. On the other hand, $AdS_2times S^2$ also describes the near-horizon region of the extreme Reissner-Nordstrom (ERN) black hole. We therefore also solve the connection problem: we show how the $AdS_2times S^2$ perturbation equations arise from an appropriate near-horizon approximation of the corresponding equations for the ERN and then, using matched asymptotic expansions, we analytically extend the $AdS_2times S^2$ solutions away from the near-horizon region connecting them with solutions in the far asymptotically flat region. From the point of view of ERN our results may be thought of as computing the classical scattering matrix for gravitational and electromagnetic waves which probe the near-horizon region of the black hole.