Nikolai Khabibulin made 26 saves for the Oilers, who snapped a two-game skid.
Fernando Pisani lit the lamp for the Blackhawks, who have lost three of four. Chicago forward Marian Hossa was back in the lineup for the first time in six games after suffering an upper-body injury versus the Kings on October 27.
Corey Crawford turned aside 24-of-26 shots in defeat.
Chicago drew first blood at the 10:22 mark of the first period. Jack Skille stole the puck away from two Edmonton players behind the net. Pisani took a pass from Skille at the right circle and fired a shot past Khabibulin.
Crawford, who made nine saves in the first, turned aside eight shots in the second. Khabibulin also made eight saves during a scoreless second stanza.
Foster’s power-play goal at the 7:13 mark of the third made it a 1-1 game. His slap shot from along the right boards snuck past Crawford.
Gagner gave the Oilers a 2-1 edge just 14 seconds later. Dustin Penner fired a shot on net from the left circle. Gagner, positioned at the right side of the net, chipped the disc into the back of the net.
Khabibulin made nine saves in the third to preserve the victory.
Edmonton forwards Steve McIntyre (back), Theo Peckham (flu-like symptoms), and Jean-Francois Jacques (back surgery) missed the game…The Oilers started a five-game road trip on Sunday…Edmonton snapped a four-game skid to Chicago with a 7-4 win in Chicago on October 29.