DE102022203357A1 - FUZZING WITH SOFTWARE COVERAGE FEEDBACK THROUGH DYNAMIC INSTRUMENTATION BASED ON DISTANCES OF INSTRUCTION BLOCKS IN CONTROL FLOW GRAPH - Google Patents

FUZZING WITH SOFTWARE COVERAGE FEEDBACK THROUGH DYNAMIC INSTRUMENTATION BASED ON DISTANCES OF INSTRUCTION BLOCKS IN CONTROL FLOW GRAPH Download PDF

Info

Publication number
DE102022203357A1
DE102022203357A1 DE102022203357.4A DE102022203357A DE102022203357A1 DE 102022203357 A1 DE102022203357 A1 DE 102022203357A1 DE 102022203357 A DE102022203357 A DE 102022203357A DE 102022203357 A1 DE102022203357 A1 DE 102022203357A1
Authority
DE
Germany
Prior art keywords
fuzzing
software
instruction
instruction block
breakpoint
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
DE102022203357.4A
Other languages
German (de)
Inventor
Max Camillo Eisele
Christopher Huth
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Robert Bosch GmbH
Original Assignee
Robert Bosch GmbH
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Robert Bosch GmbH filed Critical Robert Bosch GmbH
Priority to DE102022203357.4A priority Critical patent/DE102022203357A1/en
Priority to CN202310356784.0A priority patent/CN116893956A/en
Publication of DE102022203357A1 publication Critical patent/DE102022203357A1/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3676Test management for coverage analysis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3684Test management for test design, e.g. generating new test cases
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/40Transformation of program code
    • G06F8/41Compilation
    • G06F8/43Checking; Contextual analysis
    • G06F8/433Dependency analysis; Data or control flow analysis

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Software Systems (AREA)
  • Debugging And Monitoring (AREA)

Abstract

Ein erster Aspekt der vorliegenden Offenbarung betrifft ein computer-implementiertes Verfahren zur Erlangung von Softwareabdeckungsfeedback beim Fuzzing einer Software auf einem Hardware-Target, wobei das Hardware-Target mindestens ein Haltepunktregister aufweist und dafür ausgelegt ist, eine Ausführung der Software vor Ausführung einer Anweisung der Software anzuhalten, wenn die Anweisung bei der Ausführung der Software erreicht wird und eine Speicheradresse der Anweisung in dem mindestens einen Haltepunkteregister gesetzt ist, umfassend Auswählen eines ersten Anweisungsblocks der Software; Setzen eines ersten Haltepunkts vor einer Anweisung des ersten Anweisungsblocks in dem mindestens einen Haltepunktregister; erstes Ausführen oder erstes Fortsetzen einer Fuzzing-Iteration der Software; erstes Prüfen, ob der erste Haltepunkt beim ersten Ausführen oder ersten Fortsetzen der Fuzzing-Iteration erreicht wird; Speichern einer ersten Protokollinformation umfassend, dass der erste Anweisungsblock in der Fuzzing-Iteration erreicht worden ist - und, optional, Löschen des ersten Haltepunkts - wenn das erste Prüfen positiv ausfällt. Das Softwareabdeckungsfeedback beim Fuzzing der Software umfasst die erste Protokollinformation. Das Auswählen des ersten Anweisungsblocks der Software kann auf Abständen, optional Abstandsgewichten, von Anweisungsblöcken zu mindestens einem beim Fuzzing erreichten Anweisungsblock in einem Kontrollflussgraphen der Software basieren.A first aspect of the present disclosure relates to a computer-implemented method for obtaining software coverage feedback when fuzzing software on a hardware target, wherein the hardware target has at least one breakpoint register and is configured to require execution of the software before executing an instruction of the software stopping when the instruction is reached in execution of the software and a memory address of the instruction is set in the at least one breakpoint register, comprising selecting a first instruction block of the software; setting a first breakpoint before an instruction of the first instruction block in the at least one breakpoint register; first running or resuming a fuzzing iteration of the software; first checking whether the first breakpoint is reached the first time the fuzzing iteration is executed or resumed; storing first protocol information including that the first instruction block has been reached in the fuzzing iteration - and, optionally, deleting the first breakpoint - if the first check is positive. The software coverage feedback when fuzzing the software includes the first protocol information. Selecting the first instruction block of the software may be based on distances, optionally distance weights, from instruction blocks to at least one instruction block reached during fuzzing in a control flow graph of the software.

Description

Stand der TechnikState of the art

Fuzzing (englisch: fuzzing oder fuzz testing) ist eine automatisierte Technik zum Testen einer Software. Hierbei wird in einer Vielzahl von Fuzzing-Iterationen die Software mit ungültigen, unerwarteten und/oder zufälligen Eingangsdaten ausgeführt und dabei auf Ausnahmen (englisch: exceptions) wie Abstürze, fehlgeschlagene eingebaute Code-Zusicherungen (englisch: assertions), potenzielle Speicherlecks, etc. überwacht. Für Software, deren Eingangsdaten in einer vorbestimmten Datenstruktur vorliegen müssen, können Fuzzer (englisch: fuzzers), die für diese vorbestimmte Datenstruktur ausgelegt sind, zum Einsatz kommen. Die vorbestimmte Datenstruktur ist zum Beispiel in einem Dateiformat und/oder Protokoll spezifiziert. Ein (effizienter) Fuzzer ist dafür ausgelegt, ungültige, unerwartete und/oder zufällige Eingangsdaten in der vorbestimmten Datenstruktur zu generieren, so dass eine Ausführung einer jeweiligen Fuzzing-Iteration der Software ohne Parse-Fehler auf Basis der Eingangsdaten gestartet werden kann. Durch Fuzzing kann insbesondere in komplexer Software (wie z.B. Software für die Steuerung, Regelung und/oder Überwachung eines technischen Systems) unerwartetes Verhalten wie z.B. unerwartete (Progamm)pfade und/oder Programmierfehler sowie Randfälle ermittelt werden. Durch ein derart erlangtes besseres Softwareverständnis können die Software und insbesondere deren Sicherheit verbessert werden.Fuzzing (English: fuzzing or fuzz testing) is an automated technique for testing software. This involves running the software with invalid, unexpected and/or random input data in a variety of fuzzing iterations and monitoring for exceptions such as crashes, failed built-in code assertions, potential memory leaks, etc . For software whose input data must be in a predetermined data structure, fuzzers that are designed for this predetermined data structure can be used. The predetermined data structure is specified, for example, in a file format and/or protocol. An (efficient) fuzzer is designed to generate invalid, unexpected and/or random input data in the predetermined data structure so that execution of a respective fuzzing iteration of the software can be started based on the input data without parse errors. Fuzzing can be used to identify unexpected behavior such as unexpected (program) paths and/or programming errors as well as edge cases, particularly in complex software (such as software for the control, regulation and/or monitoring of a technical system). By gaining a better understanding of software in this way, the software and in particular its security can be improved.

Ein Fuzzing-Target kann eine Software (z.B. ein Programm) und/oder ein Teil davon (z.B. eine Funktion) sein, die durch Fuzzing getestet werden soll. Das Fuzzing-Target kann dergestalt sein, dass es potenziell nicht vertrauenswürdige Eingangsdaten akzeptiert, die beim Fuzzing durch einen Fuzzer für eine Vielzahl von Fuzzing-Iterationen generiert werden können. In diesem Zusammenhang kann Fuzzing als der automatisierte Vorgang gesehen werden, beliebige und insbesondere ungültige, unerwartete und/oder zufällige Eingangsdaten an das Fuzzing-Target zu schicken und dessen Reaktion sodann während der Ausführung dieser Fuzzing-Iteration zu beobachten. Der Fuzzer oder die Fuzzing-Maschine ist ein Computer-Programm, das dafür ausgelegt ist, automatisiert Eingangsdaten je Fuzzing-Iteration für das Fuzzing-Target zu generieren. Der Fuzzer ist nicht Teil des Fuzzing-Targets, sondern unabhängig vom Fuzzing-Target. In der Regel sind Fuzzer nicht instrumentiert. Ein bekannter Fuzzer ist zum Beispiel afl oder libfuzzer. Die Kombination aus einem Fuzzing-Target und einem dazugehörigen Fuzzer kann als Fuzzing-Test bezeichnet werden. Der Fuzzing-Test ist ausführbar. Der Fuzzer kann jeweils unterschiedliche (Fuzzing-)Eingangsdaten für eine Vielzahl von Fuzzing-Iterationen - z.B. hunderte oder tausende Fuzzing-Iterationen pro Sekunde - generieren und jeweils einen Fuzzing-Test mit den dazugehörigen Eingangsdaten starten, beobachten, und gegebenenfalls auch anhalten. Eine Fuzzing-Iteration umfasst eine Ausführung des Fuzzing-Targets/der Software ausgehend von für diese Fuzzing-Iteration generierten (Fuzzing-) Eingangsdaten. Durch Speichern der jeweiligen Eingangsdaten, kann die Fuzzing-Iteration, insbesondere, wenn ein unerwartetes Verhalten der Software während der Fuzzing-Iteration (z.B. noch nicht bekannte Pfade und/oder Programmierfehler) erkannt wurde, zu einem späteren Zeitpunkt reproduziert werden, wobei dann das Fuzzing-Target ohne Fuzzer aber auf den gespeicherten (Fuzzing-) Eingangsdaten ausgeführt werden kann.A fuzzing target can be software (e.g. a program) and/or a part of it (e.g. a function) that is to be tested by fuzzing. The fuzzing target may be such that it accepts potentially untrusted input data that may be generated when fuzzing by a fuzzer for a variety of fuzzing iterations. In this context, fuzzing can be seen as the automated process of sending arbitrary and especially invalid, unexpected and/or random input data to the fuzzing target and then observing its response during the execution of this fuzzing iteration. The fuzzer or fuzzing machine is a computer program designed to automatically generate input data for the fuzzing target per fuzzing iteration. The fuzzer is not part of the fuzzing target, but is independent of the fuzzing target. As a rule, fuzzers are not instrumented. A well-known fuzzer is, for example, afl or libfuzzer. The combination of a fuzzing target and an associated fuzzer can be referred to as a fuzzing test. The fuzzing test is executable. The fuzzer can generate different (fuzzing) input data for a large number of fuzzing iterations - e.g. hundreds or thousands of fuzzing iterations per second - and can start, observe and, if necessary, stop a fuzzing test with the associated input data. A fuzzing iteration includes an execution of the fuzzing target/software based on (fuzzing) input data generated for this fuzzing iteration. By saving the respective input data, the fuzzing iteration can be reproduced at a later point in time, in particular if unexpected behavior of the software was detected during the fuzzing iteration (e.g. not yet known paths and/or programming errors), in which case the fuzzing -Target can be executed without a fuzzer but on the stored (fuzzing) input data.

Während der Ausführung eines Fuzzing-Tests können Informationen aus dem Software-Target ausgegeben werden. Ein solches Softwareabdeckungsfeedback (englisch: coverage-guided fuzzing) kann vorteilhafterweise beim Fuzzing genutzt werden, um noch nicht bekannte Pfade/Blöcke zu erkennen und/oder Programmierfehler in der Software zu lokalisieren. Softwareabdeckungsfeedback beim Fuzzing kann zum Beispiel wie bei afl durch statische Instrumentierung des Fuzzing-Targets realisiert werden. Bei der statischen Instrumentierung wird das Fuzzing-Target - d.h. die Software - (zum Beispiel beim Kompilieren) dahingehend geändert, dass Informationen über zum Beispiel zuletzt ausgeführte Anweisungen in der Software und/oder (Programm)pfade bei der Ausführung der Software und insbesondere während einer Fuzzing-Iteration abgerufen werden können. Alternativ oder zusätzlich kann Softwareabdeckungsfeedback aus einer dynamischen Instrumentierung erlangt werden. Hierbei wird über Systemfunktionalitäten und/oder Emulatoren die Ausführung der Software zur Laufzeit gesteuert, um Informationen über die Abläufe in der Software zu erhalten. Softwareabdeckungsfeedback durch dynamische Instrumentierung ist insbesondere dann vorteilhaft, wenn die Software in kompilierter Form (englisch: closed-source) vorliegt.During the execution of a fuzzing test, information from the software target can be output. Such software coverage feedback (coverage-guided fuzzing) can advantageously be used during fuzzing to detect paths/blocks that are not yet known and/or to localize programming errors in the software. For example, as with afl, software coverage feedback in fuzzing can be realized by static instrumentation of the fuzzing target. With static instrumentation, the fuzzing target - i.e. the software - is changed (for example when compiling) so that information about, for example, last executed instructions in the software and / or (program) paths during the execution of the software and in particular during a Fuzzing iteration can be retrieved. Alternatively or additionally, software coverage feedback can be obtained from dynamic instrumentation. The execution of the software is controlled at runtime using system functionalities and/or emulators in order to obtain information about the processes in the software. Software coverage feedback through dynamic instrumentation is particularly advantageous when the software is in compiled form (closed source).

JinSeok Oh, Sungyu Kim, Eunji Jeong, and Soo-Mook Moon, „Os-less dynamic binary instrumentation for embedded firmware“, in 2015 IEEE Symposium in LowPower and High-Speed Chips (COOL CHIPS XVIII), pages 1-3. IEEE, 2015 offenbaren eine dynamische Instrumentierung über Debugger und Haltepunkte, die auf Software-Interrupts basiert. Dabei wird aktiv der Binärcode (englisch: binary) der Software verändert und eine Instruktion durch eine Software-Interrupt-Instruktion ersetzt.JinSeok Oh, Sungyu Kim, Eunji Jeong, and Soo-Mook Moon, “Os-less dynamic binary instrumentation for embedded firmware,” in 2015 IEEE Symposium in LowPower and High-Speed Chips (COOL CHIPS XVIII), pages 1-3. IEEE, 2015 disclose dynamic instrumentation via debuggers and breakpoints based on software interrupts. The binary code of the software is actively changed and an instruction is replaced by a software interrupt instruction.

Offenbarung der ErfindungDisclosure of the invention

Ein erster allgemeiner Aspekt der vorliegenden Offenbarung betrifft ein computer-implementiertes Verfahren zur Erlangung von Softwareabdeckungsfeedback beim Fuzzing einer Software auf einem Hardware-Target, wobei das Hardware-Target mindestens ein Haltepunktregister aufweist und dafür ausgelegt ist, eine Ausführung der Software vor Ausführung einer Anweisung der Software anzuhalten, wenn die Anweisung bei der Ausführung der Software erreicht wird und eine Speicheradresse der Anweisung in dem mindestens einen Haltepunkteregister gesetzt ist. Das Verfahren umfasst Auswählen eines ersten Anweisungsblocks der Software. Das Verfahren umfasst weiterhin Setzen eines ersten Haltepunkts vor einer Anweisung des ersten Anweisungsblocks in dem mindestens einen Haltepunktregister. Das Verfahren umfasst weiterhin erstes Ausführen oder erstes Fortsetzen einer Fuzzing-Iteration der Software. Das Verfahren umfasst weiterhin erstes Prüfen, ob der erste Haltepunkt beim ersten Ausführen oder ersten Fortsetzen der Fuzzing-Iteration erreicht wird. Das Verfahren umfasst weiterhin Speichern einer ersten Protokollinformation umfassend, dass der erste Anweisungsblock in der Fuzzing-Iteration erreicht worden ist, wenn das erste Prüfen positiv ausfällt. Das Verfahren kann Löschen des ersten Haltepunkts, wenn das erste Prüfen positiv ausfällt, umfassen. Das Softwareabdeckungsfeedback beim Fuzzing der Software kann die erste Protokollinformation umfassen. Das Auswählen des ersten Anweisungsblocks der Software kann auf Abständen von Anweisungsblöcken zu mindestens einem beim Fuzzing (z.B. bei einer früheren Fuzzing-Iteration oder bei der Fuzzing-Iteration der Software) erreichten Anweisungsblock in einem Kontrollflussgraphen der Software basieren. Alternativ oder zusätzlich kann das Auswählen des ersten Anweisungsblocks der Software auf Abstandsgewichten von Anweisungsblöcken zu mindestens einem beim Fuzzing (z.B. bei einer früheren Fuzzing-Iteration oder bei der Fuzzing-Iteration der Software) erreichten Anweisungsblock in einem Kontrollflussgraphen der Software basieren.A first general aspect of the present disclosure relates to a computer-implemented method for obtaining software coverage feedback when fuzzing software on a hardware target, the hardware target having at least one breakpoint register and being configured to require execution of the software before executing an instruction of the To stop software when the instruction is reached during execution of the software and a memory address of the instruction is set in the at least one breakpoint register. The method includes selecting a first instruction block of the software. The method further comprises setting a first breakpoint before an instruction of the first instruction block in the at least one breakpoint register. The method further includes first executing or first resuming a fuzzing iteration of the software. The method further includes first checking whether the first breakpoint is reached when the fuzzing iteration is first executed or continued. The method further comprises storing first protocol information including that the first instruction block has been reached in the fuzzing iteration if the first check is positive. The method may include deleting the first breakpoint if the first check is positive. The software coverage feedback when fuzzing the software may include the first protocol information. Selecting the first instruction block of the software may be based on distances of instruction blocks from at least one instruction block reached during fuzzing (e.g., in a previous fuzzing iteration or in the fuzzing iteration of the software) in a control flow graph of the software. Alternatively or additionally, selecting the first instruction block of the software may be based on distance weights of instruction blocks to at least one instruction block reached during fuzzing (e.g. in a previous fuzzing iteration or in the fuzzing iteration of the software) in a control flow graph of the software.

