*1186Cheryl Price and Greg Lovelace, two of the defendants below, petition this Court for a writ of mandamus directing the trial court to enter a summary judgment in their favor on the ground of State-agent immunity. We grant the petition and issue the writ.
Price was formerly the warden at Donaldson Correctional Facility ("the prison"), which is operated by the Alabama Department of Corrections ("the DOC"). Lovelace is a deputy commissioner of the DOC in charge of construction and maintenance. The plaintiff, Marcus Parrish, is a correctional officer employed by the DOC. The evidence, viewed in the light most favorable to Parrish, the nonmovant, see Wilma Corp. v. Fleming Foods of Alabama, Inc., 613 So.2d 359 (Ala. 1993), reveals the following facts. Parrish was supervising inmate showers in a segregation unit in the prison. Parrish left the shower area briefly to retrieve shaving trimmers, and, when he returned, inmate Rashad Byers had already entered a shower cell, which had an exterior lock on it. Byers indicated that he was finished with his shower, and Parrish told him to turn around to be handcuffed. Parrish then approached Byers's shower door with the key to the lock on the door in his hand. Parrish was getting ready to unlock the shower door when Byers unexpectedly opened the door, exited the shower cell, and attacked Parrish. During the attack, Byers took Parrish's baton from him and began striking Parrish with it. Parrish was knocked unconscious, and he sustained injuries to his head.
Parrish sued Price and Lovelace in their official capacities. Parrish later filed an amended complaint naming Price and Lovelace as defendants in their individual capacities only. Thus, it appears that Price and Lovelace are now being sued only in their individual capacities. Parrish also sued other defendants, but those claims are not relevant to this petition. Parrish's allegations concern the cell-door locks and staffing at the prison. Parrish alleged that many of the locks at the prison were defective, which allowed prisoners to open supposedly locked doors, and that the prison was understaffed with correctional officers. Parrish alleged that Price and Lovelace willfully breached their duties by failing to monitor the prison for unsafe conditions and by failing to repair or replace the allegedly defective locks. The complaint further alleged that Price willfully breached a duty by failing to remedy the alleged understaffing at the prison. Although the allegations concern both faulty locks and understaffing, it appears that the primary allegation concerns the locks; Parrish does not mention the alleged understaffing in his brief to this Court.
Price and Lovelace moved for a summary judgment, asserting, among other things, that they are entitled to State-agent immunity. Price and Lovelace supported their summary-judgment motion mainly with excerpts from their own depositions. In response, Parrish argued that Price and Lovelace are not entitled to State-agent immunity. Following a hearing, the trial court denied the summary-judgment motion. The trial court concluded, without elaboration, that genuine issues of material fact exist so as to preclude a summary judgment. Price and Lovelace then petitioned this Court for a writ of mandamus, arguing that they are immune from liability based on State-agent immunity.
Generally, the denial of a summary-judgment motion is not reviewable by a mandamus petition, but an exception to that general rule exists here. The denial of a summary-judgment motion grounded on a claim of immunity is reviewable by a mandamus petition. Ex parte Turner, 840 So.2d 132, 135 (Ala. 2002).
*1187"A writ of mandamus is an extraordinary remedy, and it will be 'issued only when there is: 1) a clear legal right in the petitioner to the order sought; 2) an imperative duty upon the respondent to perform, accompanied by a refusal to do so; 3) the lack of another adequate remedy; and 4) properly invoked jurisdiction of the court.' Ex parte United Serv. Stations, Inc., 628 So.2d 501, 503 (Ala. 1993)."
Ex parte Empire Fire & Marine Ins. Co., 720 So.2d 893, 894 (Ala. 1998).
Moreover,
"[i]n reviewing a trial court's ruling on a motion for a summary judgment, we apply the same standard the trial court applied initially in granting or denying the motion. Ex parte Alfa Mut. Gen. Ins. Co., 742 So.2d 182, 184 (Ala. 1999).
" 'The principles of law applicable to a motion for summary judgment are well settled. To grant such a motion, the trial court must determine that the evidence does not create a genuine issue of material fact and that the movant is entitled to judgment as a matter of law. Rule 56(c)(3), Ala. R. Civ. P. When the movant makes a prima facie showing that those two conditions are satisfied, the burden shifts to the nonmovant to present "substantial evidence" creating a genuine issue of material fact.'
" 742 So.2d at 184. '[S]ubstantial evidence is evidence of such weight and quality that fair-minded persons in the exercise of impartial judgment can reasonably infer the existence of the fact sought to be proved.' West v. Founders Life Assurance Co. of Florida, 547 So.2d 870, 871 (Ala. 1989)."
Swan v. City of Hueytown, 920 So.2d 1075, 1077-78 (Ala. 2005).
In Ex parte Cranman, 792 So.2d 392 (Ala. 2000) ( Cranman was a plurality decision, but a majority of this Court later adopted the Cranman standard in Ex parte Butts, 775 So.2d 173 (Ala. 2000) ), this Court restated the standard governing State-agent immunity:
"A State agent shall be immune from civil liability in his or her personal capacity when the conduct made the basis of the claim against the agent is based upon the agent's
"(1) formulating plans, policies, or designs; or
"(2) exercising his or her judgment in the administration of a department or agency of government, including, but not limited to, examples such as:
"(a) making administrative adjudications;
"(b) allocating resources;
"(c) negotiating contracts;
"(d) hiring, firing, transferring, assigning, or supervising personnel; or
"(3) discharging duties imposed on a department or agency by statute, rule, or regulation, insofar as the statute, rule, or regulation prescribes the manner for performing the duties and the State agent performs the duties in that manner; or
"(4) exercising judgment in the enforcement of the criminal laws of the State, including, but not limited to, law-enforcement officers' arresting or attempting to arrest persons[, or serving as peace officers under circumstances entitling such officers to immunity pursuant to § 6-5-338(a), Ala. Code 1975]; or
"(5) exercising judgment in the discharge of duties imposed by statute, rule, or regulation in releasing prisoners, counseling or releasing persons of unsound mind, or educating students.
"Notwithstanding anything to the contrary in the foregoing statement of the rule, a State agent shall not be immune *1188from civil liability in his or her personal capacity
"(1) when the Constitution or laws of the United States, or the Constitution of this State, or laws, rules, or regulations of this State enacted or promulgated for the purpose of regulating the activities of a governmental agency require otherwise; or
"(2) when the State agent acts willfully, maliciously, fraudulently, in bad faith, beyond his or her authority, or under a mistaken interpretation of the law."
792 So.2d at 405 (bracketed language is modification added by Hollis v. City of Brighton, 950 So.2d 300, 309 (Ala. 2006) ).
" 'This Court has established a "burden-shifting" process when a party raises the defense of State-agent immunity.' Ex parte Estate of Reynolds, 946 So.2d 450, 452 (Ala. 2006). A State agent asserting State-agent immunity 'bears the burden of demonstrating that the plaintiff's claims arise from a function that would entitle the State agent to immunity.' 946 So.2d at 452. Should the State agent make such a showing, the burden then shifts to the plaintiff to show that one of the two categories of exceptions to State-agent immunity recognized in Cranman is applicable."
Ex parte Kennedy, 992 So.2d 1276, 1282 (Ala. 2008).
The parties first dispute whether Price and Lovelace have met their burden of showing that Parrish's claims arise from a function that would entitle them to State-agent immunity. That is, the parties dispute whether Price and Lovelace have shown that they fall within any of the five categories of State-agent immunity listed in Cranman. Price and Lovelace contend on appeal, as they did below, that they qualify for State-agent immunity under multiple Cranman categories. Parrish argues that Price and Lovelace have failed to produce evidence establishing that they fall within any of the Cranman immunity categories.
In arguing that Price and Lovelace have failed to meet their evidentiary burden, Parrish relies primarily on Ex parte Wood, 852 So.2d 705 (Ala. 2002).1 In Wood, E.L. was a student at a juvenile-correctional facility operated by the Alabama Department of Youth Services ("the Department"). He sued Wood, the executive director of the Department, in his individual capacity. As executive director, Wood implemented the policies and procedures established by the Alabama Youth Services Board. E.L. alleged that, as a student at the facility, he was not provided the curriculum and course of study mandated by state law. Wood moved for a summary judgment, asserting that he was entitled to State-agent immunity, and he supported his motion with his own affidavit. The trial court denied the summary-judgment motion, and Wood petitioned this Court for a writ of mandamus.
This Court concluded that Wood had failed to meet his burden of establishing that E.L.'s claims arose from Wood's performance of a function that would entitle him to immunity under Cranman. The crucial factor was the insufficiency of Wood's *1189affidavit. His affidavit stated, in relevant part:
" 'As Executive Director, I carry out the policy and procedure established by the Alabama Youth Services Board for the operation of the Department within the budget limitations established by the Legislature in the allocation of funds for the Department. I have reviewed the amended complaint filed by [E.L.] .... All of my responsibilities in connection with the issues identified in the complaint require the exercise of judgment and discretion in carrying out state policy. The issues involve only the following: administration of the Department, allocation of resources, hiring, firing, transferring, assigning, or supervising personnel, or otherwise exercising judgment in the discharge of my duties imposed by statute, rule[,] or regulation in counseling or releasing persons of unsound mind or educating students.' "
852 So.2d at 708.
The Court concluded that "Wood's affidavit simply recite[d] the rule of State-agent immunity restated in Cranman." 852 So.2d at 710. The Court noted that, "[a]lthough Wood's affidavit state[d] the issues in terms that would lead to the conclusion that he [fell] under the immunity from liability set forth in Cranman, Wood fail[ed] to provide any significant facts relating to his personal involvement in the actions giving rise to the claims asserted against him." Id. The Court in Wood continued:
"Wood's affidavit states in conclusory terms that his duties required him to exercise his judgment and discretion. He listed his duties, yet failed to state his involvement, or his adherence to a rule or regulation governing the exercise of his duties, in the actions underlying the claims asserted against him. Based on the materials before us, we hold that the evidence was insufficient to support a conclusion that Wood was entitled to State-agent immunity."
Wood, 852 So.2d at 711-12.
Parrish argues that Price and Lovelace, like Wood, have failed to present evidence establishing that they qualify for one of the Cranman immunity categories. However, for the reasons discussed below, we conclude that this case is not controlled by Wood and that Price and Lovelace met their burden under Cranman.
In arguing that she has State-agent immunity, Price emphasizes her limited testimony addressing her responsibilities as warden. Despite such limited testimony, Price, as a warden, fits into one of the Cranman immunity categories. Unlike the Court in Wood, we can make this determination without the benefit of more detailed testimony from the defendant. The Court in Cranman recognized the distinction "between conduct involved in planning or decision-making in the administration of government and the conduct of those required to carry out the orders of others or to administer the law with little choice as to when, where, how, or under what circumstances their acts are to be done." 792 So.2d at 402. As a warden, Price falls on the immunity side of that distinction. The assertions against Price regarding the allegedly defective locks and alleged understaffing generally concern Price's role in maintaining prison safety. Price testified that, as warden, she was responsible for the security of the prison, including the safety of the correctional officers. That broad responsibility would necessarily place Price in Cranman category two, which protects a State agent when "exercising ... judgment in the administration of a department or agency." In that regard, Price, as warden of the prison, is in a position similar to the police chief in Howard v. City of Atmore, 887 So.2d 201 (Ala. 2003). The police chief in Howard was *1190"responsible for the 'day-to-day operations of the [police] department and the city jail.' " 887 So.2d at 209-10. This Court in Howard determined that "[t]hose activities fall squarely within category (2) of the Cranman formula." 887 So.2d at 210. We conclude that the same is true for Price with respect to all the allegations against her in this case.
Moreover, the materials before us contain additional evidence indicating that Price falls within a Cranman category of immunity regarding the allegation that she did not remedy the prison's allegedly defective locks (which appears to be the main allegation against her), although Price does not point to that evidence for that purpose. Price testified that she had received reports of some issues with the locks: locks in the infirmary had been opened by inmates, locks on the main riot gates had problems, and at least one lock in the old segregation unit was not operational. Price testified that, in response to those issues, the infirmary locks were changed, the locks on the main riot gate were added to a maintenance schedule so they could be serviced, and a hasp had been added to the door in the old segregation unit with the inoperable lock to keep that door secure. Regarding the locks in the prison's new, or main, segregation units, Price was asked if she recalled any correctional officers reporting that any locks in that area were inoperable. She answered: "Not inoperable, no. If they did not properly secure the doors, the inmates could jam those locks. So they would have to clean out those locks. And that became part of the policy." That policy regarding sabotaged locks was an unwritten policy that had been in place before Price became warden; Price continued the policy by discussing with the correctional officers during meetings the need to clean out locks. Price testified that she and other prison officials made the decision to discuss the unwritten policy with the correctional officers. Thus, unlike the situation in Wood, the materials before us do contain some specific facts concerning Price's personal involvement in actions underlying the claim asserted against her. Further, those facts establish that, with respect to the locks, Price continued a policy, entitling her to immunity under category one in Cranman, which provides immunity for a State agent when "formulating plans, policies, or designs," see Alabama Dep't of Corr. v. Thompson, 855 So.2d 1016, 1018-20 (Ala. 2003) (equating the continuation of a policy with the formulation of a policy), and category two, which broadly protects a State agent when the agent is "exercising ... judgment in the administration of a department or agency." 792 So.2d at 405.2
We also conclude that Lovelace, the deputy commissioner of the DOC in charge of construction and maintenance, falls within certain categories of immunity in Cranman. Parrish alleges against Lovelace, as he did against Price, that Lovelace failed to remedy the allegedly defective locks in the prison (he does not appear to be alleging that Lovelace had anything to do with alleged understaffing). Lovelace's deposition testimony is quite sparse, and Parrish emphasizes that fact in arguing that Lovelace failed to carry his burden of establishing that he qualifies for immunity under a Cranman category. Lovelace testified that his responsibilities include renovations to and modifications of the DOC's facilities, including the prison. He stated that as deputy commissioner he probably visits the prison a couple of times a year on an as-needed basis. Lovelace testified that he is in charge of the DOC's central maintenance division, which supplements *1191the maintenance work done at each of the DOC's facilities, helping the facility's staff on larger projects.
In suing Lovelace, a deputy commissioner for the DOC, for failing to remedy alleged faulty locks in the prison, Parrish reached fairly high up the DOC hierarchy. Parrish testified that he sued Lovelace because he is "in charge of the locks and taking care of the maintenance" and "he's the maintenance man that's over everything." Lovelace did testify that he is in charge of the entire central maintenance division of the DOC. Even more so than Price, Lovelace operates at the planning and decision-making level of government. The allegation leveled against him regarding the faulty locks in the prison appears necessarily to involve his judgment in the administration of the DOC. Thus, we conclude that Loveless qualifies for immunity under Cranman categories one and two.
Accordingly, Price and Lovelace met their burden of establishing that they fall under an immunity category in Cranman. The burden then shifted to Parrish to show, by substantial evidence, that one of the two exceptions to State-agent immunity recognized in Cranman applies. Parrish contends that he met that burden, but he does not explain which exception he believes is applicable. Although he does not explicitly say so in his brief, it appears that Parrish essentially argues that Price and Lovelace acted willfully and maliciously, either of which would disqualify them from State-agent immunity under the second exception in Cranman. We conclude, however, that there is no substantial evidence that Price or Lovelace acted willfully or maliciously.
" ' "Willfulness" is the conscious doing of some act or omission of some duty under knowledge of existing conditions accompanied with a design or purpose to inflict injury.' Instruction 29.01, Alabama Pattern Jury Instructions-Civil (2d ed. 1993); see also Roe v. Lewis, 416 So.2d 750, 754 (Ala. 1982) (willfulness 'denotes an intention to cause an injury'). Similarly, malice is defined as '[t]he intent, without justification or excuse, to commit a wrongful act....' Black's Law Dictionary, 968 (7th ed. 1999)."
Ex parte Nall, 879 So.2d 541, 546 (Ala. 2003) (concluding that two high-school baseball coaches were entitled to State-agent immunity).
In support of his argument that Price acted willfully or maliciously, Parrish cites his testimony stating that he informed Price that locks at the prison were inoperable. However, that evidence is not substantial evidence that Price acted willfully or maliciously. As noted, Price testified that measures were taken to remedy the inoperable locks, including her telling correctional officers to check for locks inmates had jammed. Even if some locks remained inoperable after those measures, there is no evidence indicating that Price intended to cause injury, which is necessary to establish willfulness or maliciousness. Regarding his allegations that the prison was understaffed, Parrish does not discuss any evidence indicating that Price acted willfully or maliciously, and there appears to be no evidence supporting that position in the materials before us. Regarding the allegation against Lovelace, Parrish does not cite any evidence that he argues shows willfulness or maliciousness, and there appears to be no evidence supporting such a position in the materials before us. In short, Parrish has not met his burden of showing the existence of an exception to State-agent immunity.
Price and Lovelace have established that they are entitled to State-agent immunity. Accordingly, we direct the trial court to enter a summary judgment in their favor.
PETITION GRANTED; WRIT ISSUED.
Stuart, C.J., and Bolin, Parker, Murdock, Shaw, Main, Wise, and Sellers, JJ., concur.
Parrish secondarily relies on Dunnam v. Ovbiagele, 814 So.2d 232 (Ala. 2001). Like this case, Dunnam concerned the plaintiff's assertion that the defendants had failed to produce evidence establishing that they fit into a category of immunity restated in Cranman. However, Dunnam turned on a specific question inapplicable here: whether, as a matter of law, the defendant physicians fit into the Cranman category of immunity "provided for those 'exercising judgment in the discharge of duties imposed by statute, rule, or regulation in ... counseling or releasing persons of unsound mind.' " 814 So.2d at 237 (quoting Cranman, 792 So.2d at 405 ).
The materials before us do not contain evidence establishing that the lock on the shower door that was opened during the attack on Parrish was inoperable.