Skip to content
Free planNo credit card requiredStart writing

Search 250 million research papers

Read the abstract, see who wrote it and who cites it, and get the citation in APA, MLA, Chicago or Harvard.

About 10,000 papers for “code reuse”

Increasing Code Reuse

Alejandro Serrano Mena · Apress eBooks · 2019

Chapter 1 explained that a functional language like Haskell is characterized by its profuse use of functions as parameters or return values. However, Chapter 2 didn’t mention anything about this topic. I’ll rectify that here. In this chapter, you will focus on not one but three ways in which Haskell allows for a great amount of reuse.

Cited by 0

Inheritance – Code Reuse

Ron Dai · Apress eBooks · 2019

As one of the OOP principles, inheritance is designed to centralize the common functionality of many different objects. As a result of that, it reduces duplicated code in many classes.

Cited by 0

Understanding Code For Reuse

Stuart Marshall · 1999

The software industry currently has problems meeting the high demand for software. One proposed solution is to reuse code from old projects, however this does not seem to be working. One reason could be the time and effort required to reuse. We identify the understanding of code as a key component of the time and effort spent during reuse, and look at tools that can help programmers to better understand code. Tools can utilise two approaches to support understanding: allowing the programmer to first hand experience of executing the code, and creating visualisations from these executions. We design, implement, and evaluate a tool that uses these two approaches.

Cited by 0

Reuse code data set

Lopez-Martin, Cuauhtemoc, JIANG, Lingxiao, Treude, Christoph · Zenodo (CERN European Organization for Nuclear Research) · 2025

Data sets of reuse code obtained from Personal Software Process Projects

Cited by 0Open access

Reuse code data set

Lopez-Martin, Cuauhtemoc, JIANG, Lingxiao, Treude, Christoph · Zenodo (CERN European Organization for Nuclear Research) · 2025

Data sets of reuse code obtained from Personal Software Process Projects

Cited by 0Open access

Typesafe Code Reuse across . . .

Mikolas Janota, Bruno C. d. S. Oliveira, Viliam Holub · 2010

Writing data structures for abstract syntax trees (ASTs) in a conventional OO programming language is tedious and error-prone. Hence, programmers often use AST generators to generate OO code from a higher-level description. This article argues that the existing AST generators do not provide good support for programs that manipulate several similar structural variations of an AST. Using a conventional code generator for such family of ASTs either leads to code duplication or a loss of static type-safety. This article introduces extended ASTs (XASTs), a small language for capturing ASTs, and a code-generation algorithm for XASTs. Since XASTs are a variation of regular tree types they are ordered by a similar structural subtyping relation which is preserved by the generative algorithm. In contrast to existing AST code generators, our solution facilitates both code reuse and preserves static type-safety. We demonstrate the feasibility of our approach by providing an implementation of a code generator from XASTs to Java.

Cited by 0

Seamless Code Reuse with Source Code Corpus

Tetsuo Yamamoto, Norihiro Yoshida, Yoshiki Higo · 2013

Code reuse is attracting much attention as a promising technique for efficient software development. However, code reuse itself requires human resources: for example, searching and opening source files including code fragments that users would like to reuse, or considering keywords in using code search systems. The present paper proposes a novel technique that hardly requires such reuse cost. In the proposed technique, what programmers have to do for obtaining reusable code is just inputting a trigger key for code reuse on their development environments. Also, this paper describes some applications on OSS with a prototype tool working on Eclipse.

Cited by 4

Ada code reuse guidelines for design-for-reuse

Hyoseob Kim · Durham e-Theses (Durham University) · 1995

The phenomenal growth in the costs of producing software over the last three decades has forced the computing industry to look for alternative strategies to that implied by the waterfall model of computer system development. One frequently observed solution is that of reusing the code from previously designed systems in the construction of new ones; this technique is known as software reuse. Ada language was developed as a tool to address the above problems and is believed to have many useful language features such as package and generics to produce reusable software. But programming in Ada does not guarantee the production of highly reusable software. Therefore guidelines for users are needed to maximise the benefits from using Ada. In this thesis, Ada code reuse guidelines are proposed, and as an attempt to prove the usefulness of them, reuse metrics are studied. The thesis concludes by stressing the novelty of the approach, the difficulties encountered, and enhancements to the proposed methods to overcome these shortcomings.

Cited by 3Open access

Formative Assessment and Code Reuse

Nystad, Niklas Joakim · Duo Research Archive (University of Oslo) · 2020

