1026.35(c)(4)(vii): You do not have to order an additional appraisal for a covered HPML used to acquire the property from a person who acquired title on the property via foreclosure, deed-in-lieu of foreclosure, or other similar judicial or nonjudicial procedure through that person’s exercise of rights as the holder of a defaulted loan.
If I’m understanding your question and examples correctly, this exemption would apply to the the purchase of the foreclosed property from the bank (since the bank would be the person who acquired title via foreclosure), but would not apply when that purchaser resells the property.
Note: Business purpose loans are not covered by Reg Z and, therefore, the HPML appraisal rules do not apply to business purpose loans.