Oregon State's Joe Burton shoots as California's Robert Thurman defends during the first half of an NCAA college basketball game in Berkeley, Calif., Thursday, Jan. 31, 2013. (AP Photo/George Nikitin)

Photo: George Nikitin, Associated Press

Oregon State's Joe Burton shoots as California's Robert Thurman...

Image 2 of 3

Oregon State's Jarmal Reid (32) shoots as California's David Kravish, right, defends during the first half of an NCAA college basketball game in Berkeley, Calif., Thursday, Jan. 31, 2013. In the foreground is California's Tyrone Wallace. (AP Photo/George Nikitin)

Photo: George Nikitin, Associated Press

Oregon State's Jarmal Reid (32) shoots as California's David...

Image 3 of 3

Robert Thurman (No. 34) hammers home the dunk in front of Cal teammate Richard Solomon.

After trailing by 12 points in the second half, Cal rallied in the final 15 minutes for a rousing 71-68 victory over Oregon State on Thursday night at Haas Pavilion.

Head coach Mike Montgomery's 100th win for Cal was not assured until the final buzzer.

With 17 seconds left, Richard Solomon threw down a dunk for the game's final points, followed at 0:07 by Robert Thurman's block on Devon Collier's inside shot.

After the block, the Beavers retained possession but were unable to get off a shot before the horn sounded. It was a riveting victory for the Bears (12-8, 4-4 Pac-12).

"It's a big win; you see how excited we were," said point guard Justin Cobbs, who scored 14 points, none bigger than his three-point shot at 2:51 that gave Cal a 67-66 edge. "At the same time, we have to win at home. I'm proud of our guys."

Allen Crabbe had 15 points to lead Cal but scored only four in the second half.

The game turned for Cal when Oregon State went up 51-40 with 15:49 to play. Montgomery called timeout to put things in perspective for his team.

"Coach really let us have it," Thurman said. "We really needed it. He told us we need to get our act together, that the way we were playing at the time, there was no way we were going to come back."

Asked about the pivotal timeout, Montgomery said, "We had a discussion. They seemed to react well. We were just getting our butts kicked. I explained it in no uncertain terms."

After Nelson dropped in a free throw for 52-40 coming out of the timeout, the Bears hustled, defended and scored their way into a 20-7 run over the next nine minutes, culminating in a short jumper by Cobbs that put them up 60-59.

Oregon State head coach Craig Robinson took the blame for his team not getting off a shot in the final seven seconds, saying, "I should have called a timeout, but we had a play called when they scored. I didn't want them to set up their defense. ... Just inexcusable."

The win was notable in that Cal, the home team, attempted (and made) only two free throws, both of them by Crabbe.

"Generally speaking, that's pretty unusual," Montgomery said. "We were not taking it to the basket."

Cal's players went to the student section after the emotional win and high-fived their fans. At least one player was unaware that they had given Montgomery his 100th win at Berkeley.

"To be honest, I had no idea, but congratulations, Coach," Cobbs said.

Powers injured: Cal guard Jeff Powers injured his left knee late in the first half and did not return. He's not expected to play Saturday afternoon against Oregon.