At lunch on the fourth day, the visitors were 199-7, requiring another 66 runs to win with only three wickets remaining.
Glenn Maxwell was batting on 14 with Pat Cummins on two at the break.
Bangladesh, who set Steve Smith's men a target of 265, have never won in their five previous outings against Australia since gaining Test status in 2000.
Left-arm spinner Shakib brought Bangladesh back into the game with his triple strike after Warner hit 112 off 135 balls with the help of 16 fours and a six.
More From This Section
Australia appeared to be coasting towards their fifth consecutive win against Bangladesh when Warner and Smith resumed on 109 for two.
Warner, who was unbeaten on 75 overnight, reached the three-figure mark off 121 balls with a double off Taijul.
Shakib then trapped Warner leg before to give Bangladesh the first breakthrough of the day.
It also ended Warner's 130-run partnership with Smith, who was dropped by Tamim Iqbal on 29 at mid on. But he failed to make most of the reprieve, edging Shakib behind the wicket for 37.