In the cold Wisconsin winter we often see condensation behind fiberglass batt insulation on the rim joist. This is due to basement or crawlspace water vapor reaching the cold surface behind the fiberglass. Sometimes it has been chronic enough to cause mold.
Two-part SPF is a great way to eliminate it from happening. Okay, so what are your thoughts on spray foaming over the mold? Let's also assume it's middle of winter and the sawn lumber rim joist is noticeably wet behind the F.G. How important do you think it is to dry out the surface some first?
I've seen it done and intuitively I think it should work fine. Any mold is encapsulated and the material can dry to the outside when it warms up.
I would scrape the black film and wipe up the moisture at a minimum. Why make the dry to the outside work harder? Why leave a thicker slimy film, or moisture film and attempt to make the SPF adhere to it.
Remove the FG -- heat the area for 24 - 48hours and remove moisture. Then see about the black. Then SPF. Heat to a good temp will also help do the SPF correctly.
Closed Cell I hope - beyond that, most manufacturers I know have specs for the temperature / moisture the surface being sprayed should be (not just the chemicals)
Many believe the isothermic reaction is enough to kill off mold cells but like John mentions I would scrape it all off after making sure everything is dried out.
I'm not really concerned about the isothermic or other reaction killing spores, that is just a nice side effect. The fungal growth needs water, food (wood) and spores. Just like a fire needs heat fuel and air. Remove one and the reaction stops. In this case eliminate the water. Same as you should be doing anytime you get a fungal growth.
My main concern is having reasonably clean substrates for stuff to adhere to. Like gluing a wood joint, the SPF has to adhere to something. How clean? Not clean like an operating room, or clean like the food prep counter in the kitchen. Clean like your plate after you've eaten everything on it.
Try the easy things first; lower the humidity to attempt to lower the dew point at the rim, and maybe that will solve the problem. If not: I have developed an aversion to spray foam for various reasons, mainly the chemicals, since we already have too many of them in most of our homes. So, my take would be to remove the FG, LET THE RIM DRY; forcing it to dry to the "outside" may force the moisture upward as well into the wall cavity, or the inside wall surface, then install rigid insulation with the R-value determined based on what's needed to prevent condensation at he design temps and the HUMIDITY LEVEL in the bsmt, (dew point app), and seal all edges with a "better" grade of caulk. That is the design I use for my home, and we should treat every one as our own.
A putty knife or drywall blade would work. Nothing aggressive like a paint scraper. You have to get back in there. So you might be using some type of handle extension.