Abstract
Secure coding is essential, yet the strategies developers use to detect and mitigate flaws are not well understood. We present an eye-tracking-based approach that captures developers’ visual patterns while reading, coding, and applying security tools. Our framework uses participant-editable stimuli and dynamic environments to reflect authentic coding development. By visualizing gaze transitions and attention shifts, we expose how developers allocate effort during secure coding. By leveraging techniques that reveal gaze transitions, attention levels, and pupil size changes, we are able to gain insight into their behavior. Our study provides a fine-grained, process-oriented account of behavior in CWE-based secure coding educational tasks, uncovering attentional patterns and decision timelines that traditional methods may not capture. These contributions provide a foundation for improving training and understanding developer differences.
1. Introduction
Secure coding is increasingly critical as computing devices proliferate and thousands of new vulnerabilities emerge each year [1,2]. As vulnerabilities continue to grow in number, it is increasingly important to understand not only whether learners can write secure code, but how they behave while reading, reasoning about, and repairing potentially vulnerable code. To examine these behaviors, we use an active, hands-on approach in which students identify and mitigate security weaknesses while we record their eye gaze behavior during the tasks. To the best of our knowledge, this is the first study to apply eye tracking to characterize how learners read, comprehend, and produce secure code with static and dynamic CWE-based content presented to the secure coders.
Traditional measures of learning—exams, essays, projects, and interviews—offer partial insight into what students understand about secure coding but often fail to capture how they actually behave while solving problems [3,4]. Many of these methods depend on carefully crafted prompts, vary by discipline, and can introduce bias or disrupt attention; direct observation, while objective, is intrusive [5]. Furthermore, much of secure coding proficiency resides in non-verbal “skill memory” that is hard to articulate [6]. Techniques like think-aloud protocols and questionnaires can bias responses or degrade task focus, and participants may not accurately recall key steps [5,6,7]. Self-reports cannot show where participants actually look, so they risk misattributing attention [8,9].
Our study instead examines the effectiveness of hands-on teaching materials by observing students as they locate and mitigate security flaws in actual source code. We focus on capturing and analyzing behavioral evidence while learning in an ecologically valid programming environment. In secure coding tasks, developers rapidly switch among files and tools, view multiple materials at once, and edit code, making objective gaze tracking essential. We turn to eye tracking as a discreet, unobtrusive way to collect objective data on visual attention during secure coding tasks. Building on its use in reading and math contexts [10,11], we use eye gaze data over secure coding programming stimuli to understand how learners allocate attention, switch between tools, and progress through problem-solving. This approach aims to inform the design of more effective secure coding modules and methodologies.
We use eye tracking to objectively capture developers’ fine gaze patterns, behaviors, and learning strategies while they locate and mitigate software vulnerabilities. In a realistic, user-controlled setting—multiple code files, documentation, a static-analysis tool, and web search—we record fixations and saccades with timestamps and map them to Areas of Interest (AOIs) spanning code, tools, and references. Because conventional gaze plots assume linear text reading and break down with rapid app switching, we have adapted existing methods and introduce swimlane diagrams, state-transition graphs, AOI transition matrices, and pupil-diameter timelines [12]. Our multilevel analysis in our previous work investigated and quantified behavior at the low level (eye movements, fixation durations, and saccade rates), medium level (within/between files, functions, and tools), and high level (task sequences and strategies) [13]. Several of the visualizations used in this manuscript are reproduced or adapted from our prior publications [12,13] to illustrate the analysis framework.
This manuscript builds on our prior work by applying previously developed data processing and visualization techniques to a new analytical objective. While earlier studies focused primarily on the design and validation of these eye gaze visualization approaches, the present work emphasizes their interpretive use to investigate secure coders’ behavior. In particular, we leverage our visualization methods to examine attention allocation, action sequencing, and strategy shifts, with the goal of drawing new behavioral insights and answering targeted research questions. The present work substantially extends the behavioral interpretation and draws new conclusions based on a deeper comparative analysis across learning modules and among our secure coders. Our visual analytics measure attention allocation, order of operations, and strategy shifts, even with many AOIs and frequent transitions. We apply the framework across two learning modules—manual code analysis and static-analysis tooling—to compare behaviors and progression. Overall, our approach provides unobtrusive, objective evidence to guide the design and assessment of secure coding instruction while reducing bias from self-report or intrusion. Specifically, this manuscript advances prior research by using visualization methods to answer targeted behavioral questions, such as whether participants correctly identified vulnerabilities or relied on guessing, whether relevant code regions were inspected but misunderstood or missed entirely, how navigation strategies differ (e.g., whole-file review versus function-level transitions), and how effectively participants engage with static-analysis tools. These questions frame the primary contribution of this work as moving from visualization development to using those visualizations to potentially explain how and why secure coding behaviors succeed or fail at developing secure software applications. More broadly, our approach aligns with prior work using eye tracking for process-level learning assessment, where gaze behavior is used to evaluate how learners engage with material, identify points of difficulty, and infer underlying cognitive strategies [3,4].
2. Materials and Methods
Multiple hands-on secure coding exercises were developed and integrated with eye tracking to examine how students analyze and remediate software vulnerabilities in a realistic programming context. The study design incorporates progressive learning modules, interactive coding tasks, and controlled laboratory conditions using a real-world web application with known security flaws. In the context of this study, the terms students, participants, learners, and developers are used interchangeably to refer to the graduate and undergraduate student group. Participant characteristics, experimental procedures, and ethical considerations are documented to support reproducibility and interpretation.
Figure 1 presents the secure coding eye-tracking framework developed in this study to support the experimental design and analysis of developer visual behavior for secure coding. The framework maps eye-tracking instrumentation and analysis directly onto key phases of the software development lifecycle (SDLC), with particular emphasis on coding and testing activities where security-critical decisions occur. These phases are decomposed into representative developer tasks, including reading and writing source code, interacting with IDEs and analysis tools, reviewing code, and consulting documentation, ensuring that the experimental stimuli reflect authentic secure coding workflows. The framework further defines the eye-tracking pipeline, encompassing stimulus design, gaze data analysis, and behavioral visualization, along with task types, stimulus dynamics, viewing configurations, and interaction modalities. By enabling both single- and multi-developer analyses using quantitative and qualitative techniques, this framework provides a structured and reproducible foundation for studying attention allocation, task transitions, and security-relevant behavior in secure software development.
Figure 1.
Secure coding eye-tracking framework developed in this study, linking SDLC phases and developer tasks to eye-tracking stimulus design, gaze analysis, and behavioral visualization.
2.1. Secure Learning Exercise Design and Educational Objectives
We designed a hands-on learning exercise to help participants understand key cybersecurity coding mistakes. To support students in becoming confident secure coders, we developed learning modules that gradually increase in difficulty as their skills progress. Each module walks through real-world examples of security flaws and how to fix them—starting with the CWE repository and concluding in hands-on coding exercises.
Using ShareAlbum, a media-sharing site, we demonstrated how these flaws can emerge in real-world applications. ShareAlbum’s design—centered on uploading and sharing photos and videos—makes it an ideal case study for identifying and addressing security vulnerabilities.
We designed and developed ShareAlbum, which contained known security flaws. These are based on the Common Weakness Enumeration (CWE) repository, OWASP Top 10, and the National Vulnerability Database (NVD). Therefore, they provide a suitable context for participants to identify and mitigate vulnerabilities within a complete codebase (approximately 30 files) rather than isolated snippets [1,14,15,16]. Furthermore, our eye-tracking participants were allowed to make code changes and run the web application after their code modifications. Each participant was given an original copy of the ShareAlbum application codebase for code modification. The homepage of ShareAlbum along with the split screen developer workflow is shown in Figure 2.
Figure 2.
The developer desktop used in the study, showing the ShareAlbum homepage (left) and Notepad++ displaying the instructions for CWE-443 during a secure coding task.
2.2. Learning Modules
Two primary learning modules were created: (1) manual code analysis, focused on close reading and reasoning about code, and (2) static code analysis tool, centered on using the RIPS (version 0.55) static code analysis tool. Both modules covered targeted CWEs—their definitions, exploitation pathways, and mitigation strategies—supported by worked code examples and short video demonstrations. The two learning modules presented distinct sets of CWE vulnerabilities for student examination. In the manual code analysis module, students first reviewed CWE documentation, then performed a free-form audit of the ShareAlbum application. They navigated across multiple files and functions, scrolled through large code sections, consulted web pages, and—critically—implemented their own fixes. This created dynamic, non-linear interaction with the material rather than passively reading code snippets. In the static code analysis tool module, students ran the RIPS tool to generate vulnerability reports for the same application, then traced findings back to code locations, prioritized issues, and verified or refuted the RIPS tool output. We aim to teach secure coding through step-by-step, hands-on work with a real, flaw-bearing software application. This provides realistic experience beyond trivial code snippets, letting participants practice identifying and fixing vulnerabilities in a full software context.
2.3. Eye-Tracking Stimuli Design and Areas of Interest (AOIs)
This learning content was adapted into various eye-tracking stimuli within Tobii Studio (version 3.4.5) [17]. Static stimuli included PDF documents for reading introductory material and code snippets presented alongside multiple-choice or true/false questions for simpler tasks. Dynamic, user-interactive stimuli were used for more complex tasks, allowing participants to scroll through full source code files in Notepad++ (version 7.8), use the RIPS tool and web browser (including search engines), test changes, and modify the source code directly to patch vulnerabilities, as shown in Figure 3. A split-screen setup was frequently employed to present stimuli concurrently (e.g., code editor alongside RIPS or instructions), providing a natural coding environment. The stimuli presentation followed a structured sequence: introduction, basic multiple-choice questions, and finally, user code modification tasks requiring the participant to modify the eye-tracking stimuli. The exercise was structured so that the CWE problems became increasingly complex as students advanced.
Figure 3.
The developer desktop used in the study, showing the RIPS static-analysis tool (left) and Notepad++ displaying the ShareAlbum source code (right) during a secure coding task.
We defined both static and dynamic AOIs to analyze gaze at the application, file/function, and statement levels. Static AOIs were created in Tobii Studio’s AOI tab for fixed stimuli (e.g., multiple-choice items), using manual shapes, labels, and color coding. Dynamic AOIs were built frame-by-frame in Tobii Studio over each participant’s session video, allowing AOIs to be added, resized, or re-positioned as the on-screen content changed. This timeline workflow supported the enabling/disabling of AOIs across time, marking keypoints, and tracking eye gaze through scrolling and view changes. The approach overcomes one-screen limitations by accommodating the realistic, non-linear navigation of code and tools. The trade-off is increased processing time due to meticulous per-frame AOI editing and management for every recording. While this method captures highly detailed behavioral information, extending it to larger participant samples, longer sessions, or more complex codebases would require significant effort. As it stands, this was a very time-consuming effort on our part to support dynamic non-linear content; however, this enabled more realistic eye-tracking stimuli than is generally utilized in eye-tracking studies. Semi-automated AOI generation, template-based annotations, or coarser-grained AOIs at the function or module level may offer practical ways to maintain analytical richness while improving scalability. Further research on eye-tracking methodologies, including improved automation and analysis techniques, could enhance the efficiency and applicability of these approaches, but such work is beyond the scope of the present study.
2.4. Participants
A total of 29 participants for the first learning module (manual code analysis) and 31 for the second (static code analysis tool) were recruited. These students were from undergraduate and graduate computer science courses at the University of Alabama in Huntsville (UAH), ensuring a basic understanding of software coding. Participants were incentivized by the potential for an extra team member on a semester project and exemption from a related take-home assignment; no monetary compensation was provided. Demographic data was collected via a post-session questionnaire. For the first module (total participants = 29), participants included 7 females and 22 males, aged 21–44 (median 25). Their pursued degrees included 19 Master’s (Computer Science), 1 PhD (Computer Engineering), 8 Bachelor’s (Computer Science), and 1 Bachelor’s (Computer Engineering). Experience levels reported were: 15 entry-level (0–2 years), 12 juniors (3–5 years), 1 mid-level (5–10 years), and 1 senior (>10 years). Similar demographic distributions were observed for the second module (total participants = 31). All participants received identical learning materials and questions individually. Each module was completed on a separate day, with a maximum time of 2 h including a break. The average recording durations were 49 min for the first module and 54 min for the second. Just one participant went beyond the two-hour time limit and received an instruction to conclude the experiment.
2.5. IRB Approval
The study protocol was reviewed and approved by the UAH Institutional Review Board (IRB). All participants were university students and provided written informed consent prior to taking part in any eye-tracking session. Participant identities and raw eye gaze recordings were treated as confidential and were not released or shared outside the research team. Raw eye-tracking recordings and associated metadata are not publicly available due to IRB protection of participant data. The release of individual-level eye gaze data would require explicit written consent from each participant; at present we do not have authorization to disclose these confidential datasets.
2.6. Learning Module Workflow and Evaluation Criteria
Both the manual code analysis learning module and the static code analysis tool learning module (the latter employing the RIPS static-analysis tool) were organized into three sequential phases. In the first phase participants were introduced to critical software-security flaws, with each vulnerability contextualized for our photo-and-video-sharing web application, ShareAlbum. The second phase presented stimulus materials (static source code excerpts) in Tobii Studio and required participants to answer either multiple-choice or true/false questions about the vulnerabilities they had just reviewed; multiple-choice items asked participants to select the mitigation they judged most appropriate. The third phase presented complete source code files in the Notepad++ editor and asked participants to directly modify the code to mitigate the identified vulnerability.
For programming tasks, the manual review examined the modifications each participant made and categorized responses according to both form and effectiveness. The reviewer noted whether the participant had written new source code, provided pseudocode, or left only a comment indicating the vulnerability’s location and a proposed mitigation strategy. Each submission was then rated as (1) fully mitigating the vulnerability, (2) partially mitigating the vulnerability, or (3) unsuccessful in proposing a viable mitigation. This rubric allowed us to measure two complementary competencies: the participant’s ability to locate the vulnerability within the codebase and, where possible, to specify an appropriate remediation. Because not all participants had prior experience with HTML or PHP, providing pseudocode or a descriptive comment was accepted as an alternative to fully implemented code; participants were nonetheless encouraged to implement source-level fixes when they were able.
2.7. Common Weakness Enumerations (CWEs) Included in the Study
The seven CWEs covered in the study address a range of fundamental security flaws in web applications such as the ShareAlbum application. CWE-311: Missing Encryption of Sensitive Data focuses on the failure to encrypt data that should be protected, such as authentication credentials or personal information, both when it is stored and when it is transmitted. CWE-434: Unrestricted Upload of File with Dangerous Type occurs when an application allows users to upload files without properly validating their type, potentially leading to the execution of malicious scripts or code on the server. CWE-862: Missing Authorization involves a severe access control flaw where a system fails to perform or incorrectly performs an authorization check, allowing an actor to access resources or perform actions they should not be permitted to do.
The remaining CWEs focus on improper handling of user input and resulting integrity issues. CWE-22: Improper Limitation of a Pathname to a Restricted Directory (‘Path Traversal’) allows an attacker to access files and directories stored outside the intended root directory, often by supplying input that includes sequences like “../”. CWE-443: HTTP Response Splitting is a vulnerability that arises when an attacker can inject malicious newline characters into an HTTP header, enabling them to construct a second, separate HTTP response that could be used for attacks like cross-site scripting or cache poisoning. CWE-73: External Control of File Name or Path is a general class of vulnerability where an application uses input from an external source to construct a file name or path without adequate sanitization, potentially allowing an attacker to overwrite critical files or access unauthorized ones. Finally, CWE-79: Improper Neutralization of Input During Web Page Generation (‘Cross-site Scripting’) refers to the failure to properly sanitize user-controllable input before it is rendered on a web page, allowing an attacker to inject client-side scripts that execute in other users’ browsers.
2.8. Procedure
Each participant received an emailed copy of the consent form when scheduling their eye-tracking appointment and was given the same consent form to sign by hand upon arrival to the research lab. The lead investigator verified that participants had no remaining questions or concerns before any session began; all scheduled participants agreed to participate and provided a handwritten signature.
Only one participant was allowed in the research lab at a time; the lead investigator was the only other person present during sessions. The investigator provided a brief overview of the Tobii X2-60 eye-tracking device and the Tobii Studio software (version 3.4.5) used to present stimuli and record gaze data. During each session the lead investigator observed the participant from approximately ten feet away to ensure an appropriate distance from the eye tracker.
2.9. Use of Generative AI Tools
Generative AI tools were not used for study design, data collection, data analysis, data interpretation, or the generation of results, figures, or tables. The study methods, findings, and conclusions were completed as part of the first author’s dissertation prior to preparation of this manuscript and prior to the widespread use of generative AI tools. During manuscript preparation only, Grammarly, ChatGPT, and Google Search AI Mode were used for limited editorial assistance on author-written text, including minor rephrasing for clarity and basic correction of grammar and style. All output was reviewed and edited by the authors, who take full responsibility for the final content.
3. Results
Our eye-tracking study objectively examined students’ learning behaviors during multiple secure coding tasks. Analyses of gaze behavior revealed clear differences between participants who selected correct mitigation strategies and those who did not: successful participants devoted more time to inspecting and understanding coding errors before interacting with the source code. These findings suggest that a comprehension of errors prior to editing supports more efficient and effective learning of secure coding practices.
3.1. Programming Results
In the manual code analysis module participants completed both structured questionnaire items and open-ended programming tasks. On the multiple-choice items, performance was strong: for the CWE-311 problem (correct answer = Programming Solution C) 24 participants selected the correct Solution C, five selected Solution B, and none selected Solution A (N = 29). For the CWE-434 problem (correct answer = Programming Solution A) 28 participants selected Solution A and one selected Solution B (N = 29). These distributions show that the large majority of participants identified the correct mitigation when presented with multiple-choice options for the security flaw.
The two code-writing programming problems (CWE-862 and CWE-22) were more challenging than the multiple-choice items and were scored using the above-mentioned three-level rubric (fully mitigated, partially mitigated, and not mitigated). The participants were encouraged to submit working code but could instead provide pseudocode or a comment.
For CWE-862 (N = 29), the majority of participants provided source-level responses: 16 produced correct code and five produced partially correct code. In contrast, four participants produced incorrect code. The remaining responses included one correct pseudocode and three incorrect comments. This indicates that 17 participants successfully mitigated the vulnerability (correct code + correct pseudocode).
The CWE-22 problem (N = 29) proved more challenging and diverse in its responses. Only five participants produced correct code, and three produced partially correct code. A total of five participants produced incorrect code. Non-code submissions were frequent: five participants provided correct pseudocode, one provided partially correct pseudocode, and one provided incorrect pseudocode. Furthermore, four participants provided correct comments, one provided a partially correct comment, and four provided incorrect comments. Overall, 14 participants correctly located and mitigated the flaw across all submission types (correct code + correct pseudocode + correct comments).
In the static code analysis tool module, participants answered two true/false items based on RIPS outputs (CWE-443 and CWE-73) and completed a programming task targeting CWE-79. The true/false items produced mixed results. For the CWE-443 item, where the correct answer was False (vulnerability classified incorrectly by RIPS), 10 participants answered True while the majority, 21 participants, answered False (N = 31). Conversely, for the CWE-73 item, where the correct answer was True (vulnerability classified correctly by RIPS), 15 participants answered True while 16 participants answered False (N = 31).
In the static code analysis tool module, the CWE-79 programming problem produced mainly partial solutions, with four participants producing fully correct code and 21 producing partially correct code. An additional three participants provided incorrect code, while three others provided non-code responses (one partially correct pseudocode, one correct comment, and one partially correct comment).
3.2. Secure Coders’ Performance and Behavior Analysis
We examined secure coders’ behavior on a targeted file manipulation task (CWE-73) to determine whether the vulnerability was present in the ShareAlbum codebase. For this exercise participants first reviewed instructional material on CWE-73 and then inspected the ShareAlbum source using the RIPS static-analysis tool. RIPS reported four potential file manipulation issues in the code, and each participant was required to judge whether the tool’s finding represented a real vulnerability (“YES”) or a false positive (“NO”). We selected this item for close, manual analysis after observing its notably mixed outcome—fifteen participants judged the issue correctly while sixteen did not—making CWE-73 the exercise with a higher rate of incorrect responses than the other CWEs in our study. This contrast motivated us to probe how participants approached their initial encounter with RIPS and how that interaction affected their vulnerability judgments. This observation prompted further analysis into how tool familiarity and interpretation strategies influence secure coding decisions.
This near-even split in participant responses highlights a critical challenge in secure coding practice: the cognitive and procedural gap between vulnerability theory and tool-assisted analysis. Although all participants received identical instruction on CWE-73, the mixed outcomes suggest that familiarity with a vulnerability class does not directly translate into accurate interpretation of static-analysis findings. Instead, the results indicate that developers’ trust calibration with security tools—how readily they accept or dismiss reported issues—plays a significant role in decision-making. In particular, the ambiguity of file manipulation vulnerabilities and the contextual reasoning required to validate them appear to increase susceptibility to misclassification, especially during an initial encounter with an unfamiliar analysis tool. These findings underscore the importance of not only teaching vulnerability taxonomies, but also explicitly training developers in how to critically evaluate static-analysis output, as misjudgments at this stage can either propagate latent security flaws or lead to unnecessary remediation effort.
3.3. RIPS Tool: Initial Usability
A known limitation of static analysis is the prevalence of false positives (tools flag code that is not truly vulnerable) [18,19]. As a key skill in secure software development, we designed the exercise for students to evaluate and prioritize these alerts. We assess the first-attempt usability of RIPS by determining whether participants experienced difficulties identifying vulnerabilities in ShareAlbum. Our eye-tracking analysis revealed that several participants had difficulty supplying the correct file path in the RIPS web interface when locating vulnerabilities in the ShareAlbum codebase. The study provided two guidance documents: a CWE-specific Instruction Guide that listed a relative path (Home\helpers\album.helper.php) to the target file, and a generic RIPS Help Guide that listed an absolute path (C:\wamp64\www\ShareAlbum\Home) to the ShareAlbum project directory. RIPS required the absolute project directory (the home webpage path) to locate the codebase; supplying the individual file name (e.g., album.helper.php) was not necessary. Many participants appeared confused by the discrepancy between the relative path specified in the CWE Guide and the absolute path required by the tool. This usability problem was uncovered through the analysis of eye-tracking data; notably, participants provided no verbal or written feedback regarding this confusion after their eye-tracking recording session.
To reduce confusion and improve learning outcomes, instructional materials should explicitly state the exact path format required by the analysis tool and provide standardized example paths across all stimuli. Revising the Instruction Guide to show a clear, step-by-step example of the RIPS file path entry (with both the project root and an explanation that individual filenames are optional) would likely shorten the tool-familiarization phase, reduce user frustration, and allow participants to focus on vulnerability interpretation rather than tool configuration. Such improvements should streamline the workflow for delivering tool output to learners and enable more efficient, accurate identification of real coding flaws.
Eye tracking provided us with evidence of confusion at the moment it occurred—long fixations on the file path field, repeated glances between the CWE Guide and the RIPS input box, and back-and-forth saccades to the browser to insert the path in the RIPS tool. Unlike post-task surveys, gaze data pinpointed exactly which interface elements and instructions drove the error (relative vs. absolute paths) and how long participants struggled before progressing. We were thus able to diagnose the instructional cause and usability fault without relying on potentially biased data from fallible recall or leading questions.
3.4. Correct Answers: Guessed Right or Found Flaw?
We ask whether correct True/False answers indicate genuine, source-level verification of the flaw or instead result from other factors such as guessing from the limited set of options presented. Our behavioral analysis shows that correct True/False responses for the CWE-73 vulnerability did not always reflect source-level verification. Several participants, most notably Participant S14 and Participant S26, selected the correct answer despite never examining the specific RIPS-flagged source location that actually contained the CWE-73 vulnerability. Participant S14 read the intro/exploit context carefully but skipped the mitigation paragraph, leaving a gap in preventive strategies. Furthermore, our analysis revealed that the participant previewed answer options before the question stem, suggesting a test-taking shortcut that could potentially bias their comprehension. RIPS reported four potential file manipulation issues in the codebase; the fourth flagged item contained the true CWE-73 flaw, yet Participant S14’s gaze data show no fixations on the relevant function (the add_new_file_to_album routine) and Participant S26 likewise did not inspect the underlying source. In both cases the correct binary response appears to have been driven in part by the constrained True/False format rather than by a deliberate code inspection. Additional details on the specific reading pattern of Participant S14 can be found in Appendix A.1. Additional details on the specific reading pattern of Participant S26 can be found in Appendix A.2.
While the detailed cases of Participants S14 and S26 illustrate this behavior, similar patterns were observed across other participants’ sessions. In many instances, correct True/False responses occurred without clear or sustained fixations on the specific RIPS-flagged code locations, suggesting that participants sometimes relied on contextual cues, partial readings, or test-taking strategies rather than deliberate source-level inspection. Because the depth and duration of gaze on an AOI can influence comprehension, determining a definitive “yes or no” for source-level verification is not straightforward, highlighting the complexity of interpreting behavioral data in these tasks. This reinforces the instructional risks associated with limited response formats and underscores the value of structured protocols that guide learners to systematically examine each flagged finding in the tool output.
Further analysis of the previously discussed RIPS tool setup analysis indicates that both Participant S14 and Participant S26 struggled during tool start-up because they supplied an incorrect file path when launching RIPS, which likely limited their ability to navigate all flagged items. These observations highlight two instructional risks: (1) limited response formats can produce apparently correct answers that are not grounded in code review, and (2) early usability errors (e.g., tool configuration mistakes) can prevent learners from engaging fully with flagged findings. We therefore recommend explicit training on tool configuration and a protocol that prompts users to inspect each flagged finding in the tool output; doing so should reduce accidental correct responses and improve the validity of vulnerability assessments derived from first-use interactions.
3.5. CWE-73: Inspected but Incorrect?
Our analysis also identified participants who inspected the RIPS report and the implicated source code for CWE-73 yet still judged the issue to be absent in ShareAlbum. For example, Participant S30 began fixating on the add_new_file_to_album function at approximately 560 s into the exercise and specifically inspected the internal move_uploaded_file call, which is the exact code associated with the CWE-73 finding. Participant S30 even opened RIPS’s Help documentation for this finding (reviewing the example code and proof-of-concept) but nonetheless answered that CWE-73 was not an issue in the codebase. Additional details on the specific reading pattern of Participant S30 can be found in Appendix A.3.
Participant S18 exhibited a similar pattern: Participant S18 inspected the fourth RIPS-reported item around 339 s into their session, returned to album.helper.php at 343 s, and opened the RIPS source code popup for the fourth flagged issue at 350 s; the popup remained open for only about 5 s. The brevity of this inspection suggests the participant did not engage in sustained reading of the flagged content. Additional details on the specific reading pattern of Participant S18 can be found in Appendix A.4.
Taken together, these cases indicate that mere exposure to the flagged file or opening the tool’s help content did not guarantee correct interpretation. In several instances participants viewed the relevant locations but did not allocate sufficient time to read the evidence carefully or misinterpreted the tool’s output, resulting in false-negative judgments of the CWE-73 finding. These findings have an important impact on instructional design, showing that future secure coding modules must move beyond simply providing students with access to analysis tools and focus instead on teaching them how to effectively interpret the tool’s findings and connect them to code context.
3.6. Incorrect Responses: Missed Code?
We assess whether incorrect responses arose because participants failed to open or review the specific code locations containing the CWE-73 vulnerability. Our behavioral data show that several incorrect judgments were attributable to participants not examining the source code that contained the CWE-73 vulnerability. For example, Participant S24 never inspected the second, third, or fourth items flagged by RIPS—the fourth of which contained the true CWE-73 issue—so Participant S24 could not plausibly have produced an informed or correct response. The recording logs further indicate that Participant S24 experienced difficulties initializing the RIPS tool, which likely prevented full access to the flagged findings. Additional details on the specific reading pattern of Participant S24 can be found in Appendix A.5.
These observations imply that some incorrect responses reflect failures of tool interaction or navigation. To reduce such false negatives in future exercises, we recommend enforcing a brief verification protocol (e.g., requiring users to open and view each flagged item for a minimum dwell time) and improving initial tool-configuration training so participants reliably can access all relevant findings before recording their judgments.
3.7. Whole-File Review or Function Jump?
We evaluated whether participants efficiently scanned the entire file before narrowing to a function or instead jumped straight to a single function without establishing broader context. Eye tracking shows that participants used both strategies. Several secure coders (notably Participant S10, Participant S20, and Participant S26) first scanned large portions of album.helper.php, scrolling through multiple functions and briefly glancing at many regions before settling on specific lines for closer inspection. By contrast, some participants adopted a targeted search strategy: for example, Participant S14 and Participant S10 used Notepad++’s Find feature to jump directly to relevant strings or function names.
These patterns suggest two distinct approaches—broad file scanning that builds a global view versus targeted string searches that locate likely hotspots quickly—each with different efficiency tradeoffs depending on the task. Recognizing these behaviors can inform instructional design (e.g., teach efficient search techniques and when to perform a quick global scan) to help learners balance comprehension and speed.
3.8. Do Participants Approach the Problem in the Same Way?
Because an AOI encompassing an entire code block provides limited spatial resolution, we defined the AOI specification for stimuli containing source code functions by subdividing each function into multiple, logically defined regions for static coding stimuli. As illustrated in Figure 4, AOIs were aligned with the key structural components of a programming function: the function signature/definition, variable declarations, control-flow statements, and statements that update or preserve internal program state. This approach differs from the use of a single overarching AOI for the full function and enables a supplemental, fine-grained analysis of which functional components participants inspected, as well as the sequence in which those regions were viewed.
Figure 4.
CWE-434 programming solution option A with AOIs overlays.
Figure 5 presents AOIs visualization by means of a fixation matrix for an individual participant, illustrating the distribution of visual attention across distinct components of a programming function (as defined in Figure 4). The fixation metrics indicate a clear concentration of attention on the SQL query execution AOI and the function-definition AOI within the first programming alternative (option A). Specifically, the SQL query execution AOI in option A accounts for the largest proportion of fixations (approximately 32% of total fixations) and the greatest share of fixation duration (approximately 41%), as well as the largest proportion of total recording time. Similarly, the function-definition AOI in option A exhibits elevated fixation counts and durations relative to other AOIs, indicating sustained visual engagement with this structural component of the code.
Figure 5.
Static PDF stimuli data analysis for CWE-434 with a detailed AOI for Participant 18.
In contrast, AOIs associated with conditional input validation, error handling, and boundary checks (e.g., missing input variables, file extension validation, and maximum file size checks) received comparatively fewer fixations and shorter cumulative viewing durations. This pattern suggests that, for this participant, attention was preferentially allocated to core functional logic and database interaction rather than to defensive programming constructs within the same code block. Additionally, AOIs corresponding to the second programming alternative (option B) received consistently lower fixation counts and durations across all measured metrics, indicating reduced visual engagement with that option relative to option A.
While the fixation matrix provides a quantitative summary of attention allocation across AOIs—via fixation counts, cumulative fixation duration, and total recording duration—it does not encode temporal ordering or gaze transitions between AOIs. As a result, the fixation matrix cannot reveal how the participant navigated between different components of the code, nor whether specific AOIs were revisited iteratively during problem solving. This limitation is inherent to fixation-based aggregation methods, which collapse eye-tracking data across time and stimulus elements. Consequently, AOI-to-AOI transitions, scan paths, and higher-level viewing strategies cannot be inferred from the fixation matrix alone and require complementary temporal or transition-based analyses.
To characterize how secure coders inspected and reasoned about source code, we analyzed AOI-to-AOI transitions over time. This transition-based approach complements fixation-based summaries by explicitly capturing the temporal ordering of visual attention and the revisitation behavior exhibited during problem solving. For each participant, AOI transitions were plotted along a timeline, enabling the identification of inspection strategies such as sequential reading, iterative revisiting of code regions, and switching behavior between alternative programming solutions.
In these transition plots, the x-axis represents the time at which a participant entered a given AOI, while the y-axis encodes the unique AOI identifiers, including AOIs associated with both programming option A and programming option B for CWE-434. This representation allows transitions within a single option, as well as cross-option transitions, to be visually identified and analyzed.
Figure 6 and Figure 7 illustrate representative AOI transition timelines that emphasize prolonged within-option inspection and targeted revisitation of security-relevant logic. In these examples, participants initially concentrated their attention on programming option A for an extended duration before transitioning to programming option B. The transition patterns further reveal repeated oscillations between closely related input-validation AOIs, including checks for missing input variables and incorrect file extensions. Notably, after inspecting programming option B, the participants returned to programming option A near the end of the task, indicating revisitation of the original solution following cross-option comparison. These behaviors demonstrate how AOI transition timelines capture iterative and non-linear inspection strategies that are not observable through aggregate fixation summaries alone.
Figure 6.
AOI transition plot for static stimuli for CWE-434 with a multiple AOI for Participant 32.
Figure 7.
AOI transition plot for static stimuli for CWE-434 with a multiple AOI for Participant 36.
Figure 8 and Figure 9 present additional AOI transition timelines that illustrate variation in how participants compared the two programming options for CWE-434. In Figure 8, the participant inspected multiple AOIs within programming option A prior to transitioning to option B, with several subsequent returns to option A while continuing to examine option B. This transition pattern reflects repeated cross-option movement rather than a single linear progression. In contrast, Figure 9 illustrates a participant who initially focused on programming option A, transitioned briefly to option B, and then returned to option A for an extended sequence of within-option AOI transitions before revisiting option B at a later point in the task. Unlike the participants discussed in the preceding paragraph, whose inspection was characterized by prolonged and localized examination of security-relevant AOIs, these examples emphasize broader cross-option comparison strategies and differing patterns of revisitation across programming alternatives.
Figure 8.
AOI transition plot for static stimuli for CWE-434 with multiple AOIs for Participant 10.
Figure 9.
AOI transition plot for static stimuli for CWE-434 with multiple AOIs for Participant 14.
For CWE-434, the programming solution containing the security flaw was in programming option A. The analysis of AOI transitions enables the identification of transition patterns and revisit behavior that are not observable through fixation matrices alone. By examining both the sequence and timing of AOI visits, this approach characterizes how participants navigate between functional components and between alternative implementations while working through secure coding problems.
In addition to transition patterns, AOI duration per transition, calculated from the start timestamps of successive AOI transitions, can be examined for the same participants when the transition plots are viewed interactively on a computer display. In this interactive view, hovering over an AOI entry reveals its start time and identifier, allowing the duration of visual attention within that AOI to be inferred from the time until the subsequent transition. This temporal representation supports the analysis of which AOIs received greater visual attention and when that attention occurred during task execution. Such temporal context is not available in fixation matrices, which provide only aggregate summaries of attention—such as total fixation counts or cumulative durations—per AOI without preserving their temporal ordering.
Overall, the transition-based AOI analysis demonstrates that secure coders exhibit distinct and individual inspection strategies. Some participants concentrate attention within a single programming option before switching to an alternative, while others distribute fixations across programming options throughout the task. The visualization of AOI transitions makes it possible to identify both the order and frequency of revisits to specific code elements, providing insight into participant-specific inspection patterns and supporting the conclusion that secure coding behavior varies substantially across individuals [20].
4. Discussion
Eye tracking provides behavioral details and insights that can help researchers and designers enhance user experiences, improve visual communication, and deepen understanding of how people perceive technical content. Researchers and designers can leverage the behavioral patterns and insights obtained through eye-tracking methodologies to improve the clarity and effectiveness of visual communication and to deepen understanding of human cognition and visual perception. In the context of secure coding, this behavioral perspective is particularly useful because it can reveal when and where comprehension breaks down during technical reading, and it can capture silent sources of friction that may not surface through post-task surveys or self-reports.
In this work, the emphasis is placed on the coding and testing phases of secure software development, using a real software application with known flaws to observe authentic behavior during code reading, editing, and validation. The study therefore concentrates on the software coding and software testing stages of the software development lifecycle (SDLC), as many vulnerabilities are addressed during these phases and because the experimental tasks involve an existing application containing security flaws. The results indicate systematic differences in how successful and unsuccessful participants allocated visual attention: participants who selected correct mitigations devoted more time to inspecting and understanding error or vulnerability context before interacting with the source code. This pattern is consistent with the working hypothesis that a comprehension-first strategy supports more efficient and effective mitigation. This suggests that secure coding instruction should emphasize a disciplined workflow in which learners interpret the defect, locate supporting evidence in code, and then map that evidence to a mitigation pattern rather than immediately attempting edits. While our findings provide useful instructional implications, it is important to note that the participant population in this study consists primarily of graduate and undergraduate students from a single university. As such, the observed strategies and attention patterns may differ from those of professional developers, who typically bring greater experience, established workflows, and often a more mature security mindset. This distinction may influence how readily these results generalize to industry settings. The study of professional developers is beyond the scope of this research study and therefore we cannot draw conclusions on the behavior pattern of professional developers.
The findings further suggest an instructional distinction between recognition and generation. Performance was high for multiple-choice items, where participants largely identified correct mitigations when options were provided, whereas code-writing tasks produced lower accuracy and a greater proportion of partial solutions (e.g., CWE-22 and CWE-79). This gap indicates that many learners can recognize an appropriate secure coding principle but encounter difficulty implementing it correctly in context, where edge cases and placement of defensive logic must be reasoned about. This challenge is amplified in static-analysis workflows, where learners must evaluate and prioritize tool outputs, contend with false positives, and connect alerts to source-level semantics and evidence [18,19]. The mixed outcomes observed for tool-based judgment tasks (e.g., CWE-73) are consistent with this broader difficulty; correct answers do not necessarily imply source-level verification, and incorrect answers may arise even after brief exposure to relevant code. This underscores the need for training that targets interpretation and verification rather than tool exposure alone. Additionally, because the study was conducted in a controlled experimental setting using a bounded application with known vulnerabilities, the complexity and ambiguity of real-world development environments may not be fully represented. Figure 10 shows generalized behavioral pathways observed across secure coding learning tasks, showing how early comprehension barriers, incomplete inspection, and misinterpretation can lead to unsuccessful outcomes, whereas grounded inspection and correct interpretation support appropriate responses. However, these pathways should not be interpreted deterministically: even when learners follow a grounded process by inspecting relevant evidence and reasoning carefully, they may still arrive at an incorrect conclusion due to ambiguity in the code, difficulty interpreting tool output, or limited prior experience.
Figure 10.
Generalized behavioral pathways observed across secure coding learning tasks.
Although software development also encompasses requirement engineering, documentation, design, and system architecture, these earlier stages fall outside the immediate scope of the present eye-tracking investigation. Our study did not directly examine upstream artifacts such as UML diagrams, UX design artifacts, database schemas, or cloud-deployment architecture diagrams. Prior work by other researchers have explored eye gaze behaviors during the design phase by examining how participants interpret UML diagrams [21], and related efforts have begun examining design artifacts and traceability between requirements and code [22,23,24]. Eye tracking has similarly been proposed as a valuable method for studying engagement with software requirement specifications [25], which may extend to evaluating how users navigate technical documentation prior to product release. Within the present scope, the analysis also surfaced a practical usability barrier during the first use of the RIPS tool—confusion over relative versus absolute file paths—which was observable in moment-to-moment gaze behavior even though participants did not report it afterward. This result reinforces that tool configuration and workflow clarity can directly shape whether learners reach, inspect, and correctly interpret the evidence needed for vulnerability evaluation and prioritization; accordingly, future secure coding modules should pair conceptual instruction with explicit tool-setup guidance and structured verification protocols.
The AOI-based annotation approach used to support this analysis requires substantial manual effort and domain expertise, which may present challenges when scaling to larger, more complex, or more diverse codebases. As a result, the findings should be interpreted primarily within the context of controlled environments and may not fully generalize to large-scale or highly heterogeneous development settings without adaptation. However, from an eye-tracking perspective, this study represents a comparatively advanced application in terms of the richness of stimuli and the depth of the analytical framework used. Finally, because the SDLC encompasses a diverse array of activities, the exploration of stimuli beyond source code reading, editing, and software testing—and beyond the CWE problem space—remains a natural direction for future work, including efforts to validate these findings with professional developers and to explore more scalable or automated AOI generation methods.
4.1. Limitations
Although eye tracking provided objective behavioral data, it also introduced methodological constraints. In particular, AOI construction required substantial manual frame-by-frame annotation effort for non-linear dynamic content, including turning AOIs on and off and repositioning them as the video content changed over time. This process enabled the dynamic alignment of gaze data with evolving on-screen elements, but it also introduced potential subjectivity because AOI boundary placement, timing, and granularity depended on annotator judgment. Inter-annotator agreement was not assessed in the present study, in part because the frame-by-frame dynamic AOI annotation of evolving interface elements is not well supported by current eye-tracking software and therefore requires substantial manual judgment. AOIs were primarily constructed around blocks of code with adequate spacing to separate neighboring regions and facilitate consistent annotation across frames. Accordingly, the eye-tracking results should be interpreted with the understanding that some measures may be influenced by annotation decisions. In addition, the labor-intensive nature of this approach limits scalability for larger and more complex studies. This study has several additional limitations that should be considered when interpreting the findings:
- Sample size: The participant sample was modest, which limits the strength of broader generalization.
- Institutional context: Participants were recruited from undergraduate and graduate computer science courses at a single institution, so the findings may not fully generalize to other academic settings or to professional developers. Professional developers may demonstrate different visual attention patterns, workflow strategies, and interpretation of static-analysis tool findings due to greater practical experience, which may lead to outcomes that differ from those observed in this student population.
- Multi-factor module differences: The two learning modules were intentionally designed as distinct secure coding learning contexts and therefore differed in more than tooling alone, including task complexity, interaction style, and cognitive demands. Accordingly, the observed eye-tracking differences should be interpreted as reflecting behavior across different instructional contexts rather than as a tightly controlled causal comparison of tool effects alone.
- Controlled study environment: The study was conducted in a structured instructional setting using the ShareAlbum application, a bounded codebase with known vulnerabilities, which may not fully reflect the complexity and ambiguity of real-world software development environments.
- Single static-analysis tool: The static-analysis portion of the study relied exclusively on RIPS, so some observed usability issues and behavioral patterns may be tool-specific rather than representative of static-analysis tools more broadly.
- Limited vulnerability scope: The investigation focused on a selected subset of CWE categories, rather than the full spectrum of software security weaknesses, so the conclusions are most directly applicable to the vulnerability classes examined here.
- Generalizability of conclusions: Taken together, these factors mean that the findings should be interpreted within the specific educational, institutional, and tooling context of this study. However, the approaches and methods utilized in this study may generalize to areas that could benefit from eye-tracking technologies.
4.2. Instructional Recommendations
Based on the behavioral patterns observed in this study, several instructional recommendations emerge for the design of secure coding learning modules:
- Emphasize a comprehension-first workflow: Learners should be encouraged to first interpret the vulnerability, understand its context, and identify supporting source-level evidence before attempting code changes. Our findings suggest that participants who devoted more attention to understanding the error or vulnerability context before editing were more likely to perform effectively.
- Provide explicit static-analysis tool setup guidance: Instructional materials should clearly explain how to initialize and use the analysis tool, including exact path-entry requirements and standardized worked examples. In the present study, confusion over relative versus absolute file paths in RIPS created an avoidable usability barrier that interfered with learner performance.
- Train learners to verify tool findings rather than rely on tool exposure alone: Because correct answers did not always reflect genuine source-level verification, secure coding instruction should explicitly teach students how to inspect flagged findings, connect alerts to code context, and distinguish true vulnerabilities from false positives.
- Use structured verification protocols for tool-assisted tasks: Learning activities should require students to systematically examine each flagged item in the tool output before recording a judgment. A brief verification protocol may help reduce accidental correct responses, unsupported conclusions, and missed vulnerabilities.
- Support interpretation as well as identification: The findings indicate that merely viewing a flagged source location or opening help documentation does not guarantee correct interpretation. Instruction should therefore go beyond presenting tool outputs and focus on helping secure coders reason about why a finding is or is not valid in context.
- Teach efficient code navigation strategies: Participants used both broad file scanning and targeted search strategies, each with different tradeoffs. Secure coding modules may benefit from explicitly teaching when to conduct a quick whole-file review and when to use targeted search features to locate likely problem areas efficiently.
- Address the gap between recognition and generation: Performance was stronger on structured recognition tasks than on open-ended code-writing tasks, suggesting that learners may recognize an appropriate mitigation without being able to implement it correctly. Instruction should therefore include opportunities to move from identifying secure solutions to applying them in full code context.
5. Conclusions
Our study underscores that secure coding learning modules benefit from continual iteration and refinement. We conducted (to our knowledge) the first eye-tracking investigation of secure coding behavior in cybersecurity education that specifically targets issues categorized by the Common Weakness Enumeration (CWE). In this study, we observed undergraduate and graduate participants across two secure coding learning modules. Because the participant population consisted primarily of students engaged in structured learning modules, the findings are best interpreted as patterns of secure coding learning behavior rather than as representative of expert professional practice. A key finding is that weaker performance often coincided with spending less time on the instructional materials, despite comparable overall time spent coding—highlighting the importance of guided preparation, not just practice. These insights into our learners’ attention and workflow can inform targeted revisions to content and sequencing to improve educational outcomes.
Author Contributions
Conceptualization, D.D. and F.Z.; methodology, D.D. and F.Z.; data curation, D.D.; formal analysis, D.D. and F.Z.; investigation, D.D. and F.Z.; software, D.D.; visualization, D.D.; writing—original draft preparation, D.D.; writing—review and editing, F.Z. All authors have read and agreed to the published version of the manuscript.
Funding
This research received no external funding.
Institutional Review Board Statement
The study was conducted in accordance with the Declaration of Helsinki, and approved by the Institutional Review Board of the University of Alabama in Huntsville (protocol code EE201907 approved on 12 October 2019).
Informed Consent Statement
Informed consent was obtained from all subjects involved in the study.
Data Availability Statement
The raw eye-tracking datasets that underpin the visual analyses in this study are not publicly available due to privacy and ethical restrictions. The data contain confidential student information protected under Institutional Review Board (IRB) requirements. The public release of participant-level eye gaze recordings would require explicit consent from each individual, which has not been obtained; therefore, the authors do not have authorization to disclose these data. Aggregated results and analysis procedures are included within the article. We provide detailed description of selected participants’ behavior in Appendix A of this paper.
Acknowledgments
The authors gratefully acknowledge the students enrolled and participated in the secure coding eye-tracking study. Additional thanks are due to the administrative and technical personnel whose support facilitated the execution of this study. During the preparation of this manuscript, the authors used Grammarly (web interface, version not recorded; Grammarly, Inc.), ChatGPT (web interface, GPT-5, GPT-5.1; OpenAI), and Google Search AI Mode (web interface, version not recorded; Google LLC) for limited editorial assistance, including minor rephrasing for clarity and basic grammar and style correction. The authors have reviewed and edited the output and take full responsibility for the content of this publication.
Conflicts of Interest
The authors declare no conflicts of interest. The funders had no role in the design of the study; in the collection, analyses, or interpretation of data; in the writing of the manuscript; or in the decision to publish the results.
Abbreviations
The following abbreviations are used in this manuscript:
| AOI | Area of Interest |
| AOIs | Areas of Interest |
| CWE | Common Weakness Enumeration |
| HTML | Hypertext Markup Language |
| IRB | Institutional Review Board |
| NVD | National Vulnerability Database |
| OWASP | Open Worldwide Application Security Project |
| Portable Document Format | |
| PHP | PHP: Hypertext Processor |
| RIPS | Research and Innovation to Promote Security |
| SDLC | Software Development Life Cycle |
| SQL | Structured Query Language |
| UAH | The University of Alabama in Huntsville |
| UML | Unified Modeling Language |
| UX | User Experience |
| XSS | Cross-Site Scripting |
Appendix A
Appendix A.1. Participant S14 Eye Gaze Notes for CWE-73
Participant S14 briefly read the first paragraph of instructions (in less than 10 s) and then moved into the source code file album.helper.php (at around 13 s). This coder briefly examined the other source code files in Notepad++ and the RIPS Help Instruction Guide. The secure coder started with the RIPS tool around 39 s into the session. The individual utilized the RIPS Instruction Guide to fill in the form on the RIPS tool. The coder modified the search in RIPS to only scan the specific file the coder was told contained potential security flaws. The person examined the settings for the RIPS tool. The student changed the RIPS verbosity level as indicated in the Instruction Guide (at around 72 s). The student received the first results from RIPS back around 130 s. The student struggled with using the RIPS tool because the coder kept attempting to input the specific file name to scan rather than the entire ShareAlbum codebase. At 187 s, the student got the RIPS tool to scan just the one source code file the coder was interested in. The student utilized the Notepad++ file shortcut to find the correct path location for the specific source code file. The secure coder examined the results given by RIPS and then scanned the source code files to find the issue. This secure coder utilized the Find feature of Notepad++. After seeing the create a new album function in the source code in Notepad++, the coder returned to RIPS and examined the SQL Injection help from RIPS (around 227 s). The secure coder returned and read the source code for the create a new album function. The secure coder started with the comments for the function and then the body of that function. The secure coder began modifying the source code in that function around 270 s, even though this problem was a True/False problem. The student examined the album.helper.sql.php file at around 304 s to work on this problem. The student modified the source code in the function for build sql create a new album to add an intval check around the database query. This student went back to the RIPS tool for additional scan results around 323 s. Around 343 s into working on this problem, this student returned to the Instruction Guide that was provided to them. The secure coder finished reading the instructions around 373 s. The student examined the album.helper.php source code file again. The secure coder quickly went through this source code file, searching for something. The secure coder reached the end of the file around 398 s and then returned to RIPS. The student examined the edit existing album function around 434 s. This secure coder added three more intval in album.helper.sql.php and this time around the user id session token. The secure coder returned to the instructions around 507 s to reread the question. The student returned to the RIPS tool around 547 s and attempted to search for CWE-73. The student did not appear to find the issue for file manipulation in the source code.
Appendix A.2. Participant S26 Eye Gaze Notes for CWE-73
Participant S26 spent the first 19 s reviewing the Instruction Guide provided to them. The student quickly glanced through the file names for the source code (the coder did not actually look at the source code). At 39 s, the student used the RIPS Help Instruction Guide to insert the file scan path in the RIPS web interface. This secure coder followed the instructions in the Instruction Guide to modify the RIPS search file path to the specific file that was mentioned in the instructions containing the potential vulnerability for CWE-73. However, the coder did not get the RIPS path right, so the coder turned to the RIPS Help Instruction Guide and found the correct path. The first results from RIPS came back at 121 s. This secure coder initially clicked on the vulnerability reported by RIPS that was not associated with the CWE-73 (file manipulation). At 139 s, the student returned to the Instruction Guide and started rereading the specific question. At 149 s, the student switched to the album.helper.php file and started reading the create a new album function. At 172 s, the student switched to the album.helper.sql.php file and started reading the function build sql create a new album. The student returned to the album.helper.php file at 177 s. At 180 s, the student started reading the get albums function. The student then quickly scrolled and glanced over several methods in the album.helper.php file. The student seemed to read the names of the functions in the album.helper.php file. At 205 s, the student shifted their attention back to the RIPS web interface tool and started scrolling through the report it provided. At 221 s, the student examined a cross-site scripting vulnerability reported by RIPS. At 226 s, the student examined the help popup given by RIPS but for the cross-site scripting vulnerability (not for CWE-73). The student stopped examining the cross-site scripting help report provided in RIPS at 262 s. The student then returned to the album.helper.php source code file and glanced over it. At 270 s, the student switched back to the RIPS Help Instruction Guide. At 273 s, the student switched to the album.helper.sql.php file and started reading the code in the function build sql create a new album. At 280 s, the student started scrolling in the album.helper.sql.php source code file, quickly glancing at sections of the code, primarily focusing on the comment’s description for each function. At 294 s, the student returned to the RIPS tool report and examined the File Injection vulnerability reported by RIPS. The student then quickly glanced over the report provided by RIPS for multiple different types of vulnerabilities. The student never examined the file manipulation vulnerability report in RIPS or looked at the source code in the album.helper.php associated with CWE-73.
Appendix A.3. Participant S30 Eye Gaze Notes for CWE-73
Participant S30 started the problem by reading the Instruction Guide provided to them and began at the top of that file. This secure coder moved down in a top-to-bottom fashion, reading the Instruction Guide for CWE-73. This student completed reading the Instruction Guide around 58 s into that part of the session. This secure coder then moved to the RIPS web interface. The student tried to determine what path file to give to the RIPS scanning tool. This secure coder chose to select the local host address of the ShareAlbum webpage displayed to them. This secure coder down selected the vulnerability type in RIPS to the file manipulation error. The RIPS did not return any results (due to using the wrong file scan path in the RIPS tool), and the student went back to examine the instruction sheet. The student tried to copy another path file name from the Instruction Guide into the RIPS scan file path option. The student examined the open-source code files in Notepad++ to determine their location on the hard drive to provide that as the search location for the RIPS tool to scan around 170 s. The student had several extensive fixation durations during that time (several fixations that were 2 s long). The student received the first results from RIPS around 187 s into that session. The student examined each vulnerability reported in the RIPS tool. After reviewing the overall results page from RIPS, the student read the first vulnerability Help Guide provided in RIPS. The student switched back to the source code for ShareAlbum around 308 s and examined the source code for create a new album in album.helper.php. The student spent 57 s looking into that one function, create a new album in album.helper.php. The student returned to the RIPS tool and examined the second vulnerability listed by RIPS. The student began scanning over the source code file album.helper.php around 335 s and looked for the delete this file function as indicated in RIPS as the second vulnerability. The student made several transitions between the source code for this function and the RIPS tool. The student moved on to the third vulnerability reported in RIPS around 435 s during that part of the session. This RIPS report dealt with the add a new file to album function in album.helper.php. The student moved onto the fourth RIPS issue around 560 s, and this dealt with add a new file to album, but specifically with move uploaded file, which was the security flaw. The student returned to the source code associated with this flaw and examined the code with the CWE-73 flaw. The student opened the Help Guide in RIPS associated with this security flaw to examine the example code and proof-of-concept provided by RIPS. It was interesting that the student found the source code associated with the security flaw; however, the student did not get the correct answer.
Appendix A.4. Participant S18 Eye Gaze Notes for CWE-73
Participant S18, in the first 47 s, read the paragraphs in the Instruction Guide that discussed the CWE-73 problem and how an attacker could take advantage of it. This also included reading the paragraph on the mitigation strategy. At 47 s, the student changed the web browser to open the RIPS web interface. At 50 s, the student returned to the Instruction Guide, and at 56 s, the student started selecting the file path (relative) given to the album.helper.php source code file. The student pasted that into the RIPS web interface tool and changed the filter type from ALL to file manipulation at 66 s. At 67 s, the student received their first report from the RIPS tool that did not contain any security issues (because the relative path to the source code was used). The student returned to the Instruction Guide at 73 s. The student changed to the album.helper.php source code file at 76 s and briefly examined the create a new album function. At 88 s, the student changed back to the Instruction Guide. The student returned to the RIPS tool at 93 s. At 107 s, the student returned to the Instruction Guide and examined the file path again. The student copied it again into the RIPS tool and searched again with no results from RIPS (relative path is what the coder inserted when it needed an absolute path). This secure coder switched to the RIPS Help Instruction Guide at 125 s. This secure coder copied the correct file path and pasted it into the RIPS tool. This secure coder got back their first search results from RIPS at 139 s, containing the four potential vulnerabilities that RIPS found for CWE-73. This secure coder switched back to the Instruction Guide at 143 s. The student changed to the album.helper.php source code file at 144 s and back to the Instruction Guide at 146 s. This secure coder read the attacker plan and mitigation strategy again in the Instruction Guide. This secure coder switched to the album.helper.php source code file at 172 s. At 175 s, the coder switched their attention to the RIPS tool’s first reported flaw. At 180 s, the coder opened the RIPS popup box to help with the first reported vulnerability. At 200 s, the coder opened the popup box for the source code in RIPS for the first discovered vulnerability. This secure coder closed this popup box and returned to the source code file album.helper.php and started looking into the function create a new album. This secure coder primarily focused on the body of this programming function. At 215 s, the coder returned to the RIPS tool and examined the RIPS popup box to help with the first reported vulnerability. This secure coder returned to the source code for create a new album at 236 s. This secure coder returned to the RIPS tool at 238 s and examined the RIPS popup box to help with the first reported issue by RIPS. The student returned to the source code file album.helper.php at 259 s and continued examining the body of the function create a new album. At 265 s, the student returned to the RIPS tool and started looking at the second reported issue by the RIPS tool. At 270 s, the student returned to the source code file album.helper.php and started scrolling in this source code file. The student reached the function delete this album at 279 s and stopped scrolling. At 295 s, the student opened the RIPS Help popup box associated with the second reported security flaw. At 322 s, the student examined the third reported security flaw by the RIPS tool. At 330 s, the student returned to the Instruction Guide. At 339 s, the student examined the fourth reported issue by RIPS. At 343 s, the student returned to the album.helper.php source code file. At 350 s, the student opened the RIPS source code popup box for the fourth reported security flaw. This secure coder closed the popup box after 5 s. Next, the coder returned to the Instruction Guide and reread the specific question.
Appendix A.5. Participant S24 Eye Gaze Notes for CWE-73
Participant S24 started out the session by reading the opening sentences of the Instruction Guide, and then at 16 s, the student changed to the album.helper.php source code file. The student quickly looked at the body of the first function, create a new album, before changing to the RIPS Help Instruction Guide at 22 s. The student brought into view the RIPS web interface at 26 s. At 33 s, the student changed back to the Instruction Guide provided and read the specific question that was being asked for this exercise. At 51 s, the student changed the RIPS vulnerability type to file manipulation. At 54 s, the student selected SCAN in RIPS, but the coder received no results (the coder did not give a path/file name in the RIPS tool). At 59 s, the coder changed the vulnerability type in RIPS to ALL. At 67 s, the student changed the vulnerability type in RIPS back to file manipulation. At 76 s, the students returned to the Instruction Guide and reviewed the question again. At 84 s, the student returned to the RIPS tool and examined the available options in the RIPS tool web interface. At 100 s, the student returned to the Instruction Guide and focused on the question paragraph. At 103 s, the student copied the relative path for the album.helper.php and pasted it into the RIPS tool at 108 s. The student scan returned no results (because it was a relative path). At 114 s, the student changed the filter in RIPS to ALL and got back no results. The student continued trying different file paths until 133 s, and then the student changed to the RIPS Help Instruction Guide. At 137 s, the student copied the file path as indicated in the RIPS Help Instruction Guide to the RIPS tool, and the coder got back their first RIPS result set at 148 s. At 150 s, the student changed the filter from type ALL to type file manipulation and got back the four potential vulnerabilities associated with this CWE. The student changed back to the Instruction Guide and reread the question. At 167 s, the student changed to the album.helper.php source code file. At 172 s, the student reviewed the report on the first vulnerability type returned by the RIPS tool. At 180 s, the student returned to the album.helper.php file and started reading the source code for the function create a new album. The student added a Notepad++ marker on line 20 at 181 s, which was the line that RIPS indicated had a security flaw. The student continued reading the create a new album function until 255 s, and the student returned to the first vulnerability reported in RIPS and reviewed the initial statement in the RIPS report. At 263 s, the student switched to the RIPS Help Instruction Guide and read from the top down. At 268 s, the student changed to the album.helper.sql.php file. At 271 s, the student changed back to the Instruction Guide. This student read the instructions on what to do when they finished. The student never examined the second, third, or fourth reported flaws by RIPS. The student could not get the correct answer for these reasons.
References
- National Institute of Standards and Technology (NIST). National Vulnerability Database; National Institute of Standards and Technology (NIST): Gaithersburg, MD, USA, 2013.
- Newman, M. Software Errors Cost U.S. Economy $59.5 Billion Annually NIST Assesses Technical Needs of Industry to Improve Software-Testing; NIST: Gaithersburg, MD, USA, 2002.
- Schilling, K.; Applegate, R. Best methods for evaluating educational impact: A comparison of the efficacy of commonly used measures of library instruction. J. Med. Libr. Assoc. 2012, 100, 258–269. [Google Scholar] [CrossRef] [Scilit] [PubMed]
- Jones, A.M. The use and abuse of PowerPoint in teaching and learning in the life sciences: A personal overview. Biosci. Educ. 2003, 2, 1–13. [Google Scholar] [CrossRef] [Scilit]
- Fan, M.; Shi, S.; Truong, K. Practices and Challenges of Using Think-Aloud Protocols in Industry: An International Survey. J. Usability Stud. 2020, 15, 85–102. [Google Scholar]
- Gluck, M.A.; Mercado, E.; Myers, C.E. Learning and Memory: From Brain to Behavior; Worth Publishers: New York, NY, USA, 2020. [Google Scholar]
- Busjahn, T.; Schulte, C.; Busjahn, A. Analysis of code reading to gain more insight in program comprehension. In Proceedings of the 11th Koli Calling International Conference on Computing Education Research, Koli, Finland, 17–20 November 2011. [Google Scholar]
- Rahal, R.M.; Fiedler, S. Understanding cognitive and affective mechanisms in social psychology through eye-tracking. J. Exp. Soc. Psychol. 2019, 85, 103842. [Google Scholar] [CrossRef] [Scilit]
- Rodrigues, P.; Rosa, P. Eye-Tracking as a Research Methodology in Educational Context. In Early Childhood Development: Concepts, Methodologies, Tools, and Applications; Information Science; IGI Global: Hershey, PA, USA, 2019; pp. 269–294. [Google Scholar]
- Beatty, J. Task-evoked pupillary responses, processing load, and the structure of processing resources. Psychol. Bull. 1982, 91, 276–292. [Google Scholar] [CrossRef]
- Rayner, K. Eye movements in reading and information processing: 20 years of research. Psychol. Bull. 1998, 124, 372–422. [Google Scholar] [CrossRef] [Scilit]
- Davis, D.; Zhu, F. Analysis of software developers’ coding behavior: A survey of visualization analysis techniques using eye trackers. Comput. Hum. Behav. Rep. 2022, 7, 100213. [Google Scholar] [CrossRef] [Scilit]
- Davis, D.; Zhu, F. Eye tracking technologies to visualize secure coding behavior. Array 2022, 15, 100241. [Google Scholar] [CrossRef] [Scilit]
- The MITRE Corporation. 2020 CWE Top 25 Most Dangerous Software Weaknesses; The MITRE Corporation: Bedford, MA, USA, 2020. [Google Scholar]
- The MITRE Corporation. Common Weakness Enumeration; The MITRE Corporation: Bedford, MA, USA, 2019. [Google Scholar]
- The MITRE Corporation. Overview—What Is CWE? The MITRE Corporation: Bedford, MA, USA, 2025. [Google Scholar]
- Tobii Pro. Tobii Studio User’s Manual Version 3.4.5; Tobii Pro: Stockholm, Sweden, 2016. [Google Scholar]
- Johnson, B.; Song, Y.; Murphy-Hill, E.; Bowdidge, R. Why don’t software developers use static analysis tools to find bugs? In Proceedings of the 35th International Conference on Software Engineering (ICSE), San Francisco, CA, USA, 18–26 May 2013. [Google Scholar]
- Lenarduzzi, V.; Lomio, F.; Huttunen, H.; Taibi, D. Are SonarQube Rules Inducing Bugs? In Proceedings of the IEEE 27th International Conference on Software Analysis, Evolution and Reengineering (SANER), London, ON, Canada, 18–21 February 2020. [Google Scholar]
- Duchowski, A. Eye Tracking Methodology Theory and Practice; Springer: London, UK, 2007; Volume 2. [Google Scholar]
- Smet, B.; Lempereur, L.; Sharafi, Z.; Guéhéneuc, Y.-G.; Antoniol, G.; Habra, N. Taupe: Visualizing and analyzing eye-tracking data. Sci. Comput. Program. 2014, 79, 260–278. [Google Scholar] [CrossRef] [Scilit]
- Sharif, B.; Clark, B.; Maletic, J. Studying developer gaze to empower software engineering research and practice. In FSE 2016: Proceedings of the 2016 24th ACM SIGSOFT International Symposium on Foundations of Software Engineering; Association for Computing Machinery: New York, NY, USA, 2016; pp. 940–943. [Google Scholar]
- Walters, B.; Falcone, M.; Shibble, A.; Sharif, B. Towards an eye-tracking enabled IDE for software traceability tasks. In International Workshop on Traceability in Emerging Forms of Software Engineering (TEFSE); IEEE: San Francisco, California, USA, 2013; pp. 51–54. [Google Scholar]
- Walters, B.; Shaffer, T.; Sharif, B.; Kagdi, H. Capturing software traceability links from developers’ eye gazes. In ICPC 2014: Proceedings of the 22nd International Conference on Program Comprehension; Association for Computing Machinery: New York, NY, USA, 2014; pp. 201–204. [Google Scholar]
- Ahrens, M.; Schneider, K. Improving requirements specification use by transferring attention with eye tracking data. Inf. Softw. Technol. 2020, 131, 106483. [Google Scholar] [CrossRef] [Scilit]
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2026 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license.









