Sri Lanka had built a second-innings lead of 220 over Pakistan at the end of day four of the third Test in Sharjah.
The tourists, having dismissed Pakistan for 341 to secure a first-innings lead of 87, reached the close on 133 for five as they looked to put victory out of reach for their opponents.
Mahela Jayawardene top-scored with a patient 46 after two Abdur Rehman wickets had threatened to restrict their progress.
In the morning session, Pakistan captain Misbah-ul-Haq’s 63 kept his side in touch as they added 50 for the last four wickets before being bowled out for 341, Rangana Herath finishing with 5-125.
The designated hosts then had Sri Lanka, who lead the three-match series 1-0, one down before the first interval.
Dimuth Karunaratne edged the second ball of Sri Lanka’s second innings through the slips for four, but reached only eight before being bowled by Mohammad Talha via a bottom-edged pull.
Kumar Sangakkara also fell for eight, Rehman having him caught at deep midwicket by Khurram Manzoor off a top edge.
Rehman struck again to remove Kaushal Silva, who was bowled between bat and pad for 36 to leave Sri Lanka three down at tea.
Dinesh Chandimal saw his stumps sent sprawling by Talha for 13, while Jayawardene's stay at the crease ended when he inside-edged Saeed Ajmal to short-leg.