Ein zweiter allgemeiner Aspekt der vorliegenden Offenbarung betrifft ein Computer-System, das dafür ausgelegt ist, das computer-implementierte Verfahren zur Erlangung von Softwareabdeckungsfeedback beim Fuzzing der Software auf dem Hardware-Target nach dem ersten allgemeinen Aspekt (oder einer Ausführungsform davon) auszuführen.A second general aspect of the present disclosure relates to a computer system configured to execute the computer-implemented method for obtaining software coverage feedback when fuzzing the software on the hardware target according to the first general aspect (or an embodiment thereof).

Ein dritter allgemeiner Aspekt der vorliegenden Offenbarung betrifft ein Computer-Programm, das dafür ausgelegt ist, das computer-implementierte Verfahren zur Erlangung von Softwareabdeckungsfeedback beim Fuzzing der Software auf dem Hardware-Target nach dem ersten allgemeinen Aspekt (oder einer Ausführungsform davon) auszuführen.A third general aspect of the present disclosure relates to a computer program configured to execute the computer-implemented method for obtaining software coverage feedback when fuzzing the software on the hardware target according to the first general aspect (or an embodiment thereof).

Ein vierter allgemeiner Aspekt der vorliegenden Offenbarung betrifft ein computer-lesbares Medium oder Signal, das das Computer-Programm nach dem dritten allgemeinen Aspekt (oder einer Ausführungsform davon) speichert und/oder enthält.A fourth general aspect of the present disclosure relates to a computer-readable medium or signal that stores and/or contains the computer program according to the third general aspect (or an embodiment thereof).

Das in dieser Offenbarung vorgeschlagene Verfahren nach dem ersten Aspekt (oder einer Ausführungsform davon) ist auf die Erlangung von Softwareabdeckungsfeedback beim Fuzzing einer Software auf einem Hardware-Target gerichtet, insbesondere wenn die Software an sich oder auf dem Hardware-Target nicht statisch instrumentiert werden kann.The method according to the first aspect (or an embodiment thereof) proposed in this disclosure is directed to obtaining software coverage feedback when fuzzing software on a hardware target, particularly when the software itself or on the hardware target cannot be statically instrumented .

Für Computersysteme wie Desktop-Systeme (PC etc.) und insbesondere für Software die in Form eines Programmiercodes vorliegt (z.B. open source) ist die statische Instrumentierung eine bekannte Methode, um Softwareabdeckungsfeedback beim Ausführen der Software und insbesondere während einer Fuzzing-Iteration der Software zu erlangen.For computer systems such as desktop systems (PC etc.) and especially for software that is in the form of programming code (e.g. open source), static instrumentation is a well-known method to provide software coverage feedback when executing the software and especially during a fuzzing iteration of the software gain.

Die statische Instrumentierung für das Fuzzing kann jedoch bei Software, die auf einem eingebetteten System (englisch: embedded system), das in einem technischen Kontext eingebunden ist, ausgeführt wird, aus den folgenden Gründen schwierig sein: Der für das Fuzzing erforderliche Fuzzer muss typischerweise (z.B. aus Mangel an Rechen- und/oder Speicherkapazität im eingebetteten System) auf einem anderen Rechner ausgeführt werden. Daraus ergibt sich, dass Softwareabdeckungsfeedback aus dem eingebetteten System erst zu dem Fuzzer (oder einem anderen Rechner) transferiert werden muss. Weiterhin muss typischerweise ein Gesamtsystem getestet werden, dass durchaus eine Vielzahl von Komponenten umfassen kann. Die Software für das Gesamtsystem kann Drittparteibibliotheken und Softwarekomponenten anderer Zulieferer und/oder Kunden aufweisen. Häufig werden solche Softwarekomponenten als Binärdateien (d.h. in kompilierter Form, auch: Binärcode) geliefert, die nicht oder nur mit Aufwand modifiziert werden können. Da solche Softwarekomponenten nicht mehr kompiliert werden, können sie nur mit Aufwand statisch instrumentiert werden. Dagegen kann Software (oder Softwarekomponenten davon), die als Programmiercode vorliegt, leicht beim Kompilieren statisch instrumentiert werden. Allerdings nimmt die Größe der Software in jedem Fall durch die statische Instrumentierung zu, so dass häufig aufgrund der typischerweise beschränkten Ressourcen die statisch instrumentierte Software nicht mehr in den Speicher des eingebetteten Systems passt. Dasselbe gilt für weitere Funktionalitäten, um die die Software für das Fuzzing erweitert werden kann.However, static instrumentation for fuzzing can be difficult for software running on an embedded system embedded in an engineering context for the following reasons: The fuzzer required for fuzzing typically needs to be ( e.g. due to lack of computing and/or storage capacity in the embedded system) must be executed on another computer. This means that software coverage feedback from the embedded system must first be transferred to the fuzzer (or another computer). Furthermore, an entire system must typically be tested, which may well include a large number of components. The software for the overall system may include third-party libraries and software components from other suppliers and/or customers. Such software components are often delivered as binary files (ie in compiled form, also: binary code), which cannot be modified or can only be modified with great effort. Since such software components are no longer compiled, they can only be statically instrumented with great effort. On the other hand, software (or software components thereof) that exist as programming code is easy to statically instrument at compile time. However, the size of the software increases in any case due to static instrumentation, so that the statically instrumented software often no longer fits into the memory of the embedded system due to the typically limited resources. The same applies to other functionalities that can be added to the software for fuzzing.

In einer alternativen Herangehensweise kann die Software des eingebetteten Systems in einem Emulator wie z.B. QEMU ausgeführt werden. Hierbei kann die Transparenz und Konfigurierbarkeit des Emulators dazu genutzt werden, das Softwareabdeckungsfeedback während des Fuzzing bereitzustellen. Leider ist die Einrichtung eines solchen Emulators für ein spezifisches Hardware-Target mit einem enormen Arbeitsaufwand verbunden, da typischerweise die Funktionalität der Software des eingebetteten Systems auf der Verfügbarkeit externer Hardware-Komponenten wie Sensoren und/oder Aktuatoren basiert. Fehlen allerdings solche Hardware-Komponenten in dem Emulator, kann die Software nicht unter denen Bedingungen getestet werden, für die sie eigentlich konzipiert ist. In der Tat wird sich die Software in diesem Fall anders verhalten als im Kontext des für sie konzipierten technischen Systems. Das kann sich zum Beispiel darin äußern, dass die Software wahrscheinlich andere Pfade durchlaufen wird, die nur bedingt mit dem eigentlichen Einsatzzweck der Software zu tun haben. Der Einsatz eines Emulators zwecks Softwareabdeckungsfeedback beim Fuzzing ist somit weniger geeignet.In an alternative approach, the embedded system software can be run in an emulator such as QEMU. Here, the transparency and configurability of the emulator can be used to provide software coverage feedback during fuzzing. Unfortunately, setting up such an emulator for a specific hardware target involves an enormous amount of work, as typically the functionality of the embedded system's software is based on the availability of external hardware components such as sensors and/or actuators. However, if such hardware components are missing from the emulator, the software cannot be tested under the conditions for which it was actually designed. In fact, in this case the software will behave differently than in the context of the technical system designed for it. This can be expressed, for example, in the fact that the software will probably follow other paths that only have a limited connection with the actual purpose of the software. The use of an emulator for software coverage feedback during fuzzing is therefore less suitable.

Wird ein Debugger mit dem eingebetteten System verbunden, können Haltepunkt-Anweisungen (über mindestens ein Hardware-Haltepunktregister) genutzt werden, um die Ausführung der Software im eingebetteten System an einer gezielten Position im Code anzuhalten. Allerdings wird man nicht durch beliebige Haltepunkte ein annährend komplettes Softwareabdeckungsfeedback erhalten können, da die Anzahl der gleichzeitig aktiven Haltepunkte normalerweise stark limitiert ist. Zum Beispiel ist ein ARM Cortex-MO Mikrokontroller für maximal vier gleichzeitig aktive Hardware-Haltepunkte ausgelegt.When a debugger is connected to the embedded system, breakpoint instructions (via at least one hardware breakpoint register) can be used to stop the execution of software in the embedded system at a specific location in the code. However, it will not be possible to obtain almost complete software coverage feedback using arbitrary breakpoints, as the number of simultaneously active breakpoints is usually very limited. For example, an ARM Cortex-MO microcontroller is designed for a maximum of four simultaneously active hardware breakpoints.

Das in dieser Offenbarung vorgeschlagene Verfahren nach dem ersten Aspekt (oder einer Ausführungsform davon) eignet sich besonders für das Fuzzing auf einem Hardware-Target/eingebetteten System und im (typischen) Fall, dass die Anzahl der Haltepunkte stark limitiert ist. Wie bereits ausgeführt, kann die Software durch das Fuzzing auf dem (echten) Hardware-Target - im Gegensatz zum Emulator - realistischer und somit besser getestet werden. Für das Verfahren ist es ausreichend, wenn das Hardware-Target mindestens einen Haltepunkt zulässt. Ausgehend von z.B. einer Startanweisung, die zumeist spezifiziert ist, kann dank des in dieser Offenbarung vorgeschlagenen Verfahrens und insbesondere durch ein systematisches Abfahren von Anweisungen durch strategisches Setzen mindestens eines Haltepunkts ein/der Kontrollflussgraphen der Software zumindest zu dem durch die Fuzzing-Iteration abgedeckten Teil der Software ermittelt und/oder erprobt werden. Tritt unerwartetes Verhalten während einer Fuzzing-Iteration auf, kann das Softwareabdeckungsfeedback dazu genutzt werden, die Software und insbesondere deren Sicherheit durch eine Software-Änderung zu verbessern. Dadurch kann weiterhin die Funktionalität und insbesondere die Sicherheit des durch die Software gesteuerten, geregelten und/oder überwachten eingebetteten Systems verbessert werden.The method according to the first aspect (or an embodiment thereof) proposed in this disclosure is particularly suitable for fuzzing on a hardware target/embedded system and in the (typical) case where the number of breakpoints is highly limited. As already explained, the software can be tested more realistically and therefore better thanks to fuzzing on the (real) hardware target - in contrast to the emulator. For the method, it is sufficient if the hardware target allows at least one breakpoint. Starting from, for example, a start instruction, which is mostly specified, thanks to the method proposed in this disclosure and in particular by systematically executing instructions by strategically setting at least one breakpoint, one of the control flow graphs of the software can be at least to the part of the software covered by the fuzzing iteration Software can be identified and/or tested. If unexpected behavior occurs during a fuzzing iteration, the software coverage feedback can be used to improve the software and especially its security through a software change. This can further improve the functionality and in particular the security of the embedded system controlled, regulated and/or monitored by the software.

Ein im Stand der Technik (Oh et al., siehe oben) bekanntes Verfahren für die dynamische Instrumentierung über Debugger und Haltepunkte auf Basis von Software-Interrupts könnte im Lichte der vorliegenden Offenbarung ebenfalls zur Erlangung von Softwareabdeckungsfeedback beim Fuzzing der Software auf dem Hardware-Target eingesetzt werden. Zum Beispiel kann das bereits beschriebene Ersetzen einer Instruktion durch eine Software-Interrupt-Instruktion mehrfach wiederholt werden und dadurch verschiedene Haltepunkte gesetzt werden. Dabei muss allerdings der Speicher bei jeder Wiederholung neu geschrieben werden. Bei den genutzten EEPROM/Flash Speichern in Mikrocontrollern führt das jedoch zu einem erheblichen Overhead. Die Erlangung von Softwareabdeckungsfeedback beim Fuzzing der Software auf dem Hardware-Target via Software-Interrupts wird dadurch ineffizient oder gar impraktikabel.A method known in the prior art (Oh et al., supra) for dynamic instrumentation via debuggers and breakpoints based on software interrupts could, in light of the present disclosure, also be used to obtain software coverage feedback when fuzzing the software on the hardware target be used. For example, the already described replacement of an instruction with a software interrupt instruction can be repeated several times, thereby setting different breakpoints. However, the memory has to be rewritten with each repetition. However, with the EEPROM/Flash memories used in microcontrollers, this leads to considerable overhead. Obtaining software coverage feedback when fuzzing the software on the hardware target via software interrupts becomes inefficient or even impractical.

Stattdessen werden in dem in dieser Offenbarung vorgeschlagenen Verfahren Hardware-Haltepunkte (via das mindestens eine Hardware-Haltepunktregister) gesetzt. Vorteilhaft erweist sich dabei, dass Hardware-Haltepunkte ohne großen Overhead gesetzt werden können. Somit kann Softwareabdeckungsfeedback beim Fuzzing der Software auf dem Hardware-Target effizient und somit schnell erlangt werden.Instead, in the method proposed in this disclosure, hardware breakpoints are set (via the at least one hardware breakpoint register). The advantage here is that hardware breakpoints can be set without much overhead. Thus, software coverage feedback can be obtained efficiently and therefore quickly when fuzzing the software on the hardware target.

Das in dieser Offenbarung vorgeschlagene Verfahren ist weiterhin auch in Anwendungsfällen (z.B. zum Testen/Erproben existierender Produkte) geeignet, in denen die Software aus einem Nur-Lese-Speicher (englisch: ROM, read-only memory) des Hardware-Targets ausgeführt wird. In diesem Fall ist das Ersetzen von Anweisungen im Binärcode der Software durch Software-Interrupt-Instruktionen, wenn überhaupt, nur mit erheblichem Aufwand möglich.The method proposed in this disclosure is also suitable in applications (e.g. for testing/testing existing products) in which the software is executed from a read-only memory (ROM) of the hardware target. In this case, replacing instructions in the software binary code with software interrupt instructions is only possible with considerable effort, if at all.

