Depends on the foam and the finish used (if you don't want to take the paint off)
If using a water based glue then use a damp paper towel or similar.
Whatever solvent is in the glue is what you use. For Epoxy use denatured alcohol (and get it before the epoxy starts to stiffen)
For general cleaning of the models I use foaming bathroom cleaner... after testing on scrap foam... since the bubbling action can lift dirt out of the little crevices between beads of EPO or EPS. I haven't had much luck cleaning EPP.
Water eventually dissolves CA... it can take a very long time though.
If its normal CA and that didn't eat the foam then you are may be dealing with EPO If so, carefully flex the area (to avoid permanent deformation) and the CA will pop off. EPO is the next best thing to Teflon. Nothing really bonds to it. Some glues stick well enough to fly but you can disassemble it every time.
I use Rubbing Alcohol on Depron to remove the Release agent that is on the foam so glue, paint and stickers will attach to it, test on other foams, test a CA de bonder on foam to see if it wont desolve it. Take care, Chellie
I may be getting Older, But I Refuse to grow Up I am Having to much Fun to Grow Up LOL
You could try testing a small, inconspicuous area with Testors enamel or airbrush thinner to see how it behaves.. A relatively fast wipe done without soaking the foam has worked for me, without eating foam.