The debate between contract versus convention is a continuation of the clash between individualism and communitarianism. Although social contract theory as far as we can tell originated with Socrates, it was assimilated during the Enlightenment era to support projects that Socrates would have had nothing kind to say about. Rather than justifying the state or the community, social contract theorists (SCT) of the modern period were occupied with tearing down state authority to the level of the individual. Instead of SCT being a one-way contract, with the state having the right to enforce any terms or to reach any decision whatsoever, it was seen as something artificially created, adopted through autonomous agency, and limited.
It did not represent hidden, ultimate obligations that the community burdened the individual with. Rather, it was the individual’s assent to the existence of the community that gave it is power, and this consent was seen as absolutely necessary, a thought which continues to be prominent today in theories that justify the state altogether.
As for social contract theories that went too far, Hume was ready to ridicule. His thought experiment making light of tacit consent as justifying the authority of the state or community was this: suppose someone is drugged and then dragged onto a ship in the middle of the ocean. We would feel ridiculous to say that he consents to the orders and authority of the captain simply because he does not throw himself overboard. Likewise, for the poor artisan living on subsistence wages, how can we say that he consents because he is unable to move to a foreign country where (1) he will likely starve to death, and (2) cannot even speak the language, etc.? This is essentially Hume’s criticism of the more overbearing types of social contract theory.
Hume’s view of legitimacy and justification is based on convention. Government is not justified because of some mysterious contract that everyone must have entered into at some seminal point in history. It is instead justified because of its utility. Owing to his non-cognitivist approach to ethics, Hume had no moral justification to offer for the state. Rather, he thought that it was rationally justified because it provides utility—far more utility than would be provided in its absence. Hume was no anarchist. He was quite conservative in his politics. The utility invoked was not really related to utilitarianism. It does not describe pleasure or happiness, and there is no calculus of utils. What Hume means to say is that utility is to be identified with usefulness. And this is an easy enough question to answer. All Hume has to show is that the existence of a state provides more overall use and benefits from that use than its non-existence. It provides impartiality, safety, security, a framework of rights and responsibilities, creates shared values, promotes economic exchange and prosperity, etc. If these things are not possible without a state, then the problem for Hume is solved.
Again, there might be a problem for Hume in trying to calculate aggregate utility, but he takes it as commonsensical that the majority of people prefer flourishing to suffering, freedom to slavery, peace to war, and prosperity to poverty. Of course, one could just stonewall and claim that for them the opposite would be true. Hume would then have nothing to say; he just assumes that the majority’s preferences would side with him over the others. Thus, while there is no morality behind obedience, it makes sense to keep one’s promises and obligations on a rational level; if we did not, society would cease to exist, and that would remove all utility.
There’s some agreement with Hobbes here. Both view the non-existence of the state as totally unacceptable. There could be no division of labor and no arts, no industry, no production, etc. For Hobbes, it would be the war of all against all, but for Hume it would just be less utility; he would reject Hobbes’ view of human nature.
Similarly, Locke believes in a state but does not believe that the state of nature would exist as Hobbes assumes. It would be livable; the reason that we want to form a state, however, is so we can avoid the problems inherent in taking enforcement into our own hands. Since natural rights exist apart from and prior to the state, the right to their enforcement must also exist (executive power). So everyone who suffers violation can pursue justice, something that Locke acknowledges will cause mischief.