Yes, it is perfectly legal. It is voluntary on the part of banks and other lenders to make loans--no law requires them to do so. It being voluntary, they are free to put restrictions on lending, and to require any amount, kind, or level of information or documentation that they want before extending the loan. If you or the person providing the gift does not want to disclose this information, that is your right--and it is the lender's right to then say that your aplication is denied and you are not getting the loan.