34 research outputs found

    Reverse Engineering Mobile Apps for Model Generation Using a Hybrid Approach

    Get PDF
    The popularity of mobile devices is ever increasing which led to rapid increase in the development of mobile applications. Model-Based testing can improve the quality of mobile application but the models are not always available or are of inadequate quality. Reverse engineering approaches are used to automatically generate model from the GUI of mobile applications for model-based testing. This paper proposes a hybrid approach for reverse engineering mobile applications which exploit the capabilities of both static and dynamic approaches while trying to maximize the quality of the generated models. The insight of this approach is to use static analysis on app’s source to identify supported events. The generated events can be used to dynamically explore an app at run-time to generate a state model of the app’s GUI. The preliminary results from our approach indicated that the technique can generate high quality models from android apps

    Learning the language of apps

    Get PDF
    To explore the functionality of an app, automated test generators systematically identify and interact with its user interface (UI) elements. A key challenge is to synthesize inputs which effectively and efficiently cover app behavior. To do so, a test generator has to choose which elements to interact with but, which interactions to do on each element and which input values to type. In summary, to better test apps, a test generator should know the app's language, that is, the language of its graphical interactions and the language of its textual inputs. In this work, we show how a test generator can learn the language of apps and how this knowledge is modeled to create tests. We demonstrate how to learn the language of the graphical input prior to testing by combining machine learning and static analysis, and how to refine this knowledge during testing using reinforcement learning. In our experiments, statically learned models resulted in 50\% less ineffective actions an average increase in test (code) coverage of 19%, while refining these through reinforcement learning resulted in an additional test (code) coverage of up to 20%. We learn the language of textual inputs, by identifying the semantics of input fields in the UI and querying the web for real-world values. In our experiments, real-world values increase test (code) coverage ~10%; Finally, we show how to use context-free grammars to integrate both languages into a single representation (UI grammar), giving back control to the user. This representation can then be: mined from existing tests, associated to the app source code, and used to produce new tests. 82% test cases produced by fuzzing our UI grammar can reach a UI element within the app and 70% of them can reach a specific code location.Automatisierte Testgeneratoren identifizieren systematisch Elemente der Benutzeroberfläche und interagieren mit ihnen, um die Funktionalität einer App zu erkunden. Eine wichtige Herausforderung besteht darin, Eingaben zu synthetisieren, die das App-Verhalten effektiv und effizient abdecken. Dazu muss ein Testgenerator auswählen, mit welchen Elementen interagiert werden soll, welche Interaktionen jedoch für jedes Element ausgeführt werden sollen und welche Eingabewerte eingegeben werden sollen. Um Apps besser testen zu können, sollte ein Testgenerator die Sprache der App kennen, dh die Sprache ihrer grafischen Interaktionen und die Sprache ihrer Texteingaben. In dieser Arbeit zeigen wir, wie ein Testgenerator die Sprache von Apps lernen kann und wie dieses Wissen modelliert wird, um Tests zu erstellen. Wir zeigen, wie die Sprache der grafischen Eingabe lernen vor dem Testen durch maschinelles Lernen und statische Analyse kombiniert und wie dieses Wissen weiter verfeinern beim Testen Verstärkung Lernen verwenden. In unseren Experimenten führten statisch erlernte Modelle zu 50% weniger ineffektiven Aktionen, was einer durchschnittlichen Erhöhung der Testabdeckung (Code) von 19% entspricht, während die Verfeinerung dieser durch verstärkendes Lernen zu einer zusätzlichen Testabdeckung (Code) von bis zu 20% führte. Wir lernen die Sprache der Texteingaben, indem wir die Semantik der Eingabefelder in der Benutzeroberfläche identifizieren und das Web nach realen Werten abfragen. In unseren Experimenten erhöhen reale Werte die Testabdeckung (Code) um ca. 10%; Schließlich zeigen wir, wie kontextfreien Grammatiken verwenden beide Sprachen in einer einzigen Darstellung (UI Grammatik) zu integrieren, wieder die Kontrolle an den Benutzer zu geben. Diese Darstellung kann dann: aus vorhandenen Tests gewonnen, dem App-Quellcode zugeordnet und zur Erstellung neuer Tests verwendet werden. 82% Testfälle, die durch Fuzzing unserer UI-Grammatik erstellt wurden, können ein UI-Element in der App erreichen, und 70% von ihnen können einen bestimmten Code-Speicherort erreichen

    Securing emerging IoT systems through systematic analysis and design

    Get PDF
    The Internet of Things (IoT) is growing very rapidly. A variety of IoT systems have been developed and employed in many domains such as smart home, smart city and industrial control, providing great benefits to our everyday lives. However, as IoT becomes increasingly prevalent and complicated, it is also introducing new attack surfaces and security challenges. We are seeing numerous IoT attacks exploiting the vulnerabilities in IoT systems everyday. Security vulnerabilities may manifest at different layers of the IoT stack. There is no single security solution that can work for the whole ecosystem. In this dissertation, we explore the limitations of emerging IoT systems at different layers and develop techniques and systems to make them more secure. More specifically, we focus on three of the most important layers: the user rule layer, the application layer and the device layer. First, on the user rule layer, we characterize the potential vulnerabilities introduced by the interaction of user-defined automation rules. We introduce iRuler, a static analysis system that uses model checking to detect inter-rule vulnerabilities that exist within trigger-action platforms such as IFTTT in an IoT deployment. Second, on the application layer, we design and build ProvThings, a system that instruments IoT apps to generate data provenance that provides a holistic explanation of system activities, including malicious behaviors. Lastly, on the device layer, we develop ProvDetector and SplitBrain to detect malicious processes using kernel-level provenance tracking and analysis. ProvDetector is a centralized approach that collects all the audit data from the clients and performs detection on the server. SplitBrain extends ProvDetector with collaborative learning, where the clients collaboratively build the detection model and performs detection on the client device

    BINARY INSTRUMENTATION AND TRANSFORMATION FOR SOFTWARE SECURITY APPLICATIONS

    Get PDF
    The capabilities of software analysis and manipulation are crucial to counter software security threats such as malware and vulnerabilities. Binary instrumentation and transformation are the essential techniques to enable software analysis and manipulation. However, existing approaches fail to meet requirements (e.g. flexibility, transparency) specific in software security applications

    A Novel Method for Adaptive Control of Manufacturing Equipment in Cloud Environments

    Get PDF
    The ability to adaptively control manufacturing equipment, both in local and distributed environments, is becoming increasingly more important for many manufacturing companies. One important reason for this is that manufacturing companies are facing increasing levels of changes, variations and uncertainty, caused by both internal and external factors, which can negatively impact their performance. Frequently changing consumer requirements and market demands usually lead to variations in manufacturing quantities, product design and shorter product life-cycles. Variations in manufacturing capability and functionality, such as equipment breakdowns, missing/worn/broken tools and delays, also contribute to a high level of uncertainty. The result is unpredictable manufacturing system performance, with an increased number of unforeseen events occurring in these systems. Events which are difficult for traditional planning and control systems to satisfactorily manage. For manufacturing scenarios such as these, the use of real-time manufacturing information and intelligence is necessary to enable manufacturing activities to be performed according to actual manufacturing conditions and requirements, and not according to a pre-determined process plan. Therefore, there is a need for an event-driven control approach to facilitate adaptive decision-making and dynamic control capabilities. Another reason driving the move for adaptive control of manufacturing equipment is the trend of increasing globalization, which forces manufacturing industry to focus on more cost-effective manufacturing systems and collaboration within global supply chains and manufacturing networks. Cloud Manufacturing is evolving as a new manufacturing paradigm to match this trend, enabling the mutually advantageous sharing of resources, knowledge and information between distributed companies and manufacturing units. One of the crucial objectives for Cloud Manufacturing is the coordinated planning, control and execution of discrete manufacturing operations in collaborative and networked environments. Therefore, there is also a need that such an event-driven control approach supports the control of distributed manufacturing equipment. The aim of this research study is to define and verify a novel and comprehensive method for adaptive control of manufacturing equipment in cloud environments. The presented research follows the Design Science Research methodology. From a review of research literature, problems regarding adaptive manufacturing equipment control have been identified. A control approach, building on a structure of event-driven Manufacturing Feature Function Blocks, supported by an Information Framework, has been formulated. The Function Block structure is constructed to generate real-time control instructions, triggered by events from the manufacturing environment. The Information Framework uses the concept of Ontologies and The Semantic Web to enable description and matching of manufacturing resource capabilities and manufacturing task requests in distributed environments, e.g. within Cloud Manufacturing. The suggested control approach has been designed and instantiated, implemented as prototype systems for both local and distributed manufacturing scenarios, in both real and virtual applications. In these systems, event-driven Assembly Feature Function Blocks for adaptive control of robotic assembly tasks have been used to demonstrate the applicability of the control approach. The utility and performance of these prototype systems have been tested, verified and evaluated for different assembly scenarios. The proposed control approach has many promising characteristics for use within both local and distributed environments, such as cloud environments. The biggest advantage compared to traditional control is that the required control is created at run-time according to actual manufacturing conditions. The biggest obstacle for being applicable to its full extent is manufacturing equipment controlled by proprietary control systems, with native control languages. To take the full advantage of the IEC Function Block control approach, controllers which can interface, interpret and execute these Function Blocks directly, are necessary

    Fundamental Approaches to Software Engineering

    Get PDF
    computer software maintenance; computer software selection and evaluation; formal logic; formal methods; formal specification; programming languages; semantics; software engineering; specifications; verificatio

    On the cloud deployment of a session abstraction for service/data aggregation

    Get PDF
    Dissertação para obtenção do Grau de Mestre em Engenharia InformáticaThe global cyber-infrastructure comprehends a growing number of resources, spanning over several abstraction layers. These resources, which can include wireless sensor devices or mobile networks, share common requirements such as richer inter-connection capabilities and increasing data consumption demands. Additionally, the service model is now widely spread, supporting the development and execution of distributed applications. In this context, new challenges are emerging around the “big data” topic. These challenges include service access optimizations, such as data-access context sharing, more efficient data filtering/ aggregation mechanisms, and adaptable service access models that can respond to context changes. The service access characteristics can be aggregated to capture specific interaction models. Moreover, ubiquitous service access is a growing requirement, particularly regarding mobile clients such as tablets and smartphones. The Session concept aggregates the service access characteristics, creating specific interaction models, which can then be re-used in similar contexts. Existing Session abstraction implementations also allow dynamic reconfigurations of these interaction models, so that the model can adapt to context changes, based on service, client or underlying communication medium variables. Cloud computing on the other hand, provides ubiquitous access, along with large data persistence and processing services. This thesis proposes a Session abstraction implementation, deployed on a Cloud platform, in the form of a middleware. This middleware captures rich/dynamic interaction models between users with similar interests, and provides a generic mechanism for interacting with datasources based on multiple protocols. Such an abstraction contextualizes service/users interactions, can be reused by other users in similar contexts. This Session implementation also permits data persistence by saving all data in transit in a Cloud-based repository, The aforementioned middleware delivers richer datasource-access interaction models, dynamic reconfigurations, and allows the integration of heterogenous datasources. The solution also provides ubiquitous access, allowing client connections from standard Web browsers or Android based mobile devices

    Automated Testing of Software Upgrades for Android Systems

    Get PDF
    Apps’ pervasive role in our society motivates researchers to develop automated techniques ensuring dependability through testing. However, although App updates are frequent and software engineers would like to prioritize the testing of updated features, automated testing techniques verify entire Apps and thus waste resources. Further, most testing techniques can detect only crashing failures, necessitating visual inspection of outputs to detect functional failures, which is a costly task. Despite efforts to automatically derive oracles for functional failures, the effectiveness of existing approaches is limited. Therefore, instead of automating human tasks, it seems preferable to minimize what should be visually inspected by engineers. To address the problems above, in this dissertation, we propose approaches to maximize testing effectiveness while containing test execution time and human effort. First, we present ATUA (Automated Testing of Updates for Apps), a model-based approach that synthesizes App models with static analysis, integrates a dynamically refined state abstraction function, and combines complementary testing strategies, thus enabling ATUA to generate a small set of inputs that exercise only the code affected by updates. A large empirical evaluation conducted with 72 App versions belonging to nine popular Android Apps has shown that ATUA is more effective and less effort-intensive than state-of-the-art approaches when testing App updates. Second, we present CALM (Continuous Adaptation of Learned Models), an automated App testing approach that efficiently tests App updates by adapting App models learned when automatically testing previous App versions. CALM minimizes the number of App screens to be visualized by software testers while maximizing the percentage of updated methods and instructions exercised. Our empirical evaluation shows that CALM exercises a significantly higher proportion of updated methods and instructions than baselines for the same maximum number of App screens to be visually inspected. Further, in common update scenarios, where only a small fraction of methods are updated, CALM is even quicker to outperform all competing approaches more significantly. Finally, we minimize test oracle cost by defining strategies for selecting, for visual inspection, a subset of the App outputs. We assessed 26 strategies, relying on either code coverage or action effect, on Apps affected by functional faults confirmed by their developers. Our empirical evaluation has shown that our strategies have the potential to enable the identification of a large proportion of faults. By combining code coverage with action effect, it is possible to reduce oracle cost by about 41.2% while enabling engineers to detect all the faults exercised by test automation approaches

    Load Testing of Vaadin Flow applications

    Get PDF
    All types of businesses, from small start-ups to big enterprises, have an online presence. Their web pages and applications can be used to acquire products ans services and are thus expected to be efficient. Yet, the web environment imposes additional requirements on software, such as the need for reliable security and adequate response times. To ensure these requirements are met and the product is of the expected quality, various types of testing are utilized during development. This master’s thesis evaluates a procedure for verifying a non-functional requirement of a web application – its performance. It focuses on load testing, which is used to analyze and assess an application’s behavior with different user loads. The scope of applications is limited to server-side applications that are developed with the latest long-term support version of the Vaadin framework. The effects of the performance arising from the server-side architecture of the framework and the Java ecosystem are reviewed. Furthermore, an overview of available improvement techniques, such as cache and load balancers, is given. From a load testing perspective, the biggest challenges that arise from Vaadin’s architecture are its unique features. These include node values of user interface components, synchronization and Cross-Site Request Forgery protection tokens. The defined universal regular expressions that capture these attributes can be used again later. The main contribution of this thesis is formulating a ready-to-use method of load testing a Vaadin Flow application. Once established and analyzed, the method is then applied to a real-life situation to verify its applicability and usefulness. Two widely used load testing tools are utilized – JMeter and Gatling. Furthermore, a method to estimate a web application’s session size is presented. Potential bottlenecks and other potential issues are identified by using a profiled to track the application’s memory consumption during a test run. After the load test is finalized and completed, a session size estimation is conducted. As a result of test execution, a potential bottleneck is identified and fixed in the application. Complete test plans for both JMeter and Gatling are defined and implemented. Alternatives and possible improvements to the proposed solution are reviewed. Based on the literature review, when deploying an application on multiple servers, the best solution is enabling the sticky sessions feature
    corecore