  Boundary-dependent radiative corrections that modify the magnetic moment of
an electron near a dielectric or conducting surface are investigated.
Normal-mode quantization of the electromagnetic field and perturbation theory
applied to the Dirac equation for a charged particle in a weak magnetic field
yields a general formula for the magnetic moment correction in terms of any
choice of electromagnetic mode functions. For two particular models, a
non-dispersive dielectric and an undamped plasma, it is shown that, by using
contour integration techniques over a complex wave vector, this can be
simplified to a formula featuring just integrals over TE and TM reflection
coefficients of the surface. Analysing the magnetic moment correction for
several models of surfaces, we obtain markedly different results from the
previously considered simplistic `perfect reflector' model, which is due to the
inclusion of physically important features of the surface like evanescent field
modes and dispersion in the material. Remarkably, for a general dispersive
dielectric surface, the magnetic moment correction of an electron nearby has a
peak whose position and height can be tuned by choice of material parameters.
