
646 F.3d 1128 (2011)
UNITED STATES of America, Appellee,
v.
Chad MILLER, Appellant.
No. 10-3475.
United States Court of Appeals, Eighth Circuit.
Submitted: April 15, 2011.
Filed: July 28, 2011.
*1129 Jonathan Hammond, argued, Cedar Rapids, LA, for appellant.
Daniel C. Tvedt, AUSA, argued, Charles J. Williams, AUSA, on the brief, Cedar Rapids, IA, for appellee.
Before WOLLMAN, GILMAN,[1] and MELLOY, Circuit Judges.
WOLLMAN, Circuit Judge.
Chad Miller moved to dismiss a one-count indictment charging him with possession *1130 of a firearm while subject to a court order restraining him from harassing, stalking, or threatening an intimate partner, in violation of 18 U.S.C. §§ 922(g)(8) and 924(a)(2). After the district court[2] denied the motion, Miller entered a guilty plea and was sentenced to 69 months' imprisonment. Miller appeals, arguing that his conviction must be vacated because he was unaware that his possession of a firearm was prohibited and he falls within the limited exception to the maxim that ignorance of the law is no excuse, see Lambert v. California, 355 U.S. 225, 78 S.Ct. 240, 2 L.Ed.2d 228 (1957). Miller also contends that his sentence is unreasonable. We affirm.

I. Background
On January 16, 2009, a year-long order for protection was entered in Jackson County, Iowa, restraining Miller from committing further acts or threats of abuse or having any contact with T.S.T., the mother of his child. The state-court order sets forth in bold typeface "WARNINGS TO RESPONDENT: Federal law provides penalties for possessing, transporting, shipping, or receiving any firearm or ammunition (18 U.S.C. § 922(g)(8))." The second page of the order reads, in part,
The court FINDS by a preponderance of the evidence:
. . .
[X] (4) If checked, the court finds the defendant and protected party meet the definition of intimate partners as defined in 18 U.S.C. § 921(a)(32) ("`intimate partner' means, with respect to a person, the spouse of the person, a former spouse of the person, an individual who is a parent of a child of the person, and an individual who cohabitates or has cohabitated with the person").
IF (4) IS CHECKED, the court must check box 6, prohibiting the defendant from possessing firearms.
. . .
[] (6) If checked, the defendant shall not possess firearms while this order is in effect. Defendant shall deliver all firearms to the _______________ County Sheriff or __________ (law enforcement agency) on or before _____________. The defendant is advised that the issuance of this protective order may also affect the right to possess or acquire a firearm or ammunition under federal law. 18 U.S.C. § 922(d)(8), (g)(8).
The order included handwritten instructions regarding Miller's visitation schedule with his child.
Months later, on December 3, 2009, trooper Peter Streets of the Iowa State Patrol stopped to assist Miller, who had driven his vehicle into a ditch. Streets suspected that Miller was driving while under the influence of alcohol and took him into custody. While Streets processed paperwork, Miller made threatening remarks, saying that he knew who Streets was and where he lived. Streets testified that Miller also said "that he was going to burn my fucking house down." Sentencing Tr. 8. When Streets asked Miller if he would like to make a phone call, Miller replied, "No. Fuck it. I will catch up with you later." Presentence Report ¶ 13. Miller also told Streets that he would see him in the morning and that "[d]eer season was coming and accidents happen." Sentencing Tr. 8. Miller spent that night in county jail.
On December 7, 2009, Miller made his initial appearance on the charge of operating a motor vehicle while intoxicated, his *1131 third offense of that nature. Around 7:50 p.m. that same evening, Miller drove his white Ford Mustang to Streets's home, a farmhouse located in a rural area. Streets's wife saw the Mustang slow down, rev its engine, and turn in a complete circle on the lane to Streets's home. Knowing that Streets had been threatened, his wife yelled to him and took their children upstairs. Streets grabbed his assault rifle and ran outside, but Miller had left the area. Law enforcement officers stopped Miller a short time later in a nearby town. Miller was intoxicated and had an uncased Winchester 12-gauge shotgun and seventeen rounds of ammunition in the front seat. After the officers removed him from the car, Miller refused to remove his hands from his pockets. The officers tased him, tackled him, and arrested him at gunpoint. He was charged with possessing a firearm while being subject to a court order restraining him from harassing, stalking, or threatening an intimate partner.
Miller moved to dismiss the indictment, arguing that he did not knowingly possess a firearm because there was no proof "of his knowledge that a qualifying Order was in existence at the time he possessed a firearm." Mot. to Dismiss ¶ 8. He requested a hearing to present testimony "that the Court brought the parties into chambers and specifically advised [him] that a consent order would not [a]ffect his rights to possess or acquire a firearm and ammunition under federal law." Id. ¶ 6. The district court denied the motion without a hearing and later accepted his guilty plea.
At his sentencing hearing, the district court determined that Miller's advisory sentencing range under the U.S. Sentencing Guidelines Manual was 15 to 21 months' imprisonment. After considering the factors set forth in 18 U.S.C. § 3553(a), the district court decided that an upward variance from the top of the guidelines range was appropriate, "I'm going to add another four years for the aggravating factors not taken into account by the guidelines; threats to the trooper, unscored criminal history, dangerousness." Sentencing Tr. 39.

