Locke wrote the purpose of government is to secure and protect the God given inalienable natural rights of the people. For their part, the people must obey the laws of their rulers. Meaning, a sort of contract exists between the rulers and the ruled.