Fluid Intelligence Doesn't Matter! Effects of Code Examples on the Usability of Crypto APIs

Kai Mindermann, Stefan Wagner

Research output: Chapter in Book/Report/Conference proceedingConference contributionpeer-review

1 Scopus citations

Abstract

Context : Programmers frequently look for the code of previously solved problems that they can adapt for their own problem. Despite existing example code on the web, on sites like Stack Overflow, cryptographic Application Programming Interfaces (APIs) are commonly misused. There is little known about what makes examples helpful for developers in using crypto APIs. Analogical problem solving is a psychological theory that investigates how people use known solutions to solve new problems. There is evidence that the capacity to reason and solve novel problems a.k.a Fluid Intelligence (Gf) and structurally and procedurally similar solutions support problem solving. Aim: Our goal is to understand whether similarity and Gf also have an effect in the context of using cryptographic APIs with the help of code examples. Method : We conducted a controlled experiment with 76 student participants developing with or without procedurally similar examples, one of two Java crypto libraries and measured the Gf of the participants as well as the effect on usability (effectiveness, efficiency, satisfaction) and security bugs. Results: We observed a strong effect of code examples with a high procedural similarity on all dependent variables. Fluid intelligence Gf had no effect. It also made no difference which library the participants used. Conclusions: Example code must be more highly similar to a concrete solution, not very abstract and generic to have a positive effect in a development task.

Original languageEnglish
Title of host publicationProceedings - 2020 ACM/IEEE 42nd International Conference on Software Engineering
Subtitle of host publicationCompanion, ICSE-Companion 2020
PublisherInstitute of Electrical and Electronics Engineers Inc.
Pages306-307
Number of pages2
ISBN (Electronic)9781450371223
DOIs
StatePublished - Oct 2020
Externally publishedYes
Event42nd ACM/IEEE International Conference on Software Engineering: Companion, ICSE-Companion 2020 - Seoul, Korea, Republic of
Duration: 27 Jun 202019 Jul 2020

Publication series

NameProceedings - 2020 ACM/IEEE 42nd International Conference on Software Engineering: Companion, ICSE-Companion 2020

Conference

Conference42nd ACM/IEEE International Conference on Software Engineering: Companion, ICSE-Companion 2020
Country/TerritoryKorea, Republic of
CitySeoul
Period27/06/2019/07/20

Keywords

  • Example Code
  • Intelligence
  • security
  • usability

Fingerprint

Dive into the research topics of 'Fluid Intelligence Doesn't Matter! Effects of Code Examples on the Usability of Crypto APIs'. Together they form a unique fingerprint.

Cite this