Which foam to use for temporary leak remediation?
Application of foam from the interior will not stop water from penetrating the compromised flashing seal. The water that does penetrate may very likely end up someplace you would rather not have it. That being said, it will probably be better than doing nothing, judging by your description of the leak and considering the weather that is headed your way. The retro-fit seal linked in the comment from @Jack should help once you can obtain roof access, and you do not need to remove the foam to utilize it.