Hasan, 20, was declared as the best batsman in the National Twenty20 tournament which concluded in Lahore on Saturday, while Riaz, 25, was named the best bowler at the same event.
But neither had been included in the limited over squad when it was announced beforehand.
Pakistan play two Twenty20, five one-day and two Tests against South Africa starting on October 26. The series will be held in Abu Dhabi and Dubai.
Riaz is already part of the Test team announced earlier this month.
Pakistan's chief selector Mohsin Khan said both the players have been chosen after their extra-ordinary performance.
“Both Hasan and Riaz were outstanding in the Twenty20 national event so we recommended their names, which were approved by Pakistan Cricket Board chairman Ijaz Butt,” Khan told reporters.
Former Pakistan players, including Abdul Qadir, had criticised the naming of the team before the National Twenty20 event.
“Why the selectors announced the team before the Twenty20 event is hard to understand,” Qadir had said.