Sources
Westminster Confession of Faith (1646), chapter 22, sections 2-3, and chapter 23, section 2
22.2 (end): “Yet, as, in matters of weight and moment, an oath is warranted by the word of God, under the New Testament, as well as under the Old; so a lawful oath, being imposed by lawful authority, in such matters, ought to be taken.” 22.3 (end): “Yet it is a sin to refuse an oath touching anything that is good and just, being imposed by lawful authority.” 23.2: “It is lawful for Christians to accept and execute the office of a magistrate, when called thereunto: in the managing whereof, as they ought especially to maintain piety, justice, and peace, according to the wholesome laws of each commonwealth; so, for that end, they may lawfully, now under the New Testament, wage war, upon just and necessary occasions.”
Text of 1646. Original English text, as given at westminster1647.com (/cfw/22 and /cfw/23); in 22.3, westminster1647.com puts the sentence quoted in square brackets, a text of 1646 that later revisions removed.