The Firefox web browser has been patched for security flaws, four of which were identified as "critical" by Mozilla.