The left arm pace bower, included in the Pak-bound India squad by the national selectors, added to his four-wicket first innings haul by taking all the Punjab second innings wickets to fall during the day with a shortened run-up.
At stumps Punjab, who conceded a first innings lead of 132 runs to Baroda, were tottering at 69 for five in the second, still needing 63 runs to make the home team bat for the second time in the match.
Zaheer had earlier in the day helped his captain Jacob Martin, who made an impressive 80 in the home team's first innings total of 262, add 57 runs for the last wicket and remained unbeaten with 23.
Baroda started the day at 80 for one replying to Punjab's paltry first innings total of 130 and added 142 runs, the bulk of it scored by Martin, who batted for 286 minutes and hitseven fours in his 179-ball essay.
Opener Connor Willams made 5 in 165 minutes with five hits to the fence while all other top order batsmen flopped. Number ten Rakesh Patel made 28.
Punjab's leading wicket taker was medium pacer Gagandeep Singh who utlised the effect of the early morning dew to his advantage.