This paper attemps to rationalize the use of insurance covenants in financi
al contracts, and shows how external financing generates a demand for insur
ance by risk-neutral entrepreneurs. In our model, the entrepreneur needs ex
ternal financing for a risky project that can be affected by an accident du
ring its realization. Accident losses and final returns are private informa
tion to the firm, but they can be evaluated by two costly auditing technolo
gies. We derive the optimal financial contract: it is a bundle of a standar
d debt contract and an insurance contract with franchise, trading off bankr
uptcy costs vs auditing costs. We then analyze how this optimal contract ca
n be achieved by decentralized trading on competitive markets when insuranc
e and credit activities are exogenously separated. With additive risks, the
insurance contract involves full coverage above a straight deductible. We
interpret this result by showing how our results imply induced risk aversio
n for risk-neutral firms.