The Rossoneri face Atalanta on Wednesday and a loss coupled with a Juve win over Lecce would see Antonio Conte's men crowned the champions of Italy.
However, Eranio is adamant the reason why Milan have struggled to replicate last season's success so far is down to injuries to key players.
"With all the problems the team have had then certainly [Allegri deserves a new contract]. He lost important players at decisive moments for the team. It is not his fault," the 45-year-old told Sports Radio.
Eranio was also asked if Fabio Capello, who previously coached the club, would be a suitable replacement if Allegri was to be dismissed.
"Capello's ability is not disputed, he is a great manager but the important thing now is not to put pressure on Allegri as he lost important players like [Antonio] Cassano, [Kevin-Prince] Boateng, [Alessandro] Nesta and Thiago Silva when the league was being decided," he added.
Eranio enjoyed a successful five-year spell at AC Milan between 1992 and 1997, winning three Serie A titles in the process.