The Proteas whittled out the Aussie lower order after the visitors came out after lunch on 374 for seven.
Dale Steyn nipped out Ryan Harris (19), while Robin Peterson bowled the dangerous Mitchell Johnson for 33.
Peter Siddle was the last man to fall, bowled by Steyn as the seamer returned figures of 4/78 from 29 overs.
Shaun Marsh top-scored with 148, his highest Test score, and Steven Smith made a 100. The pair shared a 233-run stand — the highest fifth-wicket partnership at the ground, passing South Africans Ashwell Prince and Herschelle Gibbs who put on 213 against Pakistan in Centurion in January 2007.