Marshall, the 2014 Conference USA champion, finally beat a team from a major conference at home after going 0-5 since 2005. But the Thundering Herd needed some late help.
After Devon Johnson put Marshall ahead 34-31 with a 6-yard scoring run with 2:50 remaining, Purdue had plenty of time left. But Lang intercepted Austin Appleby in the middle of the field and returned it 55 yards for a score with 1:20 left.
Lang was a nice bookend for Marshall. He also returned an interception 30 yards for a touchdown on the first play from scrimmage.
It marked the first time in school history that a Marshall player returned two interceptions for scores.
Purdue lost its eighth straight road opener and seventh consecutive game dating to last season.
Appleby, the fifth quarterback to start a season for Purdue in the past five years, went 31 of 48 for 270 yards and one score. He was intercepted four times.
Appleby was at his best in the first half when he stiff-armed a Marshall defender with his left hand while throwing a short pass to Danny Anthrop, who took it 9 yards for a score.
Purdue's top two running backs entered the season with no carries in a college game. Sophomore D.J. Knox and freshman Markell Jones proved quite capable.
Knox, who played on special teams a year ago, ran for 102 yards on 22 carries, including a 4-yard TD run in the first quarter.
Jones made his mark in the third quarter when he burst into the secondary, pushed his own lineman aside and dashed 36 yards for a touchdown to put Purdue ahead 28-24. Jones had 72 yards on 12 carries.
Birdsong had an up-and-down debut in his first game since transferring from James Madison a year ago. Replacing four-year starter Rakeem Cato, Birdsong went 23 of 36 for 234 yards. He looked shaky at times before a sellout home crowd and Marshall's offense misfired when it had opportunities to scores.
Birdsong threw behind Nick Mathews inside Purdue's 10 late in the third quarter and Marshall settled for a field goal.
Two series later, Johnson got into the secondary but lost the ball at end of the 33-yard run and Purdue took over at its 25.
The Boilermakers drove to the Marshall 5. Appleby overthrew an open Jordan Jurasevich on third down in the end zone, and a short field goal extended Purdue's lead to 31-27 early in the fourth.
Johnson had a 20-yard scoring run for Marshall in the first quarter but was quiet for most of the game, something he wasn't accustomed to last year when he ran for 1,767 yards. He was limited Sunday to 89 yards on 11 carries.