Bava Batra 173 - Obligations of a Loan Guarantor
One who lends money to his fellow based on a guarantor may not collect first from the guarantor. However, if the lender said to the guarantor at the time of the loan, "I am making this loan on the condition that I should be able to collect from whomever I wish," - then he may indeed collect from the guarantor.
Art: Portrait of Victor Hugo on his deathbed by Leon Daniel Saubes
