Fernando Alonso lifted Ferrari out of the doldrums with his 28th career victory at the end of a rain-hit Malaysian Grand Prix.
The Spaniard was pushed to the limit by Mexico's Sergio Perez, whose mistake on lap 50 arguably cost him a maiden race win for Sauber.
In a Ferrari that has so far been poor by the team's usual high standards, Alonso's win means he now leads the championship by five points from McLaren's Lewis Hamilton, who was forced to settle for third place after starting from pole for the second successive race.
Following a 50-minute delay after the race had been halted at the end of nine laps due to the wet conditions, it was Alonso who went on to master the elements at the Sepang International Circuit.
Perez, a member of Ferrari's young driver academy and linked with taking up the underperforming Felipe Massa's seat, claimed second place, collecting more points in this one race than he did throughout all of last season.