I believe the legal situation is covered by something called a "lien" in the Civil Aviation Act.
As for protecting yourself against it, the choice appears to be either lease your aircraft wet and assume responsibility for paying all fees and charge them back to the leasing company, or if you do lease it dry, make sure you have some form of insurance to protect your interests and/or be all over the leasing company like a rash to make sure it is paying the bills.