II. Analysis

A. Conviction
Miller contends that his conviction violates his Fifth Amendment right to due process because he did not have actual or constructive knowledge that he was subject to a restraining order that prohibited him from possessing a firearm. See § 922(g)(8). He asserts that the state court did not intend to check box (4) and that the court advised him that the order for protection would not affect his right to possess a firearm. Miller argues that he reasonably relied on the court's advice and that his case thus falls within the limited exception to the "common maxim, familiar to all minds, that ignorance of the law will not excuse any person, either civilly or criminally." United States v. Hutzell, 217 F.3d 966, 968 (8th Cir.2000) (quoting Barlow v. United States, 32 U.S. 404, 411, 7 Pet. 404, 8 L.Ed. 728 (1833)).
Section 922(g)(8) renders unlawful the possession of a firearm by an individual subject to certain restraining orders.[3] Section 924(a)(2) provides the penalties for those who "knowingly" violate *1132 § 922(g). "`[K]nowingly' supplies the mens rea for the conduct proscribed in section 922 as designated in section 924. The statutes do not require knowledge of the law nor an intent to violate it." United States v. Farrell, 69 F.3d 891, 893 (8th Cir.1995). The penalty provisions of § 924(a)(2) thus require the government to prove that the defendant knew of the facts that constituted the offense under § 922(g), not that the defendant knew that his possession of a firearm was illegal. United States v. Lippman, 369 F.3d 1039, 1043 (8th Cir.2004); Hutzell, 217 F.3d at 968.
Miller relies upon Lambert v. California, 355 U.S. 225, 78 S.Ct. 240, 2 L.Ed.2d 228 (1957), to argue that his ignorance of the law excuses his conduct. Lambert involved a Los Angeles ordinance that imposed criminal penalties on felons who remained in the city for more than five days without registering with the chief of police. Id. at 226, 78 S.Ct. 240. The Supreme Court held that the city's registration provisions violated the due process clause of the Fourteenth Amendment because the ordinance punished, without forewarning, conduct that a reasonable person ordinarily would not consider criminal. Id. at 229-30, 78 S.Ct. 240.
Miller claims that he has "satisf[ied] the requirement in Lambert that there was nothing `intuitively unlawful' about his actions" because he possessed a firearm after the state court told him that the restraining order would not affect his right to do so. Appellant's Br. 13. Even accepting Miller's allegation as true,[4] his conduct of possessing a firearm while subject to a restraining order is different from the "wholly passive" conduct of being a felon while remaining in Los Angeles for five days. See Lambert, 355 U.S. at 228, 78 S.Ct. 240. We recognize that "firearms possession, without more, is not a kind of activity comparable to possession of hand grenades, narcotics, or child pornography," United States v. Meade, 175 F.3d 215, 226 (1st Cir.1999) (citations omitted), but we conclude that firearms possession also is not the kind of activity comparable to "mere presence in the city." Lambert, 355 U.S. at 230, 78 S.Ct. 240. So although Miller's conduct may not be "per se blameworthy," the possession of a firearm, especially by someone subject to a restraining order, "is nevertheless a highly regulated activity, and everyone knows it." See Hutzell, 217 F.3d at 968, 969.
Miller's alleged lack of awareness also does not compare to the defendant in Lambert, who had no notice or reason to be on notice. The front page of Miller's restraining order warned that federal law restricts the possession of firearms by individuals subject to restraining orders, and the second page of the order established that Miller and T.S.T. were intimate partners under federal law. Box (4), which was checked, instructed that the judge "must check box (6), prohibiting the defendant *1133 from possessing firearms."[5] Moreover, the fact that Miller was subject to an order that restrained him from threatening, assaulting, stalking, molesting, attacking, harassing, or otherwise abusing T.S.T., gave Miller reason to be on notice that his conduct was subject to increased government scrutiny. See United States v. Beavers, 206 F.3d 706, 710 (6th Cir.2000) ("[I]t should not surprise anyone that the government has enacted legislation in an attempt to limit the means by which persons who have a history of domestic violence might cause harm in the future."); Meade, 175 F.3d at 226 ("[P]ossession of firearms by persons laboring under the yoke of anti-harassment or anti-stalking restraining orders is a horse of a different hue."). "Because it is not reasonable for someone in his position to expect to possess dangerous weapons free from extensive regulation, [the defendant] cannot successfully claim a lack of fair warning with respect to the requirements of § 922(g)(8)." United States v. Baker, 197 F.3d 211, 220 (6th Cir.1999). We therefore conclude that Miller's alleged lack of awareness was not reasonable, in light of the text of the order and the fact that he was subject to a restraining order.[6]