In dem in dieser Offenbarung vorgeschlagenen Verfahren nach dem ersten Aspekt (oder einer Ausführungsform davon) umfasst das strategische Setzen (oder Auswählen) des mindestens einen Haltepunkts oder z.B. jeweils eines Haltepunkts je vorhandenem Hardware-Haltepunktregister - es können z.B. ein, zwei, drei, vier oder mehr als vier, acht oder mehr als acht Hardware-Haltepunktregister auf dem Hardware-Target vorhanden sein - ein Setzen basierend auf Abständen, insbesondere Abstandsgewichten, von Anweisungsblöcken zu mindestens einem beim Fuzzing erreichten Anweisungsblock in dem Kontrollflussgraphen. In einer Ausführungsform des Verfahrens kann das strategische Setzen des mindestens einen Haltepunkts ein z.B. sukzessives Setzen von Haltepunkten vor Anweisungen von Anweisungsblöcken, die im Kontrollflussgraphen in einem hohen Maß mit bereits beim Fuzzing erreichten Anweisungsblöcken und/oder miteinander verbunden und nah beieinander sind, d.h. kleine Abstände, insbesondere hohe Abstandsgewichte, zu mindestens einen beim Fuzzing erreichten Anweisungsblock aufweisen, umfassen. Im Gegensatz z.B. zum sukzessiven Setzen von Haltepunkten vor benachbarten Anweisungen in einem abstrakten Syntaxbaum der Software und/oder gar zu beliebigen Anweisungen der Software und insbesondere im Fall von hinreichend komplexer Software - ein Kriterium, das in der Praxis fast immer erfüllt ist und/oder sehr leicht erfüllt werden kann - wird durch das strategische Setzen basierend auf (kleinen) Abständen, insbesondere (hohen) Abstandsgewichten, von Anweisungsblöcken zu dem mindestens einen beim Fuzzing erreichten Anweisungsblock im Kontrollflussgraphen die Wahrscheinlichkeit für einen Softwareentwickler/Nutzer der Software interessante und/oder relevante Ausführungsblöcke zu finden deutlich erhöht. Dadurch wird das Fuzzing erheblich effizienter, besser und/oder schneller. Dadurch kann die Software und insbesondere das von der Software gesteuerte, geregelte und/oder überwachte System verbessert werden.In the method proposed in this disclosure according to the first aspect (or an embodiment thereof), the strategic setting (or selection) of the at least one breakpoint or, for example, one breakpoint per existing hardware breakpoint register - it can be, for example, one, two, three, four or more than four, eight or more than eight hardware breakpoint registers are present on the hardware target - a setting based on distances, in particular distance weights, from instruction blocks to at least one instruction block reached during fuzzing in the control flow graph. In one embodiment of the method, the strategic setting of the at least one breakpoint can involve, for example, successive setting of breakpoints before instructions of instruction blocks that are connected to a high degree in the control flow graph with instruction blocks already reached during fuzzing and/or to each other and are close to one another, ie small distances , in particular high distance weights, to at least one instruction block reached during fuzzing. In contrast, for example, to the successive setting of breakpoints in front of neighboring statements in an abstract syntax tree of the software and/or even to arbitrary statements in the software and especially in the case of sufficiently complex software - a criterion that is almost always met in practice and/or very can be easily fulfilled - by strategically setting based on (small) distances, in particular (high) distance weights, from instruction blocks to the at least one instruction block in the control flow graph reached during fuzzing, the probability of execution blocks being interesting and/or relevant for a software developer/user of the software to be found significantly increased. This makes fuzzing significantly more efficient, better and/or faster. This allows the software and in particular the system controlled, regulated and/or monitored by the software to be improved.

In Ausführungsformen des in dieser Offenbarung vorgeschlagenen Verfahrens nach dem ersten Aspekt (oder einer Ausführungsform davon) kann das strategische Setzen (oder Auswählen) des mindestens einen Haltepunkts oder z.B. jeweils eines Haltepunkts je vorhandenem Hardware-Haltepunktregister zum einen durch (kleine) Abstände, insbesondere (hohe) Abstandsgewichte, von Anweisungsblöcken zumindest tendenziell geleitet werden, und zum anderen auf einer probabilistischen Auswahl von Anweisungsblöcken basieren. Dazu kann zum Beispiel ein Wahrscheinlichkeitsmaß berechnet werden, das Anweisungsblöcken im Kontrollflussgraphen oder einem Teil davon (normierte) Abstandsgewichte zuordnet. Das Auswählen von Anweisungsblöcken, vor oder in denen mindestens ein Haltepunkt gesetzt werden soll, kann dann einzelnes oder mehrfaches Ziehen von Anweisungsblöcken gemäß des Wahrscheinlichkeitsmaßes umfassen. In anderen Worten: Die Anweisungsblöcke können nach dem Wahrscheinlichkeitsmaß (z.B. ä la Monte Carlo) gewürfelt werden. Ein Vorteil besteht darin, dass zwar Anweisungsblöcke mit kleinen Abständen/hohen Abstandsgewichten bevorzugt und zumindest pseudo-zufällig ausgewählt werden, es dennoch aber möglich ist und von Zeit zu Zeit auch geschieht, dass ein weiter entfernter aber noch vernetzter Anweisungsblock ausgewählt wird. Die Zufälligkeit kann insbesondere bewirken, dass der Kontrollflussgraph hinreichend gut beim Fuzzing abgedeckt wird, d.h. dass das Auswählen von Anweisungsblöcke nicht nur auf einem kleinen Teil des Kontrollflussgraphen beschränkt ist. Auch dadurch wird das Fuzzing erheblich effizienter, besser und/oder schneller. Dadurch kann die Software und insbesondere das von der Software gesteuerte, geregelte und/oder überwachte System verbessert werden.In embodiments of the method proposed in this disclosure according to the first aspect (or an embodiment thereof), the strategic setting (or selection) of the at least one breakpoint or, for example, one breakpoint per existing hardware breakpoint register can be achieved on the one hand by (small) distances, in particular ( high) distance weights, at least tend to be guided by instruction blocks, and on the other hand are based on a probabilistic selection of instruction blocks. For this purpose, for example, a probability measure can be calculated that assigns (normalized) distance weights to instruction blocks in the control flow graph or to a part of it. Selecting instruction blocks before or within which at least one breakpoint should be set may then involve single or multiple dragging of instruction blocks according to the probability measure. In other words: The instruction blocks can be rolled according to the probability measure (e.g. a la Monte Carlo). One advantage is that although instruction blocks with small distances/high distance weights are preferred and at least pseudo-randomly selected, it is still possible and does happen from time to time for a more distant but still networked instruction block to be selected. In particular, the randomness can ensure that the control flow graph is covered sufficiently well during fuzzing, i.e. that the selection of instruction blocks is not limited to just a small part of the control flow graph. This also makes fuzzing significantly more efficient, better and/or faster. This allows the software and in particular the system controlled, regulated and/or monitored by the software to be improved.

Kurzbeschreibung der FigurenShort description of the characters

  • 1a illustriert schematisch ein computer-implementiertes Verfahren zur Erlangung von Softwareabdeckungsfeedback beim Fuzzing einer Software auf einem Hardware-Target. 1a schematically illustrates a computer-implemented method for obtaining software coverage feedback when fuzzing software on a hardware target.
  • 1b illustriert schematisch eine Fortsetzung des computer-implementierten Verfahrens zur Erlangung von Softwareabdeckungsfeedback beim Fuzzing einer Software auf einem Hardware-Target. 1b schematically illustrates a continuation of the computer-implemented method for obtaining software coverage feedback when fuzzing software on a hardware target.
  • 2 illustriert schematisch eine beispielhafte Ausführungsform des computer-implementierten Verfahrens zur Erlangung von Softwareabdeckungsfeedback beim Fuzzing einer Software auf einem Hardware-Target. 2 schematically illustrates an exemplary embodiment of the computer-implemented method for obtaining software coverage feedback when fuzzing software on a hardware target.
  • 3 zeigt einen beispielhaften und schematischen Kontrollflussgraphen einer Software mit Anweisungsblöcken und gerichteten Kanten. 3 shows an exemplary and schematic control flow graph of a software with instruction blocks and directed edges.

Detaillierte BeschreibungDetailed description

Das in dieser Offenbarung vorgeschlagene Verfahren 100 ermöglicht die Erlangung von Softwareabdeckungsfeedback beim Fuzzing einer Software auf einem Hardware-Target. Das Hardware-Target kann zum Beispiel eine elektronische Steuereinheit sein, wobei die Software dafür ausgelegt sein kann, die elektronische Steuereinheit zu steuern, regeln und/oder zu überwachen.The method 100 proposed in this disclosure enables obtaining software coverage feedback when fuzzing software on a hardware target. The hardware target can be, for example, an electronic control unit, wherein the software can be designed to control, regulate and/or monitor the electronic control unit.

Das in dieser Offenbarung vorgeschlagene Verfahren 100 kann sich besonders für den Fall eignen, in dem die Software nicht statisch für Fuzzing instrumentiert ist. Weiterhin kann die Software (ganz oder teilweise) closed-source sein. Stattdessen kann Softwareabdeckungsfeedback beim Fuzzing der Software über dynamische Instrumentierung erlangt werden.The method 100 proposed in this disclosure may be particularly suitable for the case where the software is not statically instrumented for fuzzing. Furthermore, the software can be closed source (in whole or in part). Instead, software coverage feedback can be obtained when fuzzing the software via dynamic instrumentation.

Bei Bestehen einer Debugging-Verbindung zu dem Hardware-Target kann zum Beispiel wie folgt, und wie in 2 beispielhaft illustriert, Softwareabdeckungsfeedback beim Fuzzing und insbesondere während einer Fuzzing-Iteration erlangt werden:

  • Zunächst kann z.B. vor dem Ausführen der Fuzzing-Iteration ein nullter Haltepunkt vor eine Startanweisung (englisch: function to instrument) gesetzt werden. Diese Startanweisung kann dadurch gekennzeichnet sein, dass sie beim Ausführen der Software unabhängig von den Eingangsdaten und somit bei einer jeden Fuzzing-Iteration ausgeführt wird. Die Startanweisung kann zum Beispiel aus einer Spezifikation der Software (z.B. symbol file) und/oder durch einen Testingenieur identifiziert werden. Alternativ oder zusätzlich kann vor dem Ausführen der Fuzzing-Iteration ein erster Haltepunkt in oder vor einem ersten Anweisungsblock gesetzt werden.
If there is a debugging connection to the hardware target, for example, as follows and as in 2 Illustrated as an example, software coverage feedback can be obtained during fuzzing and in particular during a fuzzing iteration:
  • First, for example, a zero breakpoint can be placed in front of a start instruction (function to instrument) before executing the fuzzing iteration. This start instruction can be characterized in that it is executed when the software is executed independently of the input data and thus at every fuzzing iteration. The start instruction can be identified, for example, from a specification of the software (e.g. symbol file) and/or by a test engineer. Alternatively or additionally, a first breakpoint can be set in or before a first instruction block before executing the fuzzing iteration.

Sodann kann die Fuzzing-Iteration der Software auf Basis der Fuzzing-Eingangsdaten für die Fuzzing-Iteration ausgeführt werden. Wird der nullte oder erste Haltepunkt beim Ausführen der Fuzzing-Iteration erreicht, kann er als erreicht markiert werden. Optional und insbesondere, wenn die maximale Anzahl der (Hardware-)Haltepunktregister stark limitiert ist, kann der nullte und/oder erste Haltepunkt gelöscht werden.The fuzzing iteration of the software can then be executed based on the fuzzing input data for the fuzzing iteration. If the zeroth or first breakpoint is reached while running the fuzzing iteration, it can be marked as reached. Optionally and especially if the maximum number of (hardware) breakpoint registers is severely limited, the zeroth and/or first breakpoint can be deleted.

Sodann kann mindestens ein zweiter Haltepunkt in oder vor einem zweiten Anweisungsblock gesetzt werden. Wird wiederum der zweite Haltepunkt beim Ausführen der Fuzzing-Iteration erreicht, kann er als erreicht markiert werden. Optional und insbesondere, wenn die maximale Anzahl der Haltepunktregister stark limitiert ist, kann der zweite Haltepunkt gelöscht werden. Die Fuzzing-Eingangsdaten, die dazu geführt haben, dass der zweite Haltepunkt erreicht wurde, können gespeichert und mit dem dazugehörigen Anweisungsblock in dem Kontrollflussgraphen 10 der Software werden.
Durch sukzessives Umsetzen (oder Löschen und Neusetzen) mindestens eines Haltepunkts kann Softwareabdeckungsfeedback während der Ausführung der Fuzzing-Iteration erlangt werden. Das Softwareabdeckungsfeedback kann zum Beispiel einen Pfad in dem Kontrollflussgraphen 10 umfassen, wobei der Pfad eine Sequenz von Anweisungsblöcken des Kontrollflussgraphen 10 umfassen kann.
At least one second breakpoint can then be set in or before a second instruction block. If the second breakpoint is reached when executing the fuzzing iteration, it can be marked as reached. Optionally, and especially if the maximum number of breakpoint registers is severely limited, the second breakpoint can be deleted. The fuzzing input data that caused the second breakpoint to be reached may be stored and associated with the associated instruction block in the control flow graph 10 of the software.
By successively implementing (or deleting and resetting) at least one breakpoint, software coverage feedback can be obtained during the execution of the fuzzing iteration. The software coverage feedback may, for example, include a path in the control flow graph 10, where the path may include a sequence of instruction blocks of the control flow graph 10.

Häufig ist der Kontrollflussgraph 10 der (kompilierten, closed-source) Software allerdings nicht im Vorfeld bekannt. Dennoch kann er mit dem in dieser Offenbarung vorgeschlagenen Verfahren 100 während des Fuzzing zum Beispiel durch sukzessiv protokollierte gesetzte Haltepunkte mit vertretbarem Aufwand konstruiert werden.However, the control flow graph 10 of the (compiled, closed-source) software is often not known in advance. Nevertheless, it can be constructed with reasonable effort using the method 100 proposed in this disclosure during fuzzing, for example by successively logged set breakpoints.

Es kann durchaus vorkommen, dass ein gesetzter Haltepunkt beim Ausführen der Fuzzing-Iteration nicht erreicht wird. Es kann sogar vorkommen, dass ein gesetzter Haltepunkt beim Ausführen einer Vielzahl von Fuzzing-Iterationen nicht erreicht wird. Anhand eines vorbestimmten Kriteriums (z.B. wenn nach einer vorbestimmten Anzahl von Fuzzing-Iterationen der Haltepunkt nicht erreicht wird und/oder bei einer Zeitüberschreitung), kann der Haltepunkt als übersprungen markiert werden. Dieser oder ein neuer Haltepunkt kann dann z.B. in oder vor einem Anweisungsblock gesetzt werden, der zu dem nicht erreichten Anweisungsblock im Kontrollflussgraphen 10 benachbart ist.It may well happen that a set breakpoint is not reached when executing the fuzzing iteration. It can even happen that a set breakpoint is not reached when executing a large number of fuzzing iterations. Based on a predetermined criterion (e.g. if the breakpoint is not reached after a predetermined number of fuzzing iterations and/or if a timeout occurs), the breakpoint can be marked as skipped. This or a new breakpoint can then be set, for example, in or before an instruction block that is adjacent to the instruction block in the control flow graph 10 that was not reached.

