A creditor is entitled to the benefit of everything which a surety has received from the debtor by way of security for the performance of the obligation, and may, upon the maturity of the obligation, compel the application of such security to its satisfaction.
Ca. Civ. Code § 2854