Å programmere med kunnskaps-, programvare- og kodegjenbruk er vanlig og akseptert. For lærere blir dette en utfordring når det kommer til vurdering. Hva kan betraktes som elevers kunnskap og ferdigheter, og hva er ren klipping og liming? Bruken av programmering har eksplodert de siste tiårene, og fler og fler land integrerer programmering og koding i formell utdanning i distinkte IT-fag, i tillegg til i realfag og andre akademiske retninger. Dette prosjekter sikter seg inn på å finne ut hvordan kodegjenbruk i programmeringsundervisning kan relateres til formativ vurdering som undervisnings- og læringspraksis. I tillegg sikter den seg på å finne anbefalt praksis for å arbeide formativt på en hensiktsmessig og effektiv måte. Når en programmerer er gjenbruk av problemløsning, programvare, programmer og spesifikt kode både en vanlig, effektiv og anbefalt måte å skrive nye programmer, og utvikle ny programvare. Et konkret interessant didaktisk tema - formativ vurdering - har beviselig stor innvirkning på læring, og å arbeide formativt har endret måten lærere underviser og betrakter læring. I dette forskningsprosjektet har jeg siktet på å svare problemstillingen "Hva er læreres erfaringer med formativ vurdering med hensyn på kodegjenbruk i programmeringsundervisning?". Jeg har gjennomført en grounded theory intervjustudie, og spurt lærere om deres holdninger til kodegjenbruk i programmeringsundervisning, deres utfordringer med formativ vurdering samt deres anbefalinger til praksis med hensyn på kodegjenbruk i undervisningen. Dette undervisningstemaet mangler retningslinjer, og lar det være opp til den individuelle lærer hvorvidt de støtter eller avviser gjenbruk som konsept. I tillegg er holdningene til kodegjenbruk i klasserommet spredt. Noen lærere er svært åpne og positive til å inkludere det som praksis, imens andre er mer restriktive og foretrekker at elevene unngår det. Jeg har funnet utfordringer rundt kodegjenbruk som praksis på bekostning av ordentlig forståelse og trening i generelle og spesifikke programmeringsferdigheter. Til slutt har jeg funnet og presentert noen av lærernes anbefalinger til praksis for å mestre disse utfordringene. Disse inkluderer ulike formative praksiser, hensiktsmessige oppgavedesign, generell formativ undervisningspraksis, bevissthet rundt å vurdere og lære kodegjenbruk, og mer en måte å vurdere kode og programmer. Forskningsprosjektet viser at kodegjenbruk faktisk er et interessant forskningsområde også innen utdanning, og at å forske på kodegjenbruk i sammenheng med spesifikke didaktiske temaer slik som formativ vurdering kan ha stor nytteverdi med hensyn på hvordan vi underviser programmering, og hva vi kan gjøre for å øke læringsutbyttet.

Cited by 0Open access

Code-Reuse Attacks and Defenses

Lucas Davi · Technischen Universität Darmstadt · 2015

Exploitation of memory corruption vulnerabilities in widely used software has been a threat for almost three decades and no end seems to be in sight. In particular, code-reuse techniques such as return-oriented programming offer a robust attack technique that is extensively used to exploit memory corruption vulnerabilities in modern software programs (e.g. web browsers or document viewers). Whereas conventional control-flow attacks (runtime exploits) require the injection of malicious code, code-reuse attacks leverage code that is already present in the address space of an application to undermine the security model of data execution prevention (DEP). In addition, code-reuse attacks in conjunction with memory disclosure attack techniques circumvent the widely applied memory protection model of address space layout randomization (ASLR). To counter this ingenious attack strategy, several proposals for enforcement of control-flow integrity (CFI) and fine-grained code randomization have emerged. In this dissertation, we explore the limitations of existing defenses against code-reuse attacks. In particular, we demonstrate that various coarse-grained CFI solutions can be effectively undermined, even under weak adversarial assumptions. Moreover, we explore a new return-oriented programming attack technique that is solely based on indirect jump and call instructions to evade detection from defenses that perform integrity checks for return addresses. To tackle the limitations of existing defenses, this dissertation introduces the design and implementation of several new countermeasures. First, we present a generic and fine-grained CFI framework for mobile devices targeting ARM-based platforms. This framework preserves static code signatures by instrumenting mobile applications on-the-fly in memory. Second, we tackle the performance and security limitations of existing CFI defenses by introducing hardware-assisted CFI for embedded devices. To this end, we present a CFI-based hardware implementation for Intel Siskiyou Peak using dedicated CFI machine instructions. Lastly, we explore fine-grained code randomization techniques.

Cited by 11Open access

Thwarting Advanced Code-reuse Attacks

Misiker Tadesse Aga · Deep Blue (University of Michigan) · 2019

Code-reuse attacks are the leading mechanism by which attackers infiltrate systems. Various mitigation techniques have been proposed to defend against these attacks, the most prominent one being control-flow integrity (CFI). CFI is a principled approach that restricts all indirect control flows to adhere to a statically determined control-flow graph (CFG). CFI has gained widespread adoption in industry -- such as Microsoft Control Flow Guard and Intel Control-flow Enforcement Technology. However, recent attacks dubbed CFG mimicry attacks, like control flow bending and counterfeit object-oriented programming, have shown that code-reuse attacks are still possible without violating CFI. Furthermore, data-oriented programming (DOP) has generalized non-control data attacks to achieve Turing-complete computation; it accomplishes this by repeatedly corrupting non-control data to execute a sequence of instructions within the legitimate control flow of the program. In this dissertation, we present techniques to mitigate these advanced code-reuse attacks. First, this dissertation presents a novel approach to thwart advanced control flow attacks called ProxyCFI. ProxyCFI replaces all code pointers in a program with a less powerful construct: pointer proxies. Pointer proxies are random identifiers associated with each legitimate control flow edge in the program. Pointer proxy values are defined per-function and are re-randomized at program load time to mitigate their disclosure. To ensure that the approach covers the entire control flow of the program, we have a load-time verifier built-in the program loader that performs reachability analyses of the code and verify that there is no vulnerable control flow transfer. ProxyCFI delivers these protections incurring minimal performance overhead, while stopping a broad range of real-world attacks and achieving a 100% coverage of the RIPE x86-64 attack suite. Second, this dissertation evaluates the effectiveness of previously proposed stack layout randomization techniques against attacks that only utilize relative offset between allocations (e.g., data-oriented programming) and demonstrate that they are ineffective at stopping real-world DOP exploits. We then propose Smokestack, a runtime stack-layout randomization technique that addresses the problems with prior approaches. Smokestack instruments programs to randomize their stack layout at runtime for each invocation of a function. By doing so, Smokestack minimizes the utility of information gained in the probes of chained DOP attacks for later attack stages. Our evaluation on SPEC benchmarks and various real-world applications shows that Smokestack, with a cryptographically secure pseudo random generator, can stop DOP attacks with an average slowdown of 8.7%. Lastly, we present a technique to randomize heap allocations at runtime to prevent attackers from orchestrating advanced control flow attacks as well as DOP attacks through heap-resident variables. To this end, we explored the use of multi-variant execution (MVX) with each variant having uniquely seeded random heap allocators. This capability enables our system to automatically track heap allocation pointers without the need for storing explicit meta-data. We then re-randomize heap allocations to thwart attacks that perform runtime probes to discover allocations. This technique will provide modular heap allocation protection while maintaining compatibility with legacy binaries. In all, this thesis presents novel techniques that carve out a new space in advanced code-reuse attack protections, offering a protection strength as good or better than prior solutions. These techniques provide additional protections for advanced control flow attacks and DOP attacks, while incurring minimal performance overheads.

Cited by 1Open access

Reuse for Code-Level Generalization

Alison Teoh · 2011

This paper describes how code reuse combined with good programming practices can also be used as a means to attain code-level generalization of certain programs. It presents some basic principles to be used when refactoring code for reuse and presents a case study in which the functionality of two AI planners are easily combined via application of these principles. 1.

Cited by 0

Code Reuse With Transformation Objects

Dmitry Boulytchev · arXiv (Cornell University) · 2018

We present an approach for a lightweight datatype-generic programming in Objective Caml programming language aimed at better code reuse. We show, that a large class of transformations usually expressed via recursive functions with pattern matching can be implemented using the single per-type traversal function and the set of object-encoded transformations, which we call transformation objects. Object encoding allows transformations to be modified, inherited and extended in a conventional object-oriented manner. However, the data representation is kept untouched which preserves the ability to construct and pattern-match it in the usual way. Our approach equally works for regular and polymorphic variant types which makes it possible to combine data types and their transformations from statically typed and separately compiled components. We also present an implementation which allows us to automatically derive most functionality from a slightly augmented type descriptions.

Cited by 0Open access

Test Code Reuse from OSS

Soha Makady, Robert J. Walker · 2017

We are told of the significant benefits of automated approaches to testing over manual approaches. However, it is unclear what automated testing practices exist, and how efficient or widespread such practices are within open source software. Although some organizations rigorously apply automated testing to their software, this rich pool of test code is not utilized to serve existing source code with poor or no test suites. To investigate how automated testing is performed in practice, we attempted a thorough, large-scale analysis of open source repositories. Alongside this analysis, we propose a novel approach to reuse such existing tests within projects that lack test code, hence leveraging the quality of such projects with minimal developer intervention. While such an analysis seems to be a straightforward task, we report on various practical challenges that hindered applying our proposed approach for tests' reuse. We present the challenges we have addressed so far, and those we expect to appear in the near future, in applying our approach for test reuse with open source projects. We outline potential solutions to the projected future challenges.

Cited by 3