All three posts seem likely, bad steel lines rusting inside, bad rubber line in back, and a possible proportioning valve issue. The rubber line is where I would start. The idea that the mechanic suggested a new master cylinder to cure this problem is disturbing. Although if this replaced original booster and master then it was time anyway.