Microscopic origin of local moments in a zinc-doped high- T c superconductor