B. Sentence
Miller contends that his sentence was substantively unreasonable. We review the substantive reasonableness of a sentence under a "deferential abuse-of-discretion standard." Gall v. United States, 552 U.S. 38, 41, 128 S.Ct. 586, 169 L.Ed.2d 445 (2007). When the district court imposes a sentence outside the advisory guidelines range, we "may consider the extent of the deviation, but must give due deference to the district court's decision that the § 3553(a) factors, on a whole, justify the extent of the variance." Id. at 51, 128 S.Ct. 586.
Although the district court's upward variance was substantialadding 48 months to the 15- to 21-month guidelines-range sentencethe district court gave several reasons for imposing the sentence and remarked that Miller's case was "unlike the run of the mill possession of a firearm while subject to a court order of protection." Sentencing Tr. 37. Most importantly, it found that the situation was aggravated, given that Miller had threatened Streets and continued to harass him "by going to his house, as you said you would, and being armed, as you indicated you would. Deer season, accidents happen. The impact of your actions, the words and the actions you took that night in going out to the trooper's house had a serious impact on this trooper and his family." Id. at 38, 128 S.Ct. 586. Moreover, the district court believed that Miller's unscored criminal history "shows total *1134 and complete disregard for the laws of our country." Id. It found that Miller was dangerous, based on the circumstances of his arrest and his prior and pending driving-while-intoxicated convictions, stating, "I can't think of a worse combination than being drunk and having a gun and ammunition." Id. We conclude that the aggravated nature of Miller's offense, the danger he posed to the community, and his criminal history provided adequate justification for the district court's exercise of its discretion to vary upwards as it did.
Miller contends that the district court failed to take into account the fact that he possessed the firearm and ammunition without knowing that he was prohibited from doing so, either because he was ignorant or because the state court advised him that the order for protection would not affect his right to possess firearms. The district court was well aware of Miller's arguments regarding these allegedly mitigating factors and apparently gave them little weight. We cannot say that the district court "commit[ted] a clear error of judgment by arriving at a sentence that lies outside the limited range of choice dictated by the facts of the case." United States v. San-Miguel, 634 F.3d 471, 475 (8th Cir.2011) (quoting United States v. Jones, 509 F.3d 911, 913 (8th Cir.2007)); see also Gall, 552 U.S. at 59, 128 S.Ct. 586 (noting that the range of choice dictated by the facts of a case was significantly broadened after the guidelines became advisory). Nor can we say that the sentence it imposed was greater than necessary to comply with the provisions of § 3553(a).

III. Conclusion
The conviction and sentence are affirmed.
NOTES
[1]  The Honorable Ronald Lee Gilman, United States Circuit Judge for the Sixth Circuit Court of Appeals, sitting by designation.
[2]  The Honorable Linda R. Reade, Chief Judge, United States District Court for the Northern District of Iowa.
[3]  Section 922(g) provides:

It shall be unlawful for any person . . .
(8) who is subject to a court order that
(A) was issued after a hearing of which such person received actual notice, and at which such person had an opportunity to participate;
(B) restrains such person from harassing, stalking, or threatening an intimate partner of such person or child of such intimate partner or person, or engaging in other conduct that would place an intimate partner in reasonable fear of bodily injury to the partner or child; and
(C)(i) includes a finding that such person represents a credible threat to the physical safety of such intimate partner or child; or
(ii) by its terms explicitly prohibits the use, attempted use, or threatened use of physical force against such intimate partner or child that would reasonably be expected to cause bodily injury; . . . to . . . possess in or affecting commerce, any firearm or ammunition. . . .
[4]  According to Miller, in an interview with the Federal Bureau of Investigation, the state judge "indicated he had no recollection of whether he may have stated to the Defendant that the Order would or would not interfere with the Defendant's right to possess a firearm." Reply to Government's Sentencing Mem. 2. We note that the district court did not abuse its discretion in denying a hearing on Miller's motion to dismiss the indictment.
[5]  Miller contends that the [X] indicating that box (4) applies was a scrivener's error because the state court did not intend to restrict his right to possess firearms. Federal lawnot the state court's intentiondetermines whether Miller's possession of firearms was unlawful. Even if box (4) had not been checked, it is clear from the face of the protective order that the elements of § 922(g)(8) were met. Specifically, the order sets forth Miller's visitation schedule with his child, thus establishing that he and T.S.T. were "intimate partners" under federal lawprecisely the finding that box (4) indicated. See § 921(a)(32) (defining the term "intimate partner" as including "an individual who is a parent of a child of the person").
[6]  Our sister circuits have uniformly rejected due process challenges to § 922(g)(8) based on the defendant's lack of awareness that his possession of a firearm was a federal offense. E.g., United States v. Kafka, 222 F.3d 1129, 1131 (9th Cir.2000); United States v. Reddick, 203 F.3d 767, 770 (10th Cir.2000); Baker, 197 F.3d at 220; Meade, 175 F.3d at 226; United States v. Bostic, 168 F.3d 718, 722 (4th Cir.1999); United States v. Wilson, 159 F.3d 280, 289 (7th Cir.1998).
