The Federal Reserve Bank of New York is facing the prospect of foreclosing on a number of properties in the coming months, from homes to commercial buildings, a result of a souring mortgage portfolio it took over when it helped bail out Bear Stearns in 2008. As it deals with delinquent borrowers, a team of New York Fed officials and outside advisers are trying to avoid having the US government, along with local sheriff's departments, seize commercial properties and homes as it copes with falling real-estate values. In the process, the New York Fed is getting a hard lesson in the challenges of mortgage lending.