PALLEKELE, Sri Lanka (AP) — Opener Dimuth Karunarane was the only batsman to handle Pakistan legspinner Yasir Shah as he notched his second century in leading Sri Lanka to 272-8 at stumps on the first day of the third test on Friday.

Karunaratne saw off a difficult period in the morning when Pakistan's seamers had lot of help from the pitch. After opener Kaushal Silva fell with the total on 15, he added 91 runs for the second wicket with Upul Tharanga. The left-hander met Yasir confidently, but he was the only one on his team.

Karunaratne reached three figures off 188 deliveries when he pushed a full delivery from Azhar Ali to mid-wicket for two runs, and became the first Sri Lankan to score a century at Pallekele.

He was eventually stumped for 130, having batted for nearly six hours. He faced 230 deliveries, and hit 14 boundaries.

"When the series stared, I wanted to be the highest run-scorer in the series," Karunaratne said. "I have got lot of confidence after the New Zealand tour (at the start of the year). I was struggling to get past 30 and 40, but now I know how to build up an innings, and since the seniors are also not there, I need to show more responsibility.

"I saw the wicket and it was a bit tough. So I told myself to bat through the first session. I was very choosy about which ball to put away. That was the key for me."

Yasir continued his torment of the Sri Lankan batsmen. The hosts were well placed at 85-1 when they resumed after lunch, but the batsmen were overcautious against Yasir and, as the pressure started building, they attempted a few ambitious strokes and lost the plot.

Yasir has 21 wickets so far in the series, the most by a Pakistani against Sri Lanka in a series. Offspinner Saeed Ajmal set the previous mark of 18 in 2011 in the United Arab Emirates.

"He doesn't give too many loose balls," Karunaratne said of Yasir. "He has got a flipper, a googly, and the legspin. That's why he has taken so many wickets.

"I just wanted to be positive against him. The key is to use the feet. When you do that, you can rotate the strike."

Karunaratne's and Tharanga's long partnership for the second wicket was ended when Tharanga, on 46, tried to drive Yasir and edged to Younis Khan at first slip.

The slide accelerated when Yasir dismissed Lahiru Thirimanne for 11 and Angelo Mathews for 3 in successive overs in identical fashion. Both batsmen charged down the wicket to the spinner, but got the placement wrong as substitute fielder Babar Azam took catches at mid-off and mid-on respectively.

Jehan Mubarak, playing his first test after eight years, added 67 runs with Karunaratne before being stumped for 25 off Yasir.

Part-timer Azhar dismissed Karunaratne and Dhammika Prasad in successive deliveries, and the second new ball accounted for Dinesh Chandimal on 24.

Yasir finished the day with 4-77 from 31 overs. He earned nine wickets in the first test, and eight in the second, and made Pakistan's decision at the toss to have Sri Lanka bat, work out well.