Die Auswahl der Anweisungsblöcke bzw. der Haltepunkte basiert im Verfahren 100 auf Abständen, optional Abstandsgewichten von Anweisungsblöcken im Kontrollflussgraphen 10 zu mindestens einem bereits beim Fuzzing erreichten Anweisungsblock. Es können allerdings verschiedene weitere Strategien, die auf dem Hardware-Target verfügbaren Haltepunkte zu setzen, in dem Verfahren 100 zusätzlich zur Anwendung kommen. Weiterhin können verschiedene Strategien in dem Verfahren 100 kombiniert und/oder abgewechselt werden. Alternativ oder zusätzlich kann die Strategie eine probabilistische Suche umfassen. Alternativ oder zusätzlich kann die Strategie eine entropische Suche umfassen. Alternativ oder zusätzlich kann die Strategie eine angeleitete Suche umfassen. Alternativ oder zusätzlich kann die Strategie weitere Suchstrategien umfassen. Bei der entropischen Suche kann z.B. ein Anweisungsblock (und/oder eine gerichtete Kante) im Kontrollflussgraphen 10, der beim Fuzzing erreicht wird (bzw. die beim Fuzzing durchlaufen wird), mit einem jeweiligen Wert für Informationsgewinn (auch: Entropie) versehen werden. Die Strategie bei der entropischen Suche kann dann umfassen, durch den Fuzzer solche Fuzzing-Eingangsdaten zu generieren, die einen Gesamtinformationsgewinn maximieren. Somit können eher Anweisungsblöcke (und/oder gerichtete Kanten) mit hohem Informationsgewinn bevorzugt werden. Dadurch werden weniger bereits erreichte Anweisungsblöcke (und/oder bereits durchlaufene gerichtete Kanten) entdeckt. Somit können neue Anweisungsblöcke (und/oder gerichtete Kanten) effizienter entdeckt werden. Bei der angeleiteten Suche kann weiterhin das Setzen des jeweiligen mindestens einen Haltepunkts auf einer Benutzereingabe basieren. Wenn zum Beispiel ein Nutzer, ein Programmierer und/oder ein Auditor der Software eine kritische Stelle in der Software oder im Kontrollflussgraphen 10 der Software kennen, kann ein solches Wissen über eine Benutzerschnittstelle genutzt werden, die Haltepunkte und/oder Fuzzing-Eingangsdaten derart zu wählen, dass die kritische Stelle bei mindestens einer Fuzzing-Iteration erreicht und somit eingehend getestet wird. The selection of the instruction blocks or the breakpoints is based in the method 100 on distances, optionally distance weights, from instruction blocks in the control flow graph 10 to at least one instruction block that has already been reached during fuzzing. However, various other strategies for setting the breakpoints available on the hardware target can also be used in the method 100. Furthermore, different strategies can be combined and/or alternated in the method 100. Alternatively or additionally, the strategy may include a probabilistic search. Alternatively or additionally, the strategy may include an entropic search. Alternatively or additionally, the strategy may include guided search. Alternatively or additionally, the strategy can include further search strategies. In the entropic search, for example, an instruction block (and/or a directed edge) in the control flow graph 10 that is reached during fuzzing (or which is traversed during fuzzing) can be provided with a respective value for information gain (also: entropy). The strategy in entropic search may then involve generating through the fuzzer such fuzzing input data that maximizes overall information gain. Thus, instruction blocks (and/or directed edges) with high information gain may be preferred. This means that fewer instruction blocks that have already been reached (and/or directed edges that have already been traversed) are discovered. This means new ones can Statement blocks (and/or directed edges) can be discovered more efficiently. In the case of guided searches, the setting of at least one breakpoint can still be based on user input. For example, if a user, a programmer and/or an auditor of the software knows a critical point in the software or in the control flow graph 10 of the software, such knowledge can be used via a user interface to select the breakpoints and/or fuzzing input data that the critical point is reached in at least one fuzzing iteration and is therefore tested in detail.

Offenbart wird ein computer-implementiertes Verfahren 100 zur Erlangung von Softwareabdeckungsfeedback beim Fuzzing einer Software auf einem Hardware-Target, wobei das Hardware-Target mindestens ein Haltepunktregister aufweist und dafür ausgelegt ist, eine Ausführung der Software vor Ausführung einer Anweisung der Software anzuhalten, wenn die Anweisung bei der Ausführung der Software erreicht wird und eine Speicheradresse der Anweisung in dem mindestens einen Haltepunkteregister gesetzt ist. Das mindestens eine Haltepunktregister kann ein Hardware-Haltepunktregister sein. Ein Hardware-Haltepunkt ist ein Haltepunkt, der via ein Hardware-Haltepunktregister gesetzt wird.Disclosed is a computer-implemented method 100 for obtaining software coverage feedback when fuzzing software on a hardware target, the hardware target having at least one breakpoint register and being configured to halt execution of the software before executing an instruction of the software if the Instruction is reached when executing the software and a memory address of the instruction is set in the at least one breakpoint register. The at least one breakpoint register may be a hardware breakpoint register. A hardware breakpoint is a breakpoint that is set via a hardware breakpoint register.

Das Verfahren 100, schematisch dargestellt in 1a, umfasst Auswählen 119 eines ersten Anweisungsblocks der Software.The method 100, shown schematically in 1a , includes selecting 119 a first instruction block of the software.

Das Verfahren 100 umfasst Setzen 120 eines ersten Haltepunkts vor einer Anweisung des ersten Anweisungsblocks in dem mindestens einen Haltepunktregister. Setzen 120 des ersten Haltepunkts vor der Anweisung der Software kann Setzen einer Speicheradresse der Anweisung in das mindestens eine Haltepunktregister umfassen.The method 100 includes setting 120 a first breakpoint before an instruction of the first instruction block in the at least one breakpoint register. Setting 120 the first breakpoint before the software instruction may include setting a memory address of the instruction into the at least one breakpoint register.

Das Verfahren 100 kann erstes Ausführen 130 einer Fuzzing-Iteration der Software umfassen. Alternativ kann das Verfahren 100 erstes Fortsetzen 131 einer (bereits teilweise ausgeführten, aber angehaltenen) Fuzzing-Iteration der Software umfassen.The method 100 may include first executing 130 a fuzzing iteration of the software. Alternatively, the method 100 may include first resuming 131 an (already partially executed but stopped) fuzzing iteration of the software.

Das Verfahren 100 umfasst erstes Prüfen 140, ob der erste Haltepunkt beim ersten Ausführen 130 oder ersten Fortsetzen 131 der Fuzzing-Iteration erreicht wird. Der erste Haltepunkt wird dann erreicht, wenn ohne den ersten Haltepunkt die erste Anweisung bei Ausführung der Software auf Basis der Fuzzing-Eingangsdaten der Fuzzing-Iteration ausgeführt worden wäre.The method 100 includes first checking 140 whether the first breakpoint is reached during the first execution 130 or first continuation 131 of the fuzzing iteration. The first breakpoint is reached when, without the first breakpoint, the first instruction would have been executed when the software was executed based on the fuzzing input data of the fuzzing iteration.

Das Verfahren 100 umfasst Speichern 150 einer ersten Protokollinformation, wobei die erste Protokollinformation umfasst, dass der erste Anweisungsblock (oder eine korrespondierende Anweisung vor oder in dem ersten Anweisungsblock) in der Fuzzing-Iteration erreicht worden ist, wenn das erste Prüfen 140 positiv ausfällt.The method 100 includes storing 150 a first protocol information, wherein the first protocol information includes that the first instruction block (or a corresponding instruction before or in the first instruction block) has been reached in the fuzzing iteration if the first check 140 is positive.

Das Verfahren 100 kann, wie z.B. in Fig. la als optionaler Schritt dargestellt, Löschen 151 des ersten Haltepunkts, wenn das erste Prüfen 140 positiv ausfällt, umfassen.The method 100 can, for example, as shown as an optional step in FIG. La, include deleting 151 of the first breakpoint if the first check 140 is positive.

Das Softwareabdeckungsfeedback beim Fuzzing der Software umfasst die erste Protokollinformation. Die erste Protokollinformation kann zum Beispiel weiterhin die Fuzzing-Eingangsdaten der Fuzzing-Iteration umfassen. Speichern der Fuzzing-Eingangsdaten kann zum (sukzessivem) Erstellen einer Abbildung von beim Fuzzing erreichten Ausbildungsblöcken zu Fuzzing-Eingangsdaten (oder umgekehrt) verwendet werden. Eine solche Abbildung ist schematisch in 2 dargestellt.The software coverage feedback when fuzzing the software includes the first protocol information. The first protocol information can, for example, further include the fuzzing input data of the fuzzing iteration. Storing fuzzing input data can be used to (successively) create a map from fuzzing achieved training blocks to fuzzing input data (or vice versa). Such a figure is shown schematically in 2 shown.

Das Auswählen 119 des ersten Anweisungsblocks der Software kann auf Abständen (z.B. d(b, b_i)) von Anweisungsblöcken 11 zu mindestens einem beim Fuzzing - d.h. z.B. bei einer früheren Fuzzing-Iteration oder bei der Fuzzing-Iteration der Software - erreichten Anweisungsblock 13 (z.B. b_i in B_erreicht) in einem Kontrollflussgraphen 10 der Software basieren. Hier ist z.B. b ein Anweisungsblock aus einer Menge der Anweisungsblöcke B des Kontrollflussgraphen oder einem Teil davon und z.B. b_i ein Anweisungsblock in der Menge B_erreicht der erreichten Anweisungsblöcke, wobei B_erreicht eine Teilmenge der Menge B sein kann. In anderen Worten: Das Auswählen 119 des ersten Anweisungsblocks der Software kann auf Abständen von dem mindestens einen beim Fuzzing erreichten Anweisungsblock 13 zu jeweils den Anweisungsblöcken basieren.Selecting 119 the first instruction block of the software can be done at distances (e.g. d(b, b_i)) from instruction blocks 11 to at least one instruction block 13 (e.g. b_i in B_achieved) in a control flow graph 10 of the software. Here, for example, b is an instruction block from a set of the instruction blocks B of the control flow graph or a part thereof and, for example, b_i is an instruction block in the set B_achieved of the instruction blocks reached, where B_achieved can be a subset of the set B. In other words, the selection 119 of the first instruction block of the software can be based on distances from the at least one instruction block 13 reached during fuzzing to each of the instruction blocks.

Alternativ oder zusätzlich kann das Auswählen 119 des ersten Anweisungsblocks der Software auf Abstandsgewichten (z.B. (d(b, b_i))^(-1)) von Anweisungsblöcken 11 zu mindestens einem beim Fuzzing - d.h. z.B. bei einer früheren Fuzzing-Iteration oder bei der Fuzzing-Iteration der Software - erreichten Anweisungsblock 13 in einem Kontrollflussgraphen 10 der Software basieren. In anderen Worten: Das Auswählen 119 des ersten Anweisungsblocks der Software kann auf Abstandsgewichten von dem mindestens einen beim Fuzzing erreichten Anweisungsblock 13 zu jeweils den Anweisungsblöcken basieren.Alternatively or additionally, selecting 119 the first instruction block of the software can be based on distance weights (e.g. (d(b, b_i))^(-1)) of instruction blocks 11 to at least one when fuzzing - ie, for example, at a previous fuzzing iteration or at fuzzing -Iteration of the software - achieved instruction block 13 is based in a control flow graph 10 of the software. In other words: the choosing 119 of the first instruction block of the software can be based on distance weights from the at least one instruction block 13 reached during fuzzing to each of the instruction blocks.

Ein Kontrollflussgraph 10, beispielhaft und schematisch dargestellt in 3, kann ein gerichteter Graph sein, der dazu dient, den Kontrollfluss der Software (oder eines Teils davon) zu beschreiben. Der Kontrollflussgraph kann eine Menge von Knoten 11 (z.B. b1, b2, b3, b4, b5, b6, b7), die die Anweisungsblöcke des beschriebenen Programms darstellen, sowie eine Menge von gerichteten Kanten 12, die mögliche Übergänge zwischen Anweisungsblöcken umfassen, d. h. Programmabläufe darstellen. Zum Beispiel kann der Anweisungsblock b5 der mindestens eine beim Fuzzing erreichte Anweisungsblock (aus B_erreicht) sein. Kontrollflussgraphen 10 einer hinreichend komplexen Software können >= 1e2, >= 1e3, >= 1e4, >= 1e5, >=1e6, >=1e7 Anweisungsblöcke und >= 1e2, >= 1e3, >= 1e4, >= 1e5, >=1e6, >=1e7, >=1e8, >=1e9 gerichtete Kanten umfassen.A control flow graph 10, shown as an example and schematically in 3 , can be a directed graph used to describe the control flow of the software (or part of it). The control flow graph may be a set of nodes 11 (e.g. b1, b2, b3, b4, b5, b6, b7) representing the instruction blocks of the described program, as well as a set of directed edges 12 comprising possible transitions between instruction blocks, ie program flows represent. For example, the instruction block b5 can be the at least one instruction block reached during fuzzing (from B_reached). Control flow graphs 10 of a sufficiently complex software can have >= 1e2, >= 1e3, >= 1e4, >= 1e5, >=1e6, >=1e7 instruction blocks and >= 1e2, >= 1e3, >= 1e4, >= 1e5, >= 1e6, >=1e7, >=1e8, >=1e9 include directed edges.

Zum Beispiel können Anweisungsblöcke mit den kleinsten Abständen, optional höchsten Abstandgewichten mit oder ohne Zurücklegen gezogen und somit ausgewählt 119 werden.For example, instruction blocks with the smallest distances, optionally highest distance weights, can be drawn with or without replacement and thus selected 119.

Ein Abstand (z.B. d(b, b_i)) eines (beliebigen) Anweisungsblocks 11 (z.B. Anweisungsblock b) zu dem mindestens einen beim Fuzzing erreichten Anweisungsblock (z.B. Anweisungsblock b_i) kann zum Beispiel ein Minimum aus:

  • - einer minimalen Pfadlänge (z.B. min {PL(b, b_i I über alle Pfade von b nach b_i}) von dem Anweisungsblock 11 (z.B. Anweisungsblock b) zu dem mindestens einen beim Fuzzing erreichten Anweisungsblock (z.B. Anweisungsblock b_i); und/oder
  • - einer minimalen Pfadlänge (z.B. min {PL(b_i, b I über alle Pfade von b_i nach b}) von dem mindestens einen beim Fuzzing erreichten Anweisungsblock (z.B. Anweisungsblock b_i) zu dem Anweisungsblock 11 (z.B. Anweisungsblock b);
sein.A distance (e.g. d(b, b_i)) of an (arbitrary) instruction block 11 (e.g. instruction block b) to the at least one instruction block reached during fuzzing (e.g. instruction block b_i) can, for example, be a minimum of:
  • - a minimum path length (e.g. min {PL(b, b_i I over all paths from b to b_i}) from the instruction block 11 (e.g. instruction block b) to the at least one instruction block reached during fuzzing (e.g. instruction block b_i); and/or
  • - a minimum path length (e.g. min {PL(b_i, b I over all paths from b_i to b}) from the at least one instruction block reached during fuzzing (e.g. instruction block b_i) to the instruction block 11 (e.g. instruction block b);
be.

Zum Beispiel kann d(b, b_i) = min {PL(b, b_i I über alle Pfade von b nach b_i} gelten. Zum Beispiel kann d(b, b_i) = min {PL(b_i, b I über alle Pfade von b_i nach b} gelten. Zum Beispiel kann d(b, b_i) = min(min {PL(b, b_i I über alle Pfade von b nach b_i}, min {PL(b_i, b I über alle Pfade von b_i nach b}) gelten.For example, d(b, b_i) = min {PL(b, b_i I over all paths from b to b_i}. For example, d(b, b_i) = min {PL(b_i, b I over all paths from b_i to b}. For example, d(b, b_i) = min(min {PL(b, b_i I over all paths from b to b_i}, min {PL(b_i, b I over all paths from b_i to b }) apply.

Ein Abstand kann eine Zahl z.B. in dem (reellen) Intervall [0, Unendlich] (Endpunkte inbegriffen) sein. Ein Abstand kann z.B. eine natürliche Zahl (mit Null) sein. Insbesondere kann ein Abstand positiv oder Null sein. Alternativ kann ein Abstand Unendlich (groß) sein. Alternativ kann ein Abstand eine reelle (oder natürliche) Zahl z.B. in dem Intervall (0, Unendlich] (rechter Endpunkt inbegriffen) sein. Alternativ kann ein Abstand eine reelle (oder natürliche) Zahl z.B. in dem Intervall (0, Unendlich) (Endpunkt nicht inbegriffen) sein. Das Minimum von a und Unendlich (oder umgekehrt) kann als a definiert sein. Analog kann das Minimum von Unendlich und Unendlich als Unendlich definiert sein.A distance can be a number, for example, in the (real) interval [0, infinity] (end points included). A distance can be, for example, a natural number (with zero). In particular, a distance can be positive or zero. Alternatively, a distance can be infinite (large). Alternatively, a distance can be a real (or natural) number e.g. in the interval (0, infinity) (right end point included). Alternatively, a distance can be a real (or natural) number e.g. in the interval (0, infinity) (end point not The minimum of a and infinity (or vice versa) can be defined as a. Similarly, the minimum of infinity and infinity can be defined as infinity.

Eine Pfadlänge von einem (beliebigen) Anweisungsblock zu einem anderen (beliebigen) Anweisungsblock kann ein zumindest approximatives Maß dafür sein,

  • - ob ein Pfad, in dem Kontrollflussgraphen 10 oder einem Teil davon, umfassend mindestens eine gerichtete Kante 12 ausgehend von dem einen (beliebigen) Anweisungsblock und in Flussrichtung zu dem anderen (beliebigen) Anweisungsblock existiert; und/oder;
  • - wie lang ein solcher Pfad ist, so dieser existiert, insbesondere wie viele der mindestens einen gerichteten Kante 12 dieser Pfad umfasst.
A path length from one (arbitrary) instruction block to another (arbitrary) instruction block can be at least an approximate measure of
  • - whether a path exists in the control flow graph 10 or a part thereof, comprising at least one directed edge 12 starting from the one (arbitrary) instruction block and in the flow direction to the other (arbitrary) instruction block; and or;
  • - How long such a path is, if it exists, in particular how many of the at least one directed edge 12 this path includes.

Die Pfadlänge kann je Pfad (sofern mindestens ein Pfad existiert) definiert werden. Die Pfad länge kann unendlich (groß) sein, falls kein Pfad existiert.The path length can be defined for each path (as long as at least one path exists). The path length can be infinite (large) if no path exists.

In 3 ergeben sich beispielhaft die folgenden minimalen Pfadlängen und Abstände: Anweisungs -block bx minimale Pfadlänge von b5 nach Anweisungsbloc kbx minimale Pfadlänge von Anweisungsbloc k bx nach b5 Abstan d bx nach b b1 Unendlich (nicht vorhanden) 2 2 b2 1 1 1 b3 2 Unendlich (nicht vorhanden) 2 b4 2 Unendlich (nicht vorhanden) 2 b5 0 0 0 b6 3 Unendlich (nicht vorhanden) 3 b7 1 Unendlich (nicht vorhanden) 1 In 3 The following example minimum path lengths and distances result: Instruction block bx Minimum path length from b5 to instruction block kbx Minimum path length from instruction block k bx to b5 Distance d bx to b b1 Infinite (not present) 2 2 b2 1 1 1 b3 2 Infinite (not present) 2 b4 2 Infinite (not present) 2 b5 0 0 0 b6 3 Infinite (not present) 3 b7 1 Infinite (not present) 1

Pfade von dem mindestens einen beim Fuzzing erreichten Anweisungsblock (z.B. Anweisungsblock b_i) zu dem mindestens einen beim Fuzzing erreichten Anweisungsblock (z.B. Anweisungsblock b_i) können Pfadlänge 0 aufweisen und ignoriert werden.Paths from the at least one instruction block reached during fuzzing (e.g. instruction block b_i) to the at least one instruction block reached during fuzzing (e.g. instruction block b_i) can have a path length of 0 and can be ignored.

Ein Abstandsgewicht (z.B. (d(b, b_i))^(-1)) eines (beliebigen) Anweisungsblocks 11 (z.B. b) zu dem mindestens einen beim Fuzzing erreichten Anweisungsblock 13 (z.B. b_i) kann auf dem Abstand des (beliebigen) Anweisungsblocks 11 (z.B. b) zu dem mindestens einen beim Fuzzing erreichten Anweisungsblock 13 (z.B. b_i) basieren. Zum Beispiel kann das Abstandsgewicht groß sein, wenn der Abstand klein ist, und das Abstandsgewicht klein sein, wenn der Abstand groß ist. Hierzu sind beliebige (stetige) Zusammenhänge denkbar. Weiterhin kann zum Beispiel das Abstandsgewicht umgekehrt proportional zum Abstand sein. Weiterhin kann zum Beispiel das Abstandsgewicht ein Kehrwert des Abstands, d.h. Abstandgewicht = (d(b, b_i))^(-1), sein.A distance weight (e.g. (d(b, b_i))^(-1)) of an (arbitrary) instruction block 11 (e.g. b) to the at least one instruction block 13 (e.g. b_i) reached during fuzzing can be based on the distance of the (arbitrary) instruction block 11 (e.g. b) to the at least one instruction block 13 (e.g. b_i) reached during fuzzing. For example, the distance weight may be large when the distance is small and the distance weight may be small when the distance is large. Any (continuous) connections are conceivable for this purpose. Furthermore, for example, the distance weight can be inversely proportional to the distance. Furthermore, for example, the distance weight can be a reciprocal of the distance, i.e. distance weight = (d(b, b_i))^(-1).

Ein Abstandsgewicht kann eine reelle Zahl in dem Intervall [0, Unendlich) (linker Endpunkt inbegriffen) sein. Ein Abstandsgewicht kann eine natürliche Zahl (mit Null) sein. Ein Abstandsgewicht kann positiv oder Null sein. Weiterhin kann (Unendlich)^(-1) als Null definiert werden.A distance weight can be a real number in the interval [0, infinity) (left endpoint included). A distance weight can be a natural number (including zero). A distance weight can be positive or zero. Furthermore, (Infinity)^(-1) can be defined as zero.

In 3 ergeben sich beispielhaft die folgenden Abstandsgewichte z.B. als Kehrwert der Abstände: Anweisungsblock bx Abstand bx nach b Abstandsgewicht bx nach b b1 2 0.5 b2 1 1.0 b3 2 0.5 b4 2 0.5 b5 0 Unendlich (ignoriert) b6 3 0.333333333 b7 1 1.0 In 3 The following distance weights result, for example, as the reciprocal of the distances: Instruction block bx Distance bx to b Distance weight bx to b b1 2 0.5 b2 1 1.0 b3 2 0.5 b4 2 0.5 b5 0 Infinite (ignored) b6 3 0.333333333 b7 1 1.0

In diesem Fall könnten zum Beispiel Anweisungsblöcke b2 oder b7 mit hohen Abstandsgewichten ausgewählt 119, 159 werden.In this case, for example, instruction blocks b2 or b7 with high distance weights could be selected 119, 159.

Das Verfahren 100 kann, wie z.B. in Fig. la als optionaler Schritt dargestellt, Berechnen 118a mindestens eines Abstands von Anweisungsblöcken 11 zu dem mindestens einen beim Fuzzing (z.B. bei einer früheren Fuzzing-Iteration oder bei der Fuzzing-Iteration der Software) erreichten Anweisungsblock 13 umfassen. Alternativ oder zusätzlich kann das Verfahren Berechnen 118a mindestens eines Abstandsgewichts von Anweisungsblöcken 11 zu dem mindestens einen beim Fuzzing (z.B. bei einer früheren Fuzzing-Iteration oder bei der Fuzzing-Iteration der Software) erreichten Anweisungsblock umfassen.1a, the method 100 can calculate 118a at least one distance from instruction blocks 11 to the at least one instruction block 13 reached during fuzzing (e.g. in an earlier fuzzing iteration or in the fuzzing iteration of the software). include. Alternatively or additionally, the method may include calculating 118a at least one distance weight of instruction blocks 11 to the at least one instruction block reached during fuzzing (e.g. in a previous fuzzing iteration or in the fuzzing iteration of the software).

Das Verfahren 100 kann, wie z.B. in Fig. la als optionaler Schritt dargestellt, Berechnen 118b eines ersten Wahrscheinlichkeitsmaßes zu dem mindestens einen beim Fuzzing erreichten Anweisungsblock umfassen. Das erste Wahrscheinlichkeitsmaß kann zum Beispiel mindestens zwei Anweisungsblöcken des Kontrollflussgraphen 10 oder eines Teils davon jeweils ein normiertes Gewicht G zuordnen, wobei die Gewichte G derart normiert werden können, dass die Summe aller Gewichte für die mindestens zwei Anweisungsblöcke eins ergeben kann.The method 100 can, for example, as shown as an optional step in FIG. 1a, include calculating 118b a first probability measure for the at least one instruction block reached during fuzzing. The first probability measure can, for example, assign a standardized weight G to at least two instruction blocks of the control flow graph 10 or a part thereof, wherein the weights G can be standardized in such a way that the sum of all weights for the at least two instruction blocks can result in one.

Das Auswählen 119 des ersten Anweisungsblocks der Software - insbesondere, das Auswählen 119 des ersten Anweisungsblocks der Software basierend auf Abständen, insbesondere Abstandsgewichten, der Anweisungsblöcke zu dem mindestens einem beim Fuzzing erreichten Anweisungsblock in dem Kontrollflussgraphen 10 - kann zufälliges oder zumindest pseudo-zufälliges erstes Ziehen eines Anweisungsblocks als ersten Anweisungsblock aus den nach dem ersten Wahrscheinlichkeitsmaß verteilten Anweisungsblöcken umfassen.Selecting 119 the first instruction block of the software - in particular, selecting 119 the first instruction block of the software based on distances, in particular distance weights, of the instruction blocks to the at least one instruction block in the control flow graph 10 reached during fuzzing - can be random or at least pseudo-random first pulling an instruction block as the first instruction block from the instruction blocks distributed according to the first probability measure.

Hier oder im Allgemeinen kann ein solches Ziehen auch als Würfeln (ä la Monte Carlo) bezeichnet werden. Das (erste, später zweite) Ziehen kann zum Beispiel Ziehen von mindestens einer Zahl auf einem gleichverteilten (quasi-)reellen Intervall [0, 1] und Auswerten einer invertierten Verteilungsfunktion zum (ersten, später zweiten) Wahrscheinlichkeitsmaß an der mindestens einen gezogenen Zahl umfassen. Andere Implementierungen des Ziehens sind in Fachkreisen bekannt.Here or in general, such a drawing can also be referred to as rolling dice (a la Monte Carlo). The (first, later second) drawing may include, for example, drawing at least one number on a uniformly distributed (quasi-)real interval [0, 1] and evaluating an inverted distribution function for the (first, later second) probability measure on the at least one drawn number . Other implementations of dragging are known in the art.

Ein Gewicht G eines (beliebigen) Anweisungsblocks 11 (z.B. b) kann zum Beispiel eine Summe G Sigma _ { b_i in B_erreicht }  Abstandsgewicht ( b , b_i )

Figure DE102022203357A1_0001
von Abstandsgewichten des (beliebigen) Anweisungsblocks 11 zu je einem Anweisungsblock einer Vielzahl von beim Fuzzing erreichten Anweisungsblöcken oder eines Teils davon sein. Die Summe kann zum Beispiel in folgender Weise von den Abständen abhängen: G Sigma _ { b_i in B_erreicht }   ( d ( b ,b_i ) ) ( 1 )
Figure DE102022203357A1_0002
A weight G of an (arbitrary) instruction block 11 (e.g. b) can, for example, be a sum G Sigma _ { b_i in B_achieved } distance weight ( b , bi )
Figure DE102022203357A1_0001
of distance weights of the (arbitrary) instruction block 11 to one instruction block of a large number of instruction blocks reached during fuzzing or a part thereof. For example, the sum can depend on the distances in the following way: G Sigma _ { b_i in B_achieved } ( d ( b ,bi ) ) ( 1 )
Figure DE102022203357A1_0002

Die Summe von Abstandsgewichten kann zu einer (stetigen) Funktion verallgemeinert werden, insbesondere zu Funktionen, deren Bild nicht-negativ (d.h. positive oder Null) ist.The sum of distance weights can be generalized to a (continuous) function, especially to functions whose image is non-negative (i.e. positive or zero).

Alternativ oder zusätzlich (die Summe wiese dann nur einen Summanden für den mindestens einen beim Fuzzing erreichten Anweisungsblock 13 (z.B. b_i) auf) kann ein Gewicht eines (beliebigen) Anweisungsblocks 11 ein Abstandsgewicht des (beliebigen) Anweisungsblocks 11 zu je einem Anweisungsblock einer Vielzahl von beim Fuzzing erreichten Anweisungsblöcken oder eines Teils davon sein. In diesem Fall gilt für ein Gewicht G: G Abstandsgewicht ( b , b_i )

Figure DE102022203357A1_0003
Alternatively or additionally (the sum would then only have one summand for the at least one instruction block 13 (e.g. b_i) reached during fuzzing), a weight of an (arbitrary) instruction block 11 can be a distance weight of the (arbitrary) instruction block 11 to one instruction block of a large number of instruction blocks or part of them reached during fuzzing. In this case, for a weight G: G distance weight ( b , bi )
Figure DE102022203357A1_0003

Oder z.B.: G ( d ( b ,b_i ) ) ( 1 )

Figure DE102022203357A1_0004
Or e.g.: G ( d ( b ,bi ) ) ( 1 )
Figure DE102022203357A1_0004

Das erste Ziehen des Anweisungsblocks kann derart erfolgen, dass eine erste Vielzahl von Anweisungsblöcken (d.h. eine zum Zeitpunkt des ersten Ziehens vorbestimmte erste Vielzahl von Anweisungsblöcken) nicht gezogen werden. Alternativ oder zusätzlich kann das erste Ziehen des Anweisungsblocks derart erfolgen, dass die Vielzahl der (bisher) beim Fuzzing erreichten Anweisungsblöcke 13 oder des Teils davon nicht gezogen werden.The first pull of the instruction block may be such that a first plurality of instruction blocks (i.e., a first plurality of instruction blocks predetermined at the time of the first pull) are not pulled. Alternatively or additionally, the first pulling of the instruction block can take place in such a way that the large number of instruction blocks 13 (previously) achieved during fuzzing or the part thereof are not pulled.

Das Ausschließen, dass bestimmte Anweisungsblöcke gezogen werden können, kann zum Beispiel dadurch erreicht werden, dass so lange ein Anweisungsblock gezogen wird, bis einer gezogen worden ist, der nicht ausgeschlossen werden soll. Alternativ kann zum Beispiel das (erste, später zweite) Wahrscheinlichkeitsmaß vor dem Ziehen derart modifiziert werden, dass nur nicht ausgeschlossene Anweisungsblöcke gezogen werden können. Eine solche Möglichkeit besteht zum Beispiel darin, (Abstands-)Gewichte der ausgeschlossenen Anweisungsblöcke mit Null zu skalieren und das so modifizierte Wahrscheinlichkeitsmaß zu renormieren.Excluding certain instruction blocks from being pulled can be achieved, for example, by dragging an instruction block until one that should not be excluded has been pulled. Alternatively, for example, the (first, later second) probability measure can be modified before drawing in such a way that only non-excluded instruction blocks can be drawn. One such possibility is, for example, to scale the (distance) weights of the excluded instruction blocks with zero and to renormalize the modified probability measure.

Durch das Ausschließen von bestimmten Anweisungsblöcke kann die Effizienz des Fuzzings weiter erhöht werden.By excluding certain instruction blocks, the efficiency of fuzzing can be further increased.

Das Verfahren 100 kann, wie z.B. schematisch als optionaler Schritt in 1b (Fortsetzung zu 1a) dargestellt, Auswählen 159 eines zweiten Anweisungsblocks der Software, wenn das erste Prüfen 140 positiv ausfällt (z.B. spätestens vor Schritt 160, z.B. bereits im Schritt 119) umfassen. Das Verfahren 100 kann weiterhin, wie z.B. in 1b als optionaler Schritt dargestellt, Setzen 160 eines zweiten Haltepunkts vor einer Anweisung des zweiten Anweisungsblock der Software in dem mindestens einen Haltepunktregister oder in einem weiteren Haltepunktregister, wenn das erste Prüfen 140 positiv ausfällt (z.B. spätestens vor Schritt 170, z.B. auch bereits im Schritt 120) umfassen. Setzen 160 des zweiten Haltepunkts vor der Anweisung des zweiten Anweisungsblocks der Software kann Setzen einer Speicheradresse der Anweisung des zweiten Anweisungsblocks in das mindestens eine Haltepunktregister oder in einem weiteren Haltepunktregister umfassen.The method 100 can, for example, be shown schematically as an optional step in 1b (continued to 1a) shown, selecting 159 a second instruction block of the software if the first check 140 is positive (eg at the latest before step 160, eg already in step 119). The method 100 can continue, as for example in 1b shown as an optional step, setting 160 a second breakpoint an instruction of the second instruction block of the software in the at least one breakpoint register or in a further breakpoint register if the first check 140 is positive (for example before step 170 at the latest, for example also in step 120). Setting 160 the second breakpoint before the instruction of the second instruction block of the software may include setting a memory address of the instruction of the second instruction block in the at least one breakpoint register or in another breakpoint register.

Das Verfahren 100 kann, wie z.B. in 1b als optionaler Schritt dargestellt, zweites Ausführen 170 einer Fuzzing-Iteration der Software (auf Basis von zur Fuzzing-Iteration dazugehörigen Fuzzing-Eingangsdaten) umfassen. Alternativ oder zusätzlich kann das Verfahren 100, wie z.B. in 1b als optionaler Schritt dargestellt, zweites Fortsetzen 171 der (bereits teilweise ausgeführten, aber angehaltenen) Fuzzing-Iteration der Software umfassen.The method 100 can, for example, in 1b shown as an optional step, include second execution 170 of a fuzzing iteration of the software (based on fuzzing input data associated with the fuzzing iteration). Alternatively or additionally, the method 100, such as in 1b shown as an optional step, include second continuation 171 of the (already partially executed but stopped) fuzzing iteration of the software.

Das Verfahren 100 kann, wie z.B. in 1b als optionaler Schritt dargestellt, zweites Prüfen 180, ob der zweite Haltepunkt beim zweiten Ausführen 170 oder zweiten Fortsetzen 171 der Fuzzing-Iteration erreicht wird, umfassen. Der zweite Haltepunkt wird dann erreicht, wenn ohne den zweiten Haltepunkt die Anweisung des zweiten Ausführungsblocks bei Ausführung der Software auf Basis der Fuzzing-Eingangsdaten der Fuzzing-Iteration ausgeführt worden wäre.The method 100 can, for example, in 1b shown as an optional step, second checking 180 whether the second breakpoint is reached during the second execution 170 or second continuation 171 of the fuzzing iteration. The second breakpoint is reached when, without the second breakpoint, the instruction of the second execution block would have been executed when the software was executed based on the fuzzing input data of the fuzzing iteration.

Das Verfahren 100 kann, wie z.B. in 1b als optionaler Schritt dargestellt, Speichern 190 einer zweiten Protokollinformation, dass der zweite Anweisungsblock in der Fuzzing-Iteration erreicht worden ist, wenn das zweite Prüfen 180 positiv ausfällt, umfassen.The method 100 can, for example, in 1b shown as an optional step, storing 190 a second protocol information that the second instruction block has been reached in the fuzzing iteration if the second check 180 is positive.

Das Verfahren 100 kann, wie z.B. in 1b als optionaler Schritt dargestellt, Löschen 191 des zweiten Haltepunkts, wenn das zweite Prüfen 180 positiv ausfällt, umfassen.The method 100 can, for example, in 1b shown as an optional step, deleting 191 the second breakpoint if the second check 180 is positive.

Das Softwareabdeckungsfeedback beim Fuzzing der Software kann die zweite Protokollinformation umfassen. Die zweite Protokollinformation kann zum Beispiel die bisherigen oder weiteren Fuzzing-Eingangsdaten der Fuzzing-Iteration umfassen.The software coverage feedback when fuzzing the software may include the second protocol information. The second protocol information can include, for example, the previous or further fuzzing input data of the fuzzing iteration.

Das Auswählen 159 des zweiten Anweisungsblocks der Software kann auf Abständen (z.B. d(b, b_i)] von Anweisungsblöcken 11 zu mindestens einem weiteren beim Fuzzing (z.B. bei einer früheren Fuzzing-Iteration oder bei der Fuzzing-Iteration der Software) erreichten Anweisungsblock in dem Kontrollflussgraphen 10 der Software basieren. Alternativ oder zusätzlich kann das Auswählen 159 des zweiten Anweisungsblocks der Software auf Abstandsgewichten (z.B. (d(b, b_i))^-1) von Anweisungsblöcken 11 zu mindestens einem weiteren beim Fuzzing (z.B. bei einer früheren Fuzzing-Iteration oder bei der Fuzzing-Iteration der Software) erreichten Anweisungsblock in dem Kontrollflussgraphen 10 der Software basieren.Selecting 159 the second instruction block of the software can be at distances (e.g. d(b, b_i)] from instruction blocks 11 to at least one further instruction block reached during fuzzing (e.g. in a previous fuzzing iteration or in the fuzzing iteration of the software) in the control flow graphs 10 of the software. Alternatively or additionally, the selection 159 of the second instruction block of the software can be based on distance weights (e.g. (d(b, b_i))^-1) from instruction blocks 11 to at least one further one during fuzzing (e.g. at a previous fuzzing Iteration or when fuzzing the software) is based on the instruction block reached in the control flow graph 10 of the software.

Der mindestens eine weitere beim Fuzzing erreichte Anweisungsblock kann, muss aber nicht beim ersten Ausführen 130 oder ersten Fortsetzen 131 der Fuzzing-Iteration der Software erreicht worden sein.The at least one further instruction block reached during fuzzing may, but does not have to, have been reached during the first execution 130 or first continuation 131 of the fuzzing iteration of the software.

Der mindestens eine weitere beim Fuzzing erreichte Anweisungsblock kann der mindestens eine beim Fuzzing erreichte Anweisungsblock sein.The at least one further instruction block reached during fuzzing can be the at least one instruction block reached during fuzzing.

Das Verfahren 100 kann, wie z.B. in 1b als optionaler Schritt dargestellt, Berechnen 158a mindestens eines Abstands von Anweisungsblöcken 11 zu dem mindestens einen weiteren beim Fuzzing (z.B. bei einer früheren Fuzzing-Iteration oder bei der Fuzzing-Iteration der Software) erreichten Anweisungsblock umfassen. Alternativ oder zusätzlich kann das Verfahren 100 Berechnen 158a mindestens eines Abstandsgewichts von Anweisungsblöcken 11 zu dem mindestens einen weiteren beim Fuzzing (z.B. bei einer früheren Fuzzing-Iteration oder bei der Fuzzing-Iteration der Software) erreichten Anweisungsblock umfassen.The method 100 can, for example, in 1b shown as an optional step, calculating 158a at least one distance from instruction blocks 11 to the at least one further instruction block reached during fuzzing (eg in an earlier fuzzing iteration or in the fuzzing iteration of the software). Alternatively or additionally, the method 100 may include calculating 158a at least one distance weight of instruction blocks 11 to the at least one further instruction block reached during fuzzing (eg in an earlier fuzzing iteration or in the fuzzing iteration of the software).

Die Abstände können, aber müssen nicht neu berechnet werden. Weiterhin können, aber müssen nicht die Abstandsgewichte neu berechnet werden. Eine Neuberechnung kann zum Beispiel sinnvoll sein, wenn Abstände und/oder Abstandsgewichte für einen anderen Teil des Kontrollflussgraphen 10 neu berechnet werden, d.h. wenn der Teil sich in der Zwischenzeit geändert hat.The distances can, but do not have to, be recalculated. Furthermore, the distance weights can, but do not have to, be recalculated. A recalculation can make sense, for example, if distances and/or distance weights are recalculated for another part of the control flow graph 10, i.e. if the part has changed in the meantime.

Das Verfahren kann, wie z.B. in 1b als optionaler Schritt dargestellt, Berechnen 158b eines zweiten Wahrscheinlichkeitsmaßes zu dem mindestens einen weiteren beim Fuzzing erreichten Anweisungsblock umfassen, wobei das zweite Wahrscheinlichkeitsmaß mindestens zwei Anweisungsblöcken des Kontrollflussgraphen 10 oder eines Teils davon jeweils ein normiertes Gewicht zuordnet, wobei die Gewichte derart normiert werden, dass die Summe aller Gewichte für die mindestens zwei Anweisungsblöcke eins ergeben kann.The procedure can, for example, in 1b shown as an optional step, calculating 158b a second probability measure for the at least one further instruction block reached during fuzzing, the second probability measure comprising at least two instruction blocks of the control flow Graphs 10 or a part thereof are each assigned a standardized weight, the weights being standardized in such a way that the sum of all weights for the at least two instruction blocks can result in one.

Das Auswählen 159 des zweiten Anweisungsblocks der Software - insbesondere, das Auswählen 159 des zweiten Anweisungsblocks der Software basierend auf Abständen, insbesondere Abstandsgewichten, von Anweisungsblöcken in dem Kontrollflussgraphen 10 - kann zufälliges oder zumindest pseudo-zufälliges zweites Ziehen eines Anweisungsblocks als zweiten Anweisungsblock aus den nach dem zweiten Wahrscheinlichkeitsmaß verteilten Anweisungsblöcken umfassen.Selecting 159 the second instruction block of the software - in particular, selecting 159 the second instruction block of the software based on distances, in particular distance weights, of instruction blocks in the control flow graph 10 - may involve random or at least pseudo-random second pulling of an instruction block as a second instruction block from the following include instruction blocks distributed according to the second probability measure.

Wie z.B. im Falle des ersten Wahrscheinlichkeitsmaßes kann ein Gewicht G eines (beliebigen) Anweisungsblocks 11 eine Summe von Abstandsgewichten des (beliebigen) Anweisungsblocks 11 zu je einem Anweisungsblock einer weiteren Vielzahl von beim Fuzzing erreichten Anweisungsblöcken oder eines Teils davon sein. Alternativ oder zusätzlich kann ein Gewicht G ein Abstandsgewicht des (beliebigen) Anweisungsblocks 11 zu je einem Anweisungsblock einer weiteren Vielzahl von beim Fuzzing erreichten Anweisungsblöcken oder eines Teils davon sein.As in the case of the first probability measure, for example, a weight G of an (arbitrary) instruction block 11 can be a sum of distance weights of the (arbitrary) instruction block 11 to an instruction block of a further plurality of instruction blocks achieved during fuzzing or a part thereof. Alternatively or additionally, a weight G can be a distance weight of the (arbitrary) instruction block 11 to an instruction block of a further plurality of instruction blocks achieved during fuzzing or a part thereof.

Die weitere Vielzahl von beim Fuzzing erreichten Anweisungsblöcken kann, muss aber nicht die Vielzahl von beim Fuzzing erreichten Anweisungsblöcken sein. Zum Beispiel kann sich die weitere Vielzahl von beim Fuzzing erreichten Anweisungsblöcken von der Vielzahl von beim Fuzzing erreichten Anweisungsblöcken insoweit unterscheiden, als die weitere Vielzahl von beim Fuzzing erreichten Anweisungsblöcken nun zusätzlich den ersten Anweisungsblock, so er im Schritt 130, 131 erreicht worden ist, umfasst.The further multiplicity of instruction blocks achieved during fuzzing can, but does not have to be, the multiplicity of instruction blocks achieved during fuzzing. For example, the further plurality of instruction blocks achieved during fuzzing can differ from the plurality of instruction blocks achieved during fuzzing in that the further plurality of instruction blocks achieved during fuzzing now additionally includes the first instruction block, if it was reached in step 130, 131 .

Prinzipiell kann das zweite Wahrscheinlichkeitsmaß das erste Wahrscheinlichkeitsmaß sein. In diesem Fall kann eine Neuberechnung entbehrlich sein. Allerdings kann (in der Regel) das zweite Wahrscheinlichkeitsmaß sich von dem ersten Wahrscheinlichkeitsmaß unterscheiden, insbesondere im Falle, dass sich die weitere Vielzahl von beim Fuzzing erreichten Anweisungsblöcken von der Vielzahl von beim Fuzzing erreichten Anweisungsblöcken unterscheidet. Eine Neuberechnung des Wahrscheinlichkeitsmaßes kann zum Beispiel auch dann sinnvoll sein, wenn sich der Teil des Kontrollflussgraphen 10 in der Zwischenzeit geändert hat.In principle, the second probability measure can be the first probability measure. In this case, a recalculation may be unnecessary. However, (as a rule) the second probability measure may differ from the first probability measure, in particular in the event that the further plurality of instruction blocks achieved during fuzzing differs from the plurality of instruction blocks achieved during fuzzing. A recalculation of the probability measure can also make sense, for example, if the part of the control flow graph 10 has changed in the meantime.

Das zweite Ziehen des Anweisungsblocks kann derart erfolgen, dass eine zweite Vielzahl von Anweisungsblöcken (d.h. eine zum Zeitpunkt des zweiten Ziehens vorbestimmte zweite Vielzahl von Anweisungsblöcken) nicht gezogen wird. Die zweite Vielzahl von Anweisungsblöcken kann, muss aber nicht die erste Vielzahl von Anweisungsblöcken sein. Alternativ oder zusätzlich kann das zweite Ziehen des Anweisungsblocks derart erfolgen, dass die weitere Vielzahl der beim Fuzzing erreichten Anweisungsblöcke oder des Teils davon nicht gezogen wird. Alternativ oder zusätzlich kann das zweite Ziehen des Anweisungsblocks derart erfolgen, dass der erste Anweisungsblock nicht gezogen wird.The second pull of the instruction block may occur such that a second plurality of instruction blocks (i.e., a second plurality of instruction blocks predetermined at the time of the second pull) are not pulled. The second plurality of instruction blocks may, but does not have to be, the first plurality of instruction blocks. Alternatively or additionally, the second pulling of the instruction block can take place in such a way that the further plurality of instruction blocks reached during fuzzing or the part thereof is not pulled. Alternatively or additionally, the second pulling of the instruction block can take place in such a way that the first instruction block is not pulled.

Wie bereits dargelegt, kann durch das Ausschließen von bestimmten Anweisungsblöcke die Effizienz des Fuzzings weiter erhöht werden.As already explained, the efficiency of fuzzing can be further increased by excluding certain instruction blocks.

Das Verfahren 100 kann, wie z.B. in 1b als optionaler Schritt dargestellt, Erzeugen 169 weiterer Fuzzing-Eingangsdaten für die Fuzzing-Iteration, optional basierend auf der ersten Protokollinformation, umfassen. Das zweite Ausführen 170 der Fuzzing-Iteration kann auf den weiteren Fuzzing-Eingangsdaten basieren.The method 100 can, for example, in 1b shown as an optional step, generating 169 further fuzzing input data for the fuzzing iteration, optionally based on the first protocol information. The second execution 170 of the fuzzing iteration may be based on the further fuzzing input data.

Das Setzen 120, 160 von Haltepunkten kann via eine Debugging-Verbindung zum Hardware-Target erfolgen. Weiterhin kann das Ausführen 130, 170 und/oder Fortsetzen 131, 171 der Fuzzing-Iteration via die Debugging-Verbindung zum Hardware-Target erfolgen. Das Verfahren 100 kann, wie z.B. in Fig. la als optionaler Schritt dargestellt, Initialisieren 110 der Debugging-Verbindung zum Hardware-Target umfassen.Setting 120, 160 breakpoints can be done via a debugging connection to the hardware target. Furthermore, the fuzzing iteration can be executed 130, 170 and/or continued 131, 171 via the debugging connection to the hardware target. The method 100 can, for example, as shown as an optional step in FIG. 1a, include initializing 110 the debugging connection to the hardware target.

Der erste Anweisungsblock der Software kann eine vorbestimmte Startfunktion (englisch: function to instrument) der Software umfassen. Eine solche Wahl kann dafür geeignet sein, das Fuzzing oder zumindest eine Fuzzing-Iteration des Fuzzing zu starten. Alternativ kann der erste Anweisungsblock ein beliebiger Anweisungsblock der Software (zum Beispiel bei Wiederholen 199) sein. Alternativ oder zusätzlich kann das Verfahren 100 mit dem Setzen eines (nullten) Haltepunkts vor einer beliebigen Anweisung der Software, insbesondere vor einer Anweisung eines beliebigen (nullten) Anweisungsblocks in dem Kontrollflussgraphen 10 gestartet werden.The first instruction block of the software may include a predetermined start function (function to instrument) of the software. Such a choice may be suitable for starting fuzzing or at least a fuzzing iteration of fuzzing. Alternatively, the first instruction block may be any instruction block in the software (for example, repeat 199). Alternatively or additionally, the method 100 can be started by setting a (zeroth) breakpoint before any instruction of the software, in particular before an instruction of any (zeroth) instruction block in the control flow graph 10.

Das Verfahren 100 kann, wie z.B. in Fig. la als optionaler Schritt dargestellt, Erzeugen 105 des Kontrollflussgraphen 10 der Software basierend auf dem Programmiercode der Software umfassen. Alternativ oder zusätzlich kann das Verfahren 100 Erzeugen 105 des Kontrollflussgraphen 10 der Software via Reverse engineering der Software umfassen. Alternativ oder zusätzlich kann das Verfahren 100 Erzeugen 105 des Kontrollflussgraphen 10 der Software sukzessive via Erlangung von Softwareabdeckungsfeedback beim Fuzzing der Software auf dem Hardware-Target umfassen.The method 100 can, for example, as shown as an optional step in FIG. 1a, comprise generating 105 the control flow graph 10 of the software based on the programming code of the software. Alternatively or additionally, the method 100 may include generating 105 the control flow graph 10 of the software via reverse engineering of the software. Alternatively or additionally, the method 100 may include generating 105 the control flow graph 10 of the software successively via obtaining software coverage feedback when fuzzing the software on the hardware target.

Das Verfahren 100 kann, wie z.B. in Fig. la als optionaler Schritt dargestellt, Speichern 152 einer ersten Protokollinformation umfassen, wobei die erste Protokollinformation umfasst, dass der erste Anweisungsblock in der Fuzzing-Iteration nicht erreicht worden ist, wenn das erste Prüfen 140 negativ verläuft. Das Verfahren 100 kann Löschen 151 des ersten Haltepunkts, wenn das erste Prüfen 140 negativ verläuft, umfassen. Das erste Prüfen 140 kann z.B. negativ verlaufen, wenn ein vorbestimmtes Kriterium erfüllt ist. Das vorbestimmte Kriterium kann zum Beispiel erfüllt sein, wenn der erste Haltepunkt nach einer vorbestimmten Zeitdauer oder bis zum Ende der Fuzzing-Iteration nicht erreicht wird.1a, the method 100 can include storing 152 a first protocol information, wherein the first protocol information includes that the first instruction block has not been reached in the fuzzing iteration if the first check 140 is negative . The method 100 may include deleting 151 the first breakpoint if the first check 140 is negative. The first test 140 can, for example, be negative if a predetermined criterion is met. The predetermined criterion can be met, for example, if the first breakpoint is not reached after a predetermined period of time or by the end of the fuzzing iteration.

Das Verfahren 100 kann, wie z.B. in 1b als optionaler Schritt dargestellt, Speichern 192 einer zweiten Protokollinformation umfassen, wobei die zweite Protokollinformation umfasst, dass der zweite Anweisungsblock in der Fuzzing-Iteration nicht erreicht worden ist, wenn das zweite Prüfen 180 negativ verläuft. Das Verfahren 100 kann Löschen 191 des zweiten Haltepunkts, wenn das zweite Prüfen 180 negativ verläuft, umfassen. Das zweite Prüfen 180 kann z.B. negativ verlaufen, wenn ein/das vorbestimmte Kriterium erfüllt ist. Das vorbestimmte Kriterium kann zum Beispiel erfüllt sein, wenn der zweite Haltepunkt nach einer vorbestimmten Zeitdauer oder bis zum Ende der Fuzzing-Iteration nicht erreicht wird.The method 100 can, for example, in 1b shown as an optional step, storing 192 a second protocol information, wherein the second protocol information includes that the second instruction block has not been reached in the fuzzing iteration if the second check 180 is negative. The method 100 may include deleting 191 the second breakpoint if the second test 180 is negative. The second test 180 can, for example, be negative if a/the predetermined criterion is met. The predetermined criterion can be met, for example, if the second breakpoint is not reached after a predetermined period of time or until the end of the fuzzing iteration.

Das Softwareabdeckungsfeedback beim Fuzzing der Software kann die erste und/oder zweite Protokollinformation umfassen. Die erste und/oder zweite Protokollinformation kann weiterhin zum Beispiel die (weiteren) Fuzzing-Eingangsdaten umfassen.The software coverage feedback when fuzzing the software may include the first and/or second protocol information. The first and/or second protocol information can further include, for example, the (further) fuzzing input data.

Das Verfahren 100 kann, wie z.B. in 1a oder 1b jeweils als optionaler Schritt dargestellt, Wiederholen 199 des Verfahrens 100 umfassen. Zum Beispiel kann das Verfahren 100 so lange wiederholt 199 werden, bis die Ausführung der Fuzzing-Iteration und/oder das Fuzzing beendet ist. Durch das Wiederholen 199 können sukzessive Haltepunkte gesetzt und somit Softwareabdeckungsfeedback beim Fuzzing erlangt werden. Das Wiederholen 199 kann z.B. mit einem erneuten Schritt 110, 118a, 118b, 119 oder 120 beginnen. Alternativ oder zusätzlich kann das Wiederholen 199 mit einem erneuten Schritt 158a, 158b, 159, 160 beginnen, wobei jede Durchnummerierung von Haltepunkten, Anweisungsblöcken etc. ums eins inkrementiert wird. Z.B. kann der erneute Schritt 160 somit lauten: Setzen eines dritten Haltepunkts vor einer Anweisung des dritten Anweisungsblocks, wenn das zweite Prüfen positiv ausfällt, etc.The method 100 can, for example, in 1a or 1b each shown as an optional step, repeating 199 of method 100. For example, the method 100 may be repeated 199 until the execution of the fuzzing iteration and/or the fuzzing is completed. By repeating 199 breakpoints can be set successively and thus software coverage feedback can be obtained during fuzzing. The repeat 199 can, for example, begin with a new step 110, 118a, 118b, 119 or 120. Alternatively or additionally, repeating 199 can begin with a new step 158a, 158b, 159, 160, with each numbering of breakpoints, instruction blocks, etc. being incremented by one. For example, the new step 160 can thus read: setting a third breakpoint before an instruction of the third instruction block if the second check is positive, etc.

Offenbart wird weiterhin ein Computer-System, dafür ausgelegt ist, das computer-implementierte Verfahren 100 zur Erlangung von Softwareabdeckungsfeedback beim Fuzzing der Software auf dem Hardware-Target auszuführen. Das Computer-System kann einen Prozessor und/oder einen Arbeitsspeicher umfassen. Das Computer-System kann dafür ausgelegt sein, über die Debugging-Verbindung mit dem Hardware-Target zu kommunizieren. Das Computer-System kann den Fuzzer umfassen, der dafür ausgelegt ist Fuzzing-Eingangsdaten für mindestens eine Fuzzing-Iteration der Software auf dem Hardware-Target zu generieren und bereitzustellen.Also disclosed is a computer system designed to execute the computer-implemented method 100 for obtaining software coverage feedback when fuzzing the software on the hardware target. The computer system may include a processor and/or memory. The computer system may be designed to communicate with the hardware target via the debugging connection. The computer system may include the fuzzer, which is designed to generate and provide fuzzing input data for at least one fuzzing iteration of the software on the hardware target.

Offenbart wird weiterhin ein Computer-Programm, das dafür ausgelegt ist, das computer-implementierte Verfahren 100 zur Erlangung von Softwareabdeckungsfeedback beim Fuzzing der Software auf dem Hardware-Target auszuführen. Das Computer-Programm kann z.B. in interpretierbarer oder in kompilierter Form vorliegen. Es kann (auch in Teilen) zur Ausführung z.B. als Bit- oder Byte-Folge in den RAM eines Computers geladen werden.Also disclosed is a computer program designed to execute the computer-implemented method 100 for obtaining software coverage feedback when fuzzing the software on the hardware target. The computer program can, for example, be in interpretable or compiled form. It can be loaded (even in parts) into the RAM of a computer for execution, for example as a bit or byte sequence.

Offenbart wird weiterhin ein computer-lesbares Medium oder Signal, das das Computer-Programm speichert und/oder enthält. Das Medium kann z.B. eines von RAM, ROM, EPROM, HDD, SDD, ... umfassen, auf/in dem das Signal gespeichert wird.Also disclosed is a computer-readable medium or signal that stores and/or contains the computer program. The medium may include, for example, one of RAM, ROM, EPROM, HDD, SDD, ... on which the signal is stored.

Claims (20)

Computer-implementiertes Verfahren (100) zur Erlangung von Softwareabdeckungsfeedback beim Fuzzing einer Software auf einem Hardware-Target, wobei das Hardware-Target mindestens ein Haltepunktregister aufweist und dafür ausgelegt ist, eine Ausführung der Software vor Ausführung einer Anweisung der Software anzuhalten, wenn die Anweisung bei der Ausführung der Software erreicht wird und eine Speicheradresse der Anweisung in dem mindestens einen Haltepunkteregister gesetzt ist, umfassend: - Auswählen (119) eines ersten Anweisungsblocks der Software; - Setzen (120) eines ersten Haltepunkts vor einer Anweisung des ersten Anweisungsblocks in dem mindestens einen Haltepunktregister; - erstes Ausführen (130) oder erstes Fortsetzen (131) einer Fuzzing-Iteration der Software; - erstes Prüfen (140), ob der erste Haltepunkt beim ersten Ausführen (130) oder ersten Fortsetzen (131) der Fuzzing-Iteration erreicht wird; - Speichern (150) einer ersten Protokollinformation umfassend, dass der erste Anweisungsblock in der Fuzzing-Iteration erreicht worden ist - und, optional, Löschen (151) des ersten Haltepunkts - wenn das erste Prüfen (140) positiv ausfällt; wobei das Softwareabdeckungsfeedback beim Fuzzing der Software die erste Protokollinformation umfasst; wobei das Auswählen (119) des ersten Anweisungsblocks der Software auf Abständen, optional Abstandsgewichten, von Anweisungsblöcken (11) zu mindestens einem beim Fuzzing erreichten Anweisungsblock (13) in einem Kontrollflussgraphen (10) der Software basiert.A computer-implemented method (100) for obtaining software coverage feedback when fuzzing software on a hardware target, the hardware target having at least one breakpoint register and being configured to require execution of the software before executing an instruction stopping the software when the instruction is reached during execution of the software and a memory address of the instruction is set in the at least one breakpoint register, comprising: - selecting (119) a first instruction block of the software; - Setting (120) a first breakpoint before an instruction of the first instruction block in the at least one breakpoint register; - first executing (130) or first continuing (131) a fuzzing iteration of the software; - first checking (140) whether the first breakpoint is reached when the fuzzing iteration is first executed (130) or continued (131); - storing (150) first protocol information comprising that the first instruction block has been reached in the fuzzing iteration - and, optionally, deleting (151) the first breakpoint - if the first check (140) is positive; wherein the software coverage feedback includes the first protocol information when fuzzing the software; wherein the selection (119) of the first instruction block of the software is based on distances, optionally distance weights, from instruction blocks (11) to at least one instruction block (13) reached during fuzzing in a control flow graph (10) of the software. Verfahren (100) nach Anspruch 1, wobei ein Abstand eines Anweisungsblocks (11) zu dem mindestens einen beim Fuzzing erreichten Anweisungsblock ein Minimum aus: - einer minimalen Pfadlänge von dem Anweisungsblock (11) zu dem mindestens einen beim Fuzzing erreichten Anweisungsblock; und/oder - einer minimalen Pfadlänge von dem mindestens einen beim Fuzzing erreichten Anweisungsblock zu dem Anweisungsblock (11); ist.Procedure (100) according to Claim 1 , wherein a distance of an instruction block (11) to the at least one instruction block reached during fuzzing is a minimum of: - a minimum path length from the instruction block (11) to the at least one instruction block reached during fuzzing; and/or - a minimum path length from the at least one instruction block reached during fuzzing to the instruction block (11); is. Verfahren (100) nach Anspruch 2, wobei eine Pfadlänge von einem Anweisungsblock zu einem anderen Anweisungsblock ein zumindest approximatives Maß dafür ist, - ob ein Pfad, in dem Kontrollflussgraphen (10) oder einem Teil davon, umfassend mindestens eine gerichtete Kante (12) ausgehend von dem einen Anweisungsblock und in Flussrichtung zu dem anderen Anweisungsblock existiert; und/oder - wie lang ein solcher Pfad ist, so dieser existiert, insbesondere wie viele der mindestens einen gerichteten Kante (12) dieser Pfad umfasst.Procedure (100) according to Claim 2 , wherein a path length from one instruction block to another instruction block is an at least approximate measure of - whether a path, in the control flow graph (10) or a part thereof, comprising at least one directed edge (12) starting from the one instruction block and in the flow direction to the other statement block exists; and/or - how long such a path is if it exists, in particular how many of the at least one directed edge (12) this path includes. Verfahren (100) nach einem der vorhergehenden Ansprüche, wobei ein Abstandsgewicht eines Anweisungsblocks (11) zu dem mindestens einen beim Fuzzing erreichten Anweisungsblock auf dem Abstand des Anweisungsblocks (11) zu dem mindestens einen beim Fuzzing erreichten Anweisungsblock basiert; - optional, wobei das Abstandsgewicht groß ist, wenn der Abstand klein ist, und wobei das Abstandsgewicht klein ist, wenn der Abstand groß ist; - optional, wobei das Abstandsgewicht umgekehrt proportional zum Abstand ist; - optional, wobei das Abstandsgewicht ein Kehrwert des Abstands ist.Method (100) according to one of the preceding claims, wherein a distance weight of an instruction block (11) to the at least one instruction block reached during fuzzing is based on the distance of the instruction block (11) to the at least one instruction block reached during fuzzing; - optional, where the distance weight is large when the distance is small, and where the distance weight is small when the distance is large; - optional, where the distance weight is inversely proportional to the distance; - optional, where the distance weight is a reciprocal of the distance. Verfahren (100) nach einem der vorhergehenden Ansprüche, umfassend: - Berechnen (118a) mindestens eines Abstands, optional mindestens eines Abstandsgewichts, von Anweisungsblöcken (11) zu dem mindestens einen beim Fuzzing erreichten Anweisungsblock.Method (100) according to one of the preceding claims, comprising: - Calculating (118a) at least one distance, optionally at least one distance weight, from instruction blocks (11) to the at least one instruction block reached during fuzzing. Verfahren (100) nach einem der vorhergehenden Ansprüche, umfassend: - Berechnen (118b) eines ersten Wahrscheinlichkeitsmaßes zu dem mindestens einen beim Fuzzing erreichten Anweisungsblock, wobei das erste Wahrscheinlichkeitsmaß mindestens zwei Anweisungsblöcken des Kontrollflussgraphen (10) oder eines Teils davon jeweils ein normiertes Gewicht zuordnet, wobei die Gewichte derart normiert werden, dass die Summe aller Gewichte für die mindestens zwei Anweisungsblöcke eins ergibt; wobei das Auswählen (119) des ersten Anweisungsblocks der Software - insbesondere, das Auswählen (119) des ersten Anweisungsblocks der Software basierend auf Abständen, insbesondere Abstandsgewichten, der Anweisungsblöcke zu dem mindestens einem beim Fuzzing erreichten Anweisungsblock in dem Kontrollflussgraphen (10) - zufälliges erstes Ziehen eines Anweisungsblocks als ersten Anweisungsblock aus den nach dem ersten Wahrscheinlichkeitsmaß verteilten Anweisungsblöcken umfasst; wobei ein Gewicht eines Anweisungsblocks (11): - eine Summe von Abstandsgewichten des Anweisungsblocks (11) zu je einem Anweisungsblock einer Vielzahl von beim Fuzzing erreichten Anweisungsblöcken oder eines Teils davon; und/oder - ein Abstandsgewicht des Anweisungsblocks (11) zu je einem Anweisungsblock einer Vielzahl von beim Fuzzing erreichten Anweisungsblöcken oder eines Teils davon; ist.Method (100) according to one of the preceding claims, comprising: - Calculating (118b) a first probability measure for the at least one instruction block reached during fuzzing, the first probability measure assigning a standardized weight to at least two instruction blocks of the control flow graph (10) or a part thereof, the weights being normalized in such a way that the sum of all Weights for at least two instruction blocks equal one; wherein selecting (119) the first instruction block of the software - in particular, selecting (119) the first instruction block of the software based on distances, in particular distance weights, of the instruction blocks to the at least one instruction block in the control flow graph (10) reached during fuzzing - random first drawing an instruction block as a first instruction block from the instruction blocks distributed according to the first probability measure; where a weight of an instruction block (11): - a sum of distance weights of the instruction block (11) to one instruction block of a plurality of instruction blocks reached during fuzzing or a part thereof; and or - a distance weight of the instruction block (11) to one instruction block of a plurality of instruction blocks reached during fuzzing or a part thereof; is. Verfahren (100) nach Anspruch 6, wobei das erste Ziehen des Anweisungsblocks derart erfolgt, dass: - eine erste Vielzahl von Anweisungsblöcken; und/oder - die Vielzahl der beim Fuzzing erreichten Anweisungsblöcke oder des Teils davon; nicht gezogen werden.Procedure (100) according to Claim 6 , wherein the first pulling of the instruction block is such that: - a first plurality of instruction blocks; and/or - the plurality of instruction blocks or part thereof reached during fuzzing; not be pulled. Verfahren (100) nach einem der vorhergehenden Ansprüche, umfassend: - Auswählen (159) eines zweiten Anweisungsblocks der Software, wenn das erste Prüfen (140) positiv ausfällt; - Setzen (160) eines zweiten Haltepunkts vor einer Anweisung des zweiten Anweisungsblock der Software in dem mindestens einen Haltepunktregister oder in einem weiteren Haltepunktregister, wenn das erste Prüfen (140) positiv ausfällt; - zweites Ausführen (170) einer Fuzzing-Iteration oder zweites Fortsetzen (171) der Fuzzing-Iteration der Software; - zweites Prüfen (180), ob der zweite Haltepunkt beim zweiten Ausführen (170) oder zweiten Fortsetzen (171) der Fuzzing-Iteration erreicht wird; - Speichern (190) einer zweiten Protokollinformation umfassend, dass der zweite Anweisungsblock in der Fuzzing-Iteration erreicht worden ist - und, optional, Löschen (191) des zweiten Haltepunkts - wenn das zweite Prüfen (180) positiv ausfällt; wobei das Softwareabdeckungsfeedback beim Fuzzing der Software die zweite Protokollinformation umfasst, wobei das Auswählen (159) des zweiten Anweisungsblocks der Software auf Abständen, optional Abstandsgewichten, von Anweisungsblöcken (11) zu mindestens einem weiteren beim Fuzzing erreichten Anweisungsblock in dem Kontrollflussgraphen (10) der Software basiert; optional, wobei der mindestens eine weitere beim Fuzzing erreichte Anweisungsblock beim ersten Ausführen (130) oder ersten Fortsetzen (131) der Fuzzing-Iteration der Software erreicht worden ist.Method (100) according to one of the preceding claims, comprising: - Selecting (159) a second instruction block of the software if the first test (140) is positive; - Setting (160) a second breakpoint before an instruction of the second instruction block of the software in the at least one breakpoint register or in a further breakpoint register if the first check (140) is positive; - secondly executing (170) a fuzzing iteration or secondly continuing (171) the fuzzing iteration of the software; - second checking (180) whether the second breakpoint is reached during the second execution (170) or second continuation (171) of the fuzzing iteration; - storing (190) second protocol information comprising that the second instruction block has been reached in the fuzzing iteration - and, optionally, deleting (191) the second breakpoint - if the second check (180) is positive; wherein the software coverage feedback includes the second protocol information when fuzzing the software, wherein selecting (159) the second instruction block of the software is based on distances, optionally distance weights, from instruction blocks (11) to at least one further instruction block reached during fuzzing in the control flow graph (10) of the software; optionally, whereby the at least one further instruction block reached during fuzzing has been reached the first time the fuzzing iteration of the software is executed (130) or continued (131). Verfahren (100) nach Anspruch 8, umfassend: - Berechnen (158a) mindestens eines Abstands, optional mindestens eines Abstandsgewichts, von Anweisungsblöcken (11) zu dem mindestens einen weiteren beim Fuzzing erreichten Anweisungsblock.Procedure (100) according to Claim 8 , comprising: - Calculating (158a) at least one distance, optionally at least one distance weight, from instruction blocks (11) to the at least one further instruction block reached during fuzzing. Verfahren (100) nach Anspruch 8 oder 9, umfassend: - Berechnen (158b) eines zweiten Wahrscheinlichkeitsmaßes zu dem mindestens einen weiteren beim Fuzzing erreichten Anweisungsblock, wobei das zweite Wahrscheinlichkeitsmaß mindestens zwei Anweisungsblöcken des Kontrollflussgraphen (10) oder eines Teils davon jeweils ein normiertes Gewicht zuordnet, wobei die Gewichte derart normiert werden, dass die Summe aller Gewichte für die mindestens zwei Anweisungsblöcke eins ergibt; wobei das Auswählen (159) des zweiten Anweisungsblocks der Software - insbesondere, das Auswählen (159) des zweiten Anweisungsblocks der Software basierend auf Abständen, insbesondere Abstandsgewichten, von Anweisungsblöcken in dem Kontrollflussgraphen (10) - zufälliges zweites Ziehen eines Anweisungsblocks als zweiten Anweisungsblock aus den nach dem zweiten Wahrscheinlichkeitsmaß verteilten Anweisungsblöcken umfasst; wobei ein Gewicht eines Anweisungsblocks (11): - eine Summe von Abstandsgewichten des Anweisungsblocks (11) zu je einem Anweisungsblock einer weiteren Vielzahl von beim Fuzzing erreichten Anweisungsblöcken oder eines Teils davon; und/oder - ein Abstandsgewicht des Anweisungsblocks (11) zu je einem Anweisungsblock einer weiteren Vielzahl von beim Fuzzing erreichten Anweisungsblöcken oder eines Teils davon; ist.Procedure (100) according to Claim 8 or 9 , comprising: - Calculating (158b) a second probability measure for the at least one further instruction block reached during fuzzing, the second probability measure assigning a standardized weight to at least two instruction blocks of the control flow graph (10) or a part thereof, the weights being standardized in this way, that the sum of all weights for the at least two instruction blocks equals one; wherein selecting (159) the second instruction block of the software - in particular, selecting (159) the second instruction block of the software based on distances, in particular distance weights, of instruction blocks in the control flow graph (10) - randomly second pulling an instruction block as a second instruction block from the instruction blocks distributed according to the second probability measure; wherein a weight of an instruction block (11): - a sum of distance weights of the instruction block (11) to each instruction block of a further plurality of instruction blocks reached during fuzzing or a part thereof; and/or - a distance weight of the instruction block (11) to an instruction block of a further plurality of instruction blocks reached during fuzzing or a part thereof; is. Verfahren (100) nach Anspruch 10, wobei das zweite Ziehen des Anweisungsblocks derart erfolgt, dass: - eine zweite Vielzahl von Anweisungsblöcken; - die weitere Vielzahl der beim Fuzzing erreichten Anweisungsblöcke oder des Teils davon; und/oder - der erste Anweisungsblock; nicht gezogen werden.Procedure (100) according to Claim 10 , wherein the second pulling of the instruction block is such that: - a second plurality of instruction blocks; - the further multitude of instruction blocks or parts thereof achieved during fuzzing; and/or - the first instruction block; not be pulled. Verfahren (100) nach einem der Ansprüche 8 bis 11, umfassend: - Erzeugen (169) weiterer Fuzzing-Eingangsdaten für die Fuzzing-Iteration, optional basierend auf der ersten Protokollinformation. wobei das zweite Ausführen (170) der Fuzzing-Iteration auf den weiteren Fuzzing-Eingangsdaten basiert.Method (100) according to one of Claims 8 until 11 , comprising: - Generating (169) further fuzzing input data for the fuzzing iteration, optionally based on the first protocol information. wherein the second execution (170) of the fuzzing iteration is based on the further fuzzing input data. Verfahren (100) nach einem der vorhergehenden Ansprüche, wobei die Software nicht statisch für Fuzzing instrumentiert ist und/oder closed-source ist.Method (100) according to one of the preceding claims, wherein the software is not statically instrumented for fuzzing and/or is closed-source. Verfahren (100) nach einem der vorhergehenden Ansprüche, umfassend: - Erzeugen (105) des Kontrollflussgraphen (10) der Software basierend auf dem Programmiercode der Software, via Reverse engineering der Software und/oder sukzessive via Erlangung von Softwareabdeckungsfeedback beim Fuzzing der Software auf dem Hardware-Target.Method (100) according to one of the preceding claims, comprising: - generating (105) the control flow graph (10) of the software based on the programming code of the software, via reverse engineering of the software and / or successively via obtaining software coverage feedback when fuzzing the software on the Hardware target. Verfahren (100) nach einem der vorhergehenden Ansprüche, wobei das Hardware-Target eine elektronische Steuereinheit ist und die Software dafür ausgelegt ist, die elektronische Steuereinheit zu steuern, regeln und/oder zu überwachen.Method (100) according to one of the preceding claims, wherein the hardware target is an electronic control unit and the software is designed to control, regulate and / or monitor the electronic control unit. Verfahren (100) nach einem der vorhergehenden Ansprüche, umfassend: - Speichern (152) einer ersten Protokollinformation umfassend, dass der erste Anweisungsblock in der Fuzzing-Iteration nicht erreicht worden ist - und, optional, Löschen (151) des ersten Haltepunkts - wenn das erste Prüfen (140) negativ verläuft, wobei das erste Prüfen (140) negativ verläuft, wenn der erste Haltepunkt nach einer vorbestimmten Zeitdauer oder bis zum Ende der Fuzzing-Iteration nicht erreicht wird; und/oder - Speichern (192) einer zweiten Protokollinformation umfassend, dass der zweite Anweisungsblock in der Fuzzing-Iteration nicht erreicht worden ist - und, optional, Löschen (191) des zweiten Haltepunkts - wenn das zweite Prüfen (180) negativ verläuft, wobei das zweite Prüfen (180) negativ verläuft, wenn der zweite Haltepunkt nach einer vorbestimmten Zeitdauer oder bis zum Ende der Fuzzing-Iteration nicht erreicht wird; wobei das Softwareabdeckungsfeedback beim Fuzzing der Software die erste und/oder zweite Protokollinformation umfasst.Method (100) according to one of the preceding claims, comprising: - storing (152) first protocol information comprising that the first instruction block has not been reached in the fuzzing iteration - and, optionally, deleting (151) the first breakpoint - if the first check (140) is negative, the first check (140) is negative if the first breakpoint is not reached after a predetermined period of time or until the end of the fuzzing iteration; and or - storing (192) second protocol information comprising that the second instruction block has not been reached in the fuzzing iteration - and, optionally, deleting (191) the second breakpoint - if the second check (180) is negative, the second check (180) is negative if the second breakpoint is not reached after a predetermined period of time or until the end of the fuzzing iteration; wherein the software coverage feedback includes the first and/or second protocol information when fuzzing the software. Verfahren (100) nach einem der vorhergehenden Ansprüche, umfassend: - Wiederholen (199) des Verfahrens (100) nach einem der vorhergehenden Ansprüche.Method (100) according to one of the preceding claims, comprising: - Repeating (199) the method (100) according to one of the preceding claims. Computer-System, dafür ausgelegt, das computer-implementierte Verfahren (100) zur Erlangung von Softwareabdeckungsfeedback beim Fuzzing der Software auf dem Hardware-Target nach einem der vorhergehenden Ansprüche auszuführen.Computer system adapted to carry out the computer-implemented method (100) for obtaining software coverage feedback when fuzzing the software on the hardware target according to any one of the preceding claims. Computer-Programm, dafür ausgelegt, das computer-implementierte Verfahren (100) zur Erlangung von Softwareabdeckungsfeedback beim Fuzzing der Software auf dem Hardware-Target nach einem der Ansprüche 1 bis 17 auszuführen.Computer program designed to implement the computer-implemented method (100) for obtaining software coverage feedback when fuzzing the software on the hardware target according to one of the Claims 1 until 17 to carry out. Computer-lesbares Medium oder Signal, das das Computer-Programm nach Anspruch 19 speichert und/oder enthält.Computer-readable medium or signal that the computer program reads Claim 19 stores and/or contains.
DE102022203357.4A 2022-04-05 2022-04-05 FUZZING WITH SOFTWARE COVERAGE FEEDBACK THROUGH DYNAMIC INSTRUMENTATION BASED ON DISTANCES OF INSTRUCTION BLOCKS IN CONTROL FLOW GRAPH Pending DE102022203357A1 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
DE102022203357.4A DE102022203357A1 (en) 2022-04-05 2022-04-05 FUZZING WITH SOFTWARE COVERAGE FEEDBACK THROUGH DYNAMIC INSTRUMENTATION BASED ON DISTANCES OF INSTRUCTION BLOCKS IN CONTROL FLOW GRAPH
CN202310356784.0A CN116893956A (en) 2022-04-05 2023-04-04 Fuzzy test with software overlay feedback by dynamic instrumentation based on spacing of statement blocks in a control flow graph

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
DE102022203357.4A DE102022203357A1 (en) 2022-04-05 2022-04-05 FUZZING WITH SOFTWARE COVERAGE FEEDBACK THROUGH DYNAMIC INSTRUMENTATION BASED ON DISTANCES OF INSTRUCTION BLOCKS IN CONTROL FLOW GRAPH

Publications (1)

Publication Number Publication Date
DE102022203357A1 true DE102022203357A1 (en) 2023-10-05

Family

ID=88019308

Family Applications (1)

Application Number Title Priority Date Filing Date
DE102022203357.4A Pending DE102022203357A1 (en) 2022-04-05 2022-04-05 FUZZING WITH SOFTWARE COVERAGE FEEDBACK THROUGH DYNAMIC INSTRUMENTATION BASED ON DISTANCES OF INSTRUCTION BLOCKS IN CONTROL FLOW GRAPH

Country Status (2)

Country Link
CN (1) CN116893956A (en)
DE (1) DE102022203357A1 (en)

Also Published As

Publication number Publication date
CN116893956A (en) 2023-10-17

Similar Documents

Publication Publication Date Title
DE69831732T2 (en) METHOD AND DEVICE FOR CORRECTING ERRORS IN A COMPUTER SYSTEM
DE69909945T2 (en) Method and arrangement for correlating profile data dynamically generated by an optimized executable program with source code instructions
EP2137615B1 (en) Method for the computer-aided determination of the dependencies of a plurality of modules of a technical system, especially of a software system
DE102006019292A1 (en) Modeling programmable devices
DE102014102551A1 (en) Machine and method for evaluating failed software programs
EP2442248A1 (en) Coupling method for non-iterative co-simulation
DE202016008043U1 (en) Apparatus for creating, collecting, storing and loading debug information for failed test scripts
DE112014002960T5 (en) Derivation of generalized test cases
DE112018002316T5 (en) CODE COVERAGE TRACKING FOR A MICROCONTROLLER PROGRAM
DE102022203357A1 (en) FUZZING WITH SOFTWARE COVERAGE FEEDBACK THROUGH DYNAMIC INSTRUMENTATION BASED ON DISTANCES OF INSTRUCTION BLOCKS IN CONTROL FLOW GRAPH
US10579761B1 (en) Method and system for reconstructing a graph presentation of a previously executed verification test
DE112017002779T5 (en) Format specific data processing operations
Sousa et al. Evaluating co-occurrence of GOF design patterns with god class and long method bad smells
DE102022203356A1 (en) FUZZING WITH SOFTWARE COVERAGE FEEDBACK THROUGH DYNAMIC INSTRUMENTATION BASED ON CONNECTIVITIES OF STATEMENT BLOCKS IN CONTROL FLOW GRAPH
DE102009009172B4 (en) Mapping addresses of a program code and addresses of data in a memory
DE102018128342A1 (en) A processor device that collects performance information through a command-set based replay
DE102021212596A1 (en) FUZZING WITH SOFTWARE COVERAGE FEEDBACK THROUGH DYNAMIC INSTRUMENTATION
DE102021212597A1 (en) MEMORY USAGE-BASED FUZZING
DE10058371A1 (en) Management of non-fixed register values during random program generation e.g. for design verification of CPUs, requires marking a value state as non-fixed when the content is unknown and when any desired content can be generated
DE10126018A1 (en) Method for providing error information about inconsistencies in a system of differential equations
Costa et al. Characterization of dynamic memory allocations in real-world applications: an experimental study
AL-Zaghameem An aspect oriented programming framework to support transparent runtime monitoring of applications
Pizzarello An industrial experience in the use of UNITY
DE102022202697A1 (en) Method for providing a blockchain
DE102010032765B4 (en) Automatic verification of translations