Boro will travel to Bradford City in Round Three of the Carabao Cup.
The Bantams beat Wrexham on penalties in the second round last night, while Boro came from behind to best Bolton.
The sides have not met competitively in over two decades, and not in the League Cup since way back in 1984, but Boro were at Valley Parade as recently as July for an entertaining pre-season friendly that ended 3-3.
Third-round ties are due to take place week commencing 25 September.