Pakistan off-spinner Saeed Ajmal picked up two wickets in the last session to restrict Sri Lanka to 220 for five wickets at stumps on the first day of the third and final Test in Sharjah on Thursday.
The experienced slow bowler dismissed a well-set Mahela Jayawardene (47) with some extra spin and bounce and then baffled Dinesh Chandimal (11) with a doosra to reduce Sri Lanka to 166 for five at one stage.
Captain Angelo Mathews (24) and wicketkeeper Prasanna Jayawardene (28) held firm with an unbroken sixth-wicket stand of 54 runs to deny Pakistan any further success.
Ajmal was confident he had Prasanna out leg before and the umpire agreed too but the batsman reviewed the decision successfully as replays showed the ball was bouncing over the stumps.
Faced with some accurate bowling from Pakistan, Sri Lanka found scoring difficult on a slow and low pitch at the Sharjah stadium after Mathews opted to bat after winning the toss.
Mohammad Talha, playing only his second Test, struck early to get rid of Kaushal Silva (17) while left-arm spinner Abdur Rehman dismissed Dimuth Karunaratne (34) immediately after lunch.
Kumar Sangakkara (52) added 60 for the third wicket with Mahela to steady Sri Lanka's ship but hit paceman Junaid Khan tamely to mid-wicket after completing his 44th Test fifty.
Sangakkara, on 15, was lucky to survive an appeal for a catch after replays showed that he had gloved a sweep shot off Rehman. Pakistan opted not to challenge the umpire's not out verdict.
Mahela looked in good control against the spinners before failing to negotiate a ball from Ajmal which turned and bounced sharply to take the edge and reach Azhar Ali at short leg.
Sri Lanka, who lead the three Test series 1-0, would have been in more trouble if Talha had managed to hold on to a return catch off Mathews with the batsman yet to open his account.
Two wickets from Saeed Ajmal in the final session ensured both teams shared the honours on the first day of the third Test at the Sharjah Cricket Stadium.
Winning the toss and opting to bat first, Sri Lankan batsmen made good starts but could not carry on to make big scores as they posted 220 for five in 90 overs.
Kumar Sangakkara top scored with 52 while Mahela Jayawardene missed his half century for 47.
Angelo Mathews (24) and Prasanna Jayawardene (28) shared an unbroken 54 runs.
Junaid Khan, Mohammad Talha and Abdur Rehman took a wicket each for Pakistan.
Mathews and Jayawardene share a half century partnership. SL 219-5 in 88.2 overs
A crucial partnership building on between Mathews and Jayawardene. SL 200-5 in 80 overs.
Sri Lanka are 196 for 5 in 77 overs.
Two new batsmen in the middle. Huge pressure on Prasanna Jayawardene and Angelo Mathews. SL 180-5 in 70 overs.
Ajmal takes another as Sri Lanka suddenly look to be dropping from a good position. Chandimal offers an easy catch to Asad Shaifq. SL 166-5 in 65.2 overs.
D Chandimal c Asad Shafiq b Saeed Ajmal 11 (42b 1x4 0x6)
Ajmal gets his first wicket and an important one. Jayawardene misses his half century by three runs. SL 159-4 in 62 overs.
M Jayawardene c Azhar Ali b Saeed Ajmal 47 (108b 5x4 2x6)
Two successive boundaries from Jayawardene and Sri Lanka reach 150. SL 150-3 in 59 overs.
Sri Lanka are 133 for three in 57 overs at tea. Pakistan picked two wickets in the session including the wicket of Kumar Sangakkara who was well settled after scoring a half century.
Mahela Jaywardene is batting on 24.
A boundary gives Sangakkara his half century but he is out immediately after offers a simple catch to Manzoor. SL 125-3 in 50.5 overs.
K Sangakkara c Khurram Manzoor b Junaid Khan 52 (103b 5x4 0x6)
Sri Lanka 121 for 2 in 50 overs.
Jayawardene and Sangakkara share a partnership of 50. Sangakkara batting on 43. SL 115-2 in 48.4 overs.
Sri Lanka cross 100. Sangakkara is on 33, while Jayawardene batting on 14. SL 101-2 in 39 overs.
A great spell from Abdur Rehman. His bowling reads 6-3-6-1. Two experienced batsmen Jayawardene and Sangakarra countering him. SL 77-2 in 34 overs.
Success for Pakistan immediately after lunch. Well bowled by Rehman as karunaratne departs. SL 65-1 in 27.2 overs.
D Karunaratne c Younis Khan b Abdur Rehman 34 (93b 2x4 1x6)
It's been a quiet opening session of the third Test at the Sharjah Cricket stadium as Sri Lanka scored 64-1 in 27 overs at lunch.
Pakistan removed Kaushal Silva but the other opener Karunaratne has been going strong batting on 34. Sangakkara is on 12.
Karunaratne on 34 while Sangakkara bats on 11. The duo share a partnership of 32 runs. SL 63-1 in 26 overs.
Sangakkara in as Sri Lanka reach 50 for 1 in 20 overs.
A very late decision from umpire Kettleborough after Silva edges a Talha delivery to the keeper. Pak 31-1 in 15 overs.
K Silva c Sarfraz Ahmed b Mohammad Talha 17 (46b 1x4 0x6)
Pakistan lose a review after Ajmal felt he had trapped Karunaratne. SL 31-0 in 13.1 overs.
Only six runs in the last five overs. Sri Lanka openers are settling in there. SL 18-0 in 10 overs.
Sri Lanka taking a cautious approach. Pakistan bowlers not making much of an early impact. SL 12-0 in 5 overs.
Silva opens account with a boundary. SL 5-0 in 2 overs.
Karunaratne and Silva open for Sri Lanka. Junaid bowls for Pakistan.
Sri Lanka have won the toss and elected to bat first in the third Test against Pakistan at Sharjah Cricket Stadium on Thursday.
Dilruwan Perera has been handed a debut by Sri Lanka replacing Nuwan Pradeep.
Pakistan have made three changes with Azhar Ali, Mohammad Talha and Abdur Rehman coming in for Hafeez, Rahat Ali and the injured Bhatti.
Sri Lanka lead the series 1-0 and Pakistan are in danger of losing their first Test series in UAE since 2009.
Pakistan: Khurram Manzoor, Ahmed Shehzad, Azhar Ali, Younis Khan, Misbah-ul-Haq, Asad Shafiq, Sarfraz Ahmed, Saeed Ajmal, Junaid Khan, Abdur Rehman, Mohammad Talha.
Sri Lanka: Dimuth Karunaratne, Kaushal Silva, Kumar Sangakkara, Mahela Jayawardene, Dinesh Chandimal, Angelo Mathews, Prasanna Jayawardene, Dilruwan Perera, Rangana Herath, Shaminda Eranga, Suranga Lakmal