The first competitive meeting between the two clubs turned out to be a cracker.
Stevenage had hit back on each occasion after falling behind three times.
David Ball twice put Peterborough ahead but Boro levelled through Stacy Long and Michael Bostwick.
Former Stevenage favourite George Boyd restored Posh's lead in the first period of extra-time but Chris Beardsley brought the League One club level again.
Tomlin settled the tie from the spot when Jon Ashton was adjudged to have fouled Boyd inside the box.
Stevenage goalkeeper Alan Julian had saved from Tomlin and Lee Frecklington before Ball put Peterborough in front.
Ryan Tunnicliffe headed Frecklington's deep corner back across goal and Ball headed home from close range after 16 minutes.
Long levelled just after the half-hour mark with a low, 18-yard shot.
Julian saved from Boyd before Ball put Peterborough back in front from the edge of the box after 65 minutes.
Bostwick sent the game into extra-time with a superb 25-yard effort before Boyd, who left Stevenage for Posh in 2007, matched that with a long range strike of his own.
Beardsley headed home Bostwick's cross as the tie looked to be heading for a penalty shoot out.
The game was eventually settled from the spot, when Tomlin sent Julian the wrong way at the death.