Mak Ing VPN Client Modules Platform Independent

You might also like

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 56

Mak ing VPN client modules platform independent

Table of Contents
(I).Title.I
(II).CertificateII (III).Acknowledgment.III (IV).AbstractIV 1. Problem Definition..1 2. Literature Survey.2 3.Software Requirement Specification 7.Bibilography...36 8. Assignments...38

Figure List
1. Dataflow Diagram .14 2. Class Diagram15 3. Transition Diagram16 4. Components in ACE..18 5. Class categories in ACE.21 6. SAP class category relationships...23 7. Use Case Diagram......24 8. Advanced Class Diagram...24 9. Activity Diagram...25 10. Component Diagram..26 11. Deployment Diagram27

Ma king VPN client modules Platform Independent

CERTIFICATE
ARMY INSTITUTE OF TECHNOLOGY DEPARTMENT OF COMPUTER ENGINEERING

This is to certify that the project report entitled MAKING VPN MODULES PLATFORM INDEPENDENT has been successfully completed by Arushi Singh,Kavita Upadhyay,Tanvi Agarwal and Sunita Yadav under my guidance in partial fulfillment of the degree of Bachelor of Engineering in Computer Engineering of University of Pune,Maharashtra during the academic year 2011-2012. To the best of my knowledge and belief this work has not been submitted elsewhere for the award of any other degree.The students have followed all the standards throughout the project.

Guide

Head of Department

Examiner

Head of the Department

Mrs. Rushali Patil

Prof. S.R Dhore

ACKNOWLEDGEMENT

We would like to thank in the preparation of seminar report.

my project guide Mrs. Rushali Patil for

keeping up our moral all the time. We are also grateful to her for proper guidance We are also grateful to the people who directly or indirectly helped in

preparation of the report and provided us with resources.

ARUSHI SINGH KAVITA UPADHYAY SUNITA YADAV TANVI AGARWAL

ABSTRACT
The demand for robust and high-performance distributed computing systems is steadily increasing. Examples of these types of systems include global personal communication systems, network management platforms, enterprise medical imaging systems, online nancial analysis

systems, and realtime avionics systems. Distributed computing is a promising technology for improving collaboration through connectivity and interworking; performance through parallel processing; reliability and availability through replication; scalability and portability through modularity; extensibility through dynamic conguration and reconguration; and cost effectiveness through resource sharing and open systems. Although distributed computing offers many potentially benets, developing communication software is expensive and error-prone. Object-oriented (OO) programming languages, components, and frameworks are widely touted technologies for reducing software cost and improving software quality. ACE is a freely available, open-source object-oriented framework that implements many core design patterns for concurrent communication software. ACE provides reusable C++ wrappers, frameworks and real-time ORB available for most operating systems. ACE is targeted for developers of high-performance and real-time communication services and applications. ACE simplifies the development of OO network applications and services that utilize inter-process communication, event demultiplexing, explicit dynamic linking, and concurrency. Some benefits of using ACE include: increased portability, increased software quality, increased efficiency and predictability and easier transition to standard higher-level middleware. The ACE Frameworks support the efficient, robust, and flexible development and configuration of concurrent networked applications and services. ACE provides a standardized usage for operating system/machine specific features. It provides common data types and methods to access the powerful but complex features of modern operating systems. These include: inter-process communication, thread management, efficient memory management, etc. It was designed to be portable and provides a common framework. The same code will work on most Unixes, Microsoft Windows, VxWorks, QNX, OpenVMS etc, with minimal changes. Due to this cross-platform support, it has been widely used in the development of communication software. Some of the successful projects that have used ACE includes: Motorola Iridium satellites, Boeing Wedgetail's Australian airborne early warning & control (AEW&C) system, and others.

Page 1

1.PROBLEM DEFINITON:
AIM: Making Propalms VPN client modules platform independent using the ACE library. ACE is a framework built in C/C++ that provides a unified interface for C/C++ developers to build programs that can be compiled on various platforms without requiring any changes in the core application. Propalms VPN is a secure remote access product from Propalms Network. Many of the Propalms VPN modules are developed in C/C++ which are specific to Windows. These programs use Windows OS API to perform tasks on the PCs. Customers of Propalms products may run other OS like MAC OSX and Linux. Propalms Network wants to port these Windows modules to Linux and MAC OSX without rewriting them for Linux and MAC OSX. This project aims to redevelop the windows modules using ACE library such that the same program can be then compiled for Linux and MACOSX with Propalms developer needing to learn Linux and MACOSX specific API.

2.LITERATURE SURVEY:

Page 1

The various background tasks involved are: 1)Understanding the existing system:
We took a brief survey of what VPN is and how the gateway is installed on the machine. Then we analyzed how the client logs in and transfers files

2)Analyzing the drawbacks:


We then analyzed that the VPN gateway needs to be redeveloped for different operating systems. This increases the overhead of time and efforts

3)Understanding ACE:
Then we understood on what ACE is and how it can help to implement abstraction of operating systems. We then understood its functionalities and system calls

4)Using ACE for this system:


Then after comparing performance of system with ACE to that without ACE,we came to conclusion that ACE is a better method for this approach.

CONCLUSION:
After understanding all the aspects, we came to conclusion that this can be an interesting project to implement

3. Software Requirement Specifications


3.1.Introduction 3.1.1Purpose
This project will aim to create a virtual private network gateway that is platform independent and need not be redeveloped when used in different platforms. This VPN gateway should be compatible with Windows,Linux and MaC OS.

Page 2

Virtual Private network is a secure and authenticated network that uses public infrastructure for setting up network .It can be used in an organization where people use different operating system with different platforms. All the people need not have same operating system. This can minimize cost of using leased lines.

3.1.2.Document Conventions
The terms in bold represent terms that are of significance to the project. The statements highlighted represent significant statements.

3.1.3Intended Audience and Reading Suggestion


The various intended audience are : The project group itself The faculty The sponsoring company

It is suggested to start with system features then proceed with requirements of system.

3.1.4Project Scope
The idea is to connect the employees of an organization that work at distant locations.

Page 1

It can be used in multi-national companies, Government offices, banking sector, technical organizations and various other such organizations. As there is no need to reconfigure it every time for a new operating system, the task is simplified more. The users can use the same gateway irrespective of the platform they are using . This will reduce time and effort in redeveloping the system. As new operating systems are emerging, the need to redevelop the library will be eliminated. This will simplify the task of all organizations to a greater extent.

3.1.5References
The references are: www.cs.schmildt.ace.com This is a web site where the object oriented framework called ACE(adaptive communication environment) is found. It contains the documentation, wrapper functions and other details www.en.wikipedia.virtual-private-networks. It is a website to understand virtual private networks in detail.

Page 1

3.2.Overall Description
3.2.1Product Perspective
Certain libraries already exist for configuration in windows. But such libraries need to be redeveloped for other OS. This adds to effort of user and developer.

3.2.2Product Features 1. No need to configure the system or software for other OS.
2. No need to install libraries each time 3. The modules are reusable 4. No concern to the operating system used 5. Upgradable to the advanced operating systems 6. Helpful in distributed networks 7. Helpful to employees working at different separated places

3.2.3.User Classes and Characteristics


The users can be classified as: 1. Novice users These users do not have an idea on how actually network is set up. They just want a software that is compatible with all operating systems . 2. Users with basic computer knowledge These users have detailed insight on how network operates. These users have a basic idea on how network operates. 3. Professional developers They can modify the network as per the needs.

Page 2

3.2.4Operating Environment
The gateway will be compatible with:

1. Windows all versions

2. Linux

3. MacOS

3.2.5.Design and Implementation Constraints


The various constraints may be:

Limited hardware drive space

Firewall

Threatening of security by hacking

Reduction in processing time

Limited access to data.

Page 1

3.2.6.User Documentation
The user needs to run the exe file and click on next and then install it on the desktop.The system thus checks if all the requirements specified are present and launches the application.

3.2.7.Assumptions and Dependencies


The various assumptions are: 1. Compatibility of dll files

2. Successful system calls 3. Error handling

4. System recovery 5. Networking drivers present and enabled The various dependencies are: 1. Already a dll file exists for this purpose, the source code depends on existing system.

2. Dependency on the space requirements.

3.3System Features
3.3.1System Feature 1
3.1.1 Description and Priority No need to redevelop the modules of VPN gateway Highest priority

3.1.2 Stimulus/Response Sequences

Page 2

User downloads the exe file User installs the gateway 3.1.3 Functional Requirements Friendly Graphical user interface Same installation steps for all operating systems

3.3.2. System Feature 2


.1 Description and Priority Quick response time Normal priority .2 Stimulus/Response Sequences User runs a number of programs at same time .3 Functional Requirements Given priority as compared to other tasks Low CPU processing time

3.4External Interface Requirements


3.4.1User Interfaces
Log in page Session details page Session disconnect page Installation page

Page 2

Data exchange page Session restoration page

3.4.2Hardware Interfaces
Application running hardware Networking drivers present

3.4.3Software Interfaces Interface to connect to destination Interface to notify status Interface to provide options to disconnect Interface on data rate Interface on bandwidth used Interface to simplify installation 3.4.4 Communications Interfaces Machines connected IP address entries Session details Session logon

Page 2

Session disconnect Session restoration Session data transfer

3.5.Other Nonfunctional Requirements


3.5.1Performance Requirements
Reduced CPU processing time Multi VPNs can be open at the same time VPN connection renewal Quick response time and throughput Optimal effect on other processes Less installation efforts

3.5.2.Safety Requirement
If data loss occurs, some cache should be there to store and review check points. Error handling

Page 2

Invalid system calls leads to system crash..So appropriate mechanism to handle such errors must be defined.

3.5.3Security Requirements
Using Firewalls to restrict invalid data manipulation Private key encryption to be used Use of appropriate cryptography algorithms Secured data transfer IP address validation Detecting proxy

3.5.4.Software Quality Attributes


The software should be: Reliable: Able to handle unwanted interrupts Robust: Able to work under all situations Secure No data theft or hacking Safe It should not harm the machine on which it is installed in any way.

Page 1

3.6 Other Requirements


Networking drivers Network sharing(secure)enabled on server side Appropirate data recovery Backup of critical data Reuse Objectives for the Project:

ACE is targeted for developers of high-performance and real-time communication services and applications. It simplifies the development of OO network applications and services that utilize interprocess communication, event demultiplexing, explicit dynamic linking, and concurrency. In addition, ACE automates system configuration and reconfiguration by dynamically linking services into applications at run-time and executing these services in one or more processes or threads. You dont have to code several program for one purpose only .The same program coded with ACE will be used on several operating systems. ACE is carefully designed to support a wide range of application quality of service (QoS) requirements, including low latency for delay-sensitive applications, high performance for bandwidth-intensive applications, and predictability for real-time applications. ACE provides a standard library of distributed services that are packaged as self-contained components. Although these service components are not strictly part of the ACE framework library, these service components play two roles in ACE:

1. Factoring out reusable distributed application building blocks -- These service


components provide reusable implementations of common distributed application tasks such as naming, event routing, logging, time synchronization, and network locking.

2. Demonstrating common use-cases of ACE components -- The distributed services also


demonstrate how ACE components like Reactors, Service Configurators, Acceptors and

Page 2

Connectors, Active Objects, and IPC wrappers can be used effectively to develop flexible, efficient, and reliable communication software. 3. The reusable facades can be very effective for development for use cases.

Page 2

Page 3

Page 4

3.8.SYSTEM IMPLEMENTATION PLAN:


1) Mastering ACE framework: The first step is to get used to ACE framework. It has lot of classes for the OS objects like threads, memory management, InterProcess Communications (semaphore, events, pipes), file handling etc.These classes implement various functions that support system calls.These call provide an abstraction from operating systems end. 2) Studying Existing System Then the next step is to study the VPN modules which are written in Windows. Then one needs to setup the development environment on windows for those modules.This will include: i)Analyzing error handling functions ii)Analyzing how to handle system calls

3) Getting into detail of each function Then we will take each function and understand its functionality. We will then write your own test program which will call that function with different parameters, and this program will record the output of the function on windows. 4) Testing on Windows:

Page 1

Next we will rewrite that function using ACE library and test it on windows using your test program that you created 5) Testing on Linux: Next step is to compile the same code on linux and make sure it works on linux. 6) Integration of all functions This way all the code will be converted by integrating all functions.

4.SYSTEM DESIGN AND ARCHITECTURE:


4. 1 SYSTEM ARCHITECTURE: The ADAPTIVE Communication Environment (ACE) is an object-oriented (OO) toolkit that implements fundamental design patterns for communication software. ACE is targeted for developers of high-performance communication services and applications on UNIX and Win32 platforms.ACE simplifies the development of OO network applications and services that utilize inter process communication, event demultiplexing, explicit dynamic linking, and concurrency.ACE automates system configuration and reconfiguration by dynamically linking services into applications at run-time and executing these services in one or more processes or threads.

Page 1

FIGURE 4

Overview of the ADAPTIVE Communication Environment (ACE)


To illustrate how OO patterns and frameworks are being successfully applied to distributed software, this paper examines the ADAPTIVE Communication Environment (ACE) . ACE is a freely available OO toolkit containing a rich set of reusable wrappers, class categories, and frameworks that perform common network programming tasks across a wide range of OS platforms. The tasks provided by ACE include: _Event demultiplexing and event handler dispatching

Connection establishment and service initialization. Interprocess communication and shared memory management Dynamic configuration of distributed communication services ;
Concurrency/parallelism and synchronization Components for higher-level distributed services

Page 2

The ACE toolkit is designed using a layered architecture. Figure

illustrates the vertical and

horizontal relationship between ACE components. The lower layers of ACE are OO wrappers that encapsulate existing OS network programming mechanisms. The higher layers of ACE extend the wrappers to provide OO frameworks and components that cover a broader range of applicationoriented networking tasks and services. The remainder of this section presents an overview of the structure and functionality of the class categories in ACE.

The ACE OS Adaptation Layer


The ACE source tree contains over 85,000 lines of C++.Approximately 9,000 lines of code (i.e., about 10% of the total toolkit) are devoted to the OS Adaptation Layer. This layer shields the higher layers of ACE from platform-specific dependencies associated with the following OS mechanisms: _Multi-threading and synchronization Inter process communication _Event demultiplexing Explicit dynamic linking _Memory-mapped files and shared memory.

The ACE OO Wrappers


Above the OS Adaptation Layer are OO wrappers that encapsulate and enhance the concurrency, inter process communication (IPC), and virtual memory mechanisms available on modern compose these operating systems like Win32 and UNIX. Applications can combine and class categories:

components by selectively inheriting, aggregating, and/or instantiating the following ACE wrapper

_IPC SAP which encapsulates local and/or remote IPC Service Access Point (IPC SAP
mechanisms such as sockets, TLI, UNIX FIFOs and STREAM pipes, and Win32 Named Pipes.

Service Initialization ACE provides a set of Connector and Acceptor components [18]
that decouple the active and passive initializationroles, respectively, from the tasks a communication service performs once initialization is complete.

Concurrencymechanisms ACE abstracts lower-levelOS multi-threading and multiprocessing mechanisms (such as mutexes and semaphores ) to create higherlevel OO concurrency abstractions (such as Active Object).

Memory management mechanisms the ACE memory management components provide


a flexible and extensible abstraction for managing dynamic allocation

Page 2

and deallocation of shared memory and local memory;

f_IFI

FIGURE 5 CORBA integration ACE can be integrated with CORBA implementations (such as singlethreaded and multi-threaded Orbix). The use of OO wrappers improves application robustness by encapsulating OS communication, concurrency, and virtual memory mechanisms with type-secure OO interfaces. This alleviates the need for applications to directly access the underlying OS libraries, which are written using weakly typed C interfaces. Therefore, compilers for OO languages like C++ and Java can detect type system violations at compile-time, rather than at run-time. The C++ version of ACE uses inlining extensively to eliminate performance penalties that would otherwise be incurred from the additional type-security and abstraction provided by the wrapper layer.

The ACE Framework

Page 2

ACE contains a higher layer network programming framework that integrates and enhances the lower layer OS wrappers. This framework supports the dynamic configuration of concurrent network daemons composed of application services. The framework portionof ACE contains the following class categories:

Reactor The ACE Reactor provides extensible, object-oriented demultiplexer that


dispatches handlers in response to various types of events (e.g., I/O-based, timer-based, signal-based, and synchronization-basedevents);

_Service Configurator The ACE Service Configurator supports the construction of


applications whose services may be configured dynamically at installationtime and/or runtime.

Streams
_

The ACE Streams components

simplify the development of concurrent

communication software applications composed of one or more hierarchically related services (such as protocol stacks); ACE Network Service Components In addition to the wrappers and frameworks, ACE provides a standard library of network service components. These components play two roles in ACE: 1. They illustrate how to utilize the ACE IPC wrappers, Reactor, Service Configurator, Service Initialization, Concurrency, Memory Management, and Streams components; 2. They provide reusable components for common distributed system tasks such as Logging

Naming, Locking, and


Time synchronization

Page 1

FIGURE 6

4. 2 UML DIAGRAMS:

Page 2

1) USE CASE DIAGRAM

FIGURE 7

2) ADVANCED CLASS DIAGRAM

FIGURE 8

Page 2

3) ACTIVITY DIAGRAM

FIGURE 9

Page 2

4)COMPONENT DIAGRAM:

FIGURE 10

Page 2

5) DEPLOYMENT DIAGRAM:

Page 3

FIGURE 11

Page 2

5. TECHNICAL SPECIFICATION 5.1 ADVANTAGE:The ADAPTIVE Communication Environment (ACE) is a freely available, open-source objectoriented framework that implements many core patterns for concurrent communication software. ACE provides a rich set of reusable C++ wrapper facades and framework components that perform common communication software tasks across a range of OS platforms. The ACE tools ease the implementation of your solution with the following: Event demultiplexing and event handler dispatching Signal handling Service initialization Interprocess communication Shared memory management Message routing Dynamic (re)configuration of distributed services Concurrent execution and synchronization

Why ACE? Increased portability of application code across operating systems and development
environments.

Increased software quality due to use of key patterns that increase key qualities, such as
flexibility, extensibility, reusability, and modularity, of communication software.

Increased efficiency and predictability due to support for a wide range of application quality
of service (QoS) requirements, including low latency, high performance, and predictability.

Easier transition to standard higher-level middleware such as The ACE ORB (TAO), which
is built on ACE.

Page 1

If you have to support multiple platforms and deal with networking and multithreading the
ACE library is probably the way to go or at least a reasonably safe bet.

5.2 DISADVANTAGE: Sometimes descriptions of functions , return values and parameters are missing. So you have
to dig in the source code after all. In some areas the library is weak. Especially the container classes (including the ACE string classes) are nowhere near the container classes of the standard library; they are inconsistent, often incomplete and the awkward iterators don't mix well (if at all) with standard library algorithms.

Also the fact that ACE targets so many platforms has a downside. It means the developers
had to consider for the lowest common denominator of C++ features supported by all compilers. This didn't help to make the code elegant. Also the excessive use of macro's can make debugging problems inside the ACE library (sometimes you have to, unfortunately) a real pain.

While using the programs which are embedded with ACE ,the user will not have the
knowledge of all the operating systems.

Ace creates an intermediate stage which decreases the systems speed.

5.3 APPLICATIONS:i)It facilitates portability ii)It does not provide a Virtual Machine. iii)It makes the program platform independent. IV)Decreases the overhead of redevelopment V)Minimises Response time.

Page 2

6.Appendix:
Glossary: Virtual Private Network:
It refers to a network that uses the public network infrastructure for private networks. It is a secure authenticated network.

ACE:
The Adaptive Communication Environment (ACE) is a freely available, open-source objectoriented (OO) framework that implements many core patterns for concurrent communication software. ACE provides a rich set of reusable C++ wrapper facades and framework components that perform common communication software tasks across a range of OS platforms. The communication software tasks provided by ACE include event demultiplexing and event handler dispatching, signal handling, service initialization, interprocess communication, shared memory management, message routing, dynamic (re)configuration of distributed services, concurrent execution and synchronization.

Cryptography:
Cryptography is the practice and study of techniques for secure communication in the presence of third parties . It is about constructing and analyzing protocols that overcome the influence of adversaries and which are related to various aspects in information security such as data confidentiality, data integrity and authentication. Modern cryptography intersects the disciplines of mathematics, computer science, and electrical engineering.

Wrapper Faade:
The facade pattern is a software engineering design pattern commonly used with object oriented programming.The name is by analogy to an architectural faade. A facade is an object that provides a simplified interface to a larger body of code, such as a class library. A facade can:

Page 1

make a software library easier to use, understand and test, since the facade has convenient
methods for common tasks; make code that uses the library more readable, for the same reason; reduce dependencies of outside code on the inner workings of a library, since most code uses the facade, thus allowing more flexibility in developing the system; wrap a poorly-designed collection of APIs with a single well-designed API (as per task needs). An Adapter is used when the wrapper must respect a particular interface and must support a polymorphic behavior.

DYNAMIC LINK LIBRARIES (DLL):


Dynamic-link library or DLL, is Microsoft's implementation of the shared library concept in the Microsoft Windows and OS/2 operating systems. These libraries usually have the file extension DLL, OCX (for libraries containing ActiveX controls), or DRV (for legacy system drivers). The file formats for DLLs are the same as for Windows EXE files that is, Portable Executable (PE) for 32-bit and 64-bitWindows, and New Executable (NE) for 16-bit Windows. As with EXEs, DLLs can contain code, data, and resources, in any combination. In the broader sense of the term, any data file with the same file format can be called a resource DLL. Examples of such DLLs include icon libraries, sometimes having the extension ICL, and font files, having the extensions FON and FOT.

IPC(INTERPROCESS COMMUNCATION):
In computing, Inter-process communication (IPC) is a set of methods for the exchange of data among multiple threads in one or more processes. Processes may be running on one or more computers connected by a network. IPC methods are divided into methods for message passing, synchronization, shared memory and remote procedure calls (RPC). The method of IPC used may vary based on the bandwidth and latency of communication between the threads, and the type of data being communicated. There are several reasons for providing an environment that allows process cooperation:

Page 1

Information sharing Speedup Modularity Convenience

Privilege separation
IPC may also be referred to as inter-thread communication and inter-application communication. The combination of IPC with the address space concept is the foundation for address space independence/isolation.

VPN GATEWAY:
A VPN gateway (VPN router) is a connection point that connects two LANs that a nonsecure network such as the Internet connects. Therefore, a VPN gateway connects to either a single VPN gateway or to multiple VPN gateways to extend the LAN. This scenario is typically referred to as a router-to-router VPN. The corporate networks are connected through the VPN servers running Routing And Remote Access Service (RRAS). The actual medium that connects the LANs is usually the Internet. This means that the VPN gateway or router will be configured with the address on the LAN that it is connected to and a public IP address.

CPU(CENTRAL PROCESSING ENVIRONMENT): The central processing unit (CPU) is the portion of a computer system that carries out the instructions of a computer program, to perform the basic arithmetical, logical, and input/output operations of the system. The CPU plays a role somewhat analogous to the brain in the computer. The term has been in use in the computer industry at least since the early 1960s.The form, design and implementation of CPUs have changed dramatically since the earliest examples, but their fundamental operation remains much the same.

Page 1

TAO(THE ACE ORB):


The ACE ORB (TAO - The Ace Orb) is a freely available, open-source, and standards-compliant real-time C++ implementation of CORBA based upon the Adaptive Communication Environment(ACE). It attempts to provide efficient, predictable, and scalable quality of service (QoS) end-to-end. TAO applies the best software practices and patterns to automate the delivery of high-performance and real-time QoS to distributed applications. TAO is for developers of distributed and embedded applications who have stringent performance demands. TAO brings familiar concepts from elsewhere in the software industry to real-time systems. These concepts include CORBA, RPC, an OO presentation, and Berkeley-sockets. In OO, RPC is usually termed remote method invocation (RMI), because subroutines or procedures that are directly associated with objects or classes are termed methods, but the concept is fundamentally the same in that the caller at the origin is suspended while the method at the destination object executes. This provides a simplicity of execution of software that can be desirable when subroutine is the idiom that is intended in the design or architecture.

OS(OPERATING SYTEM):
An operating system (OS) is a set of programs that manage computer hardware resources and provide common services for application software. The operating system is the most important type of system software in a computer system. A user cannot run an application program on the computer without an operating system, unless the application program is self booting. Time-sharing operating systems schedule tasks for efficient use of the system and may also include accounting for cost allocation of processor time, mass storage, printing, and other resources. For hardware functions such as input and output and memory allocation, the operating system acts as an intermediary between application programs and the computer hardware,although the application code is usually executed directly by the hardware and will frequently call the OS or be interrupted by it. Operating systems are found on almost any device that contains a computer from cellular phones and video game consoles to web servers.

Page 2

Appendix B: Drawbacks

1) Reduced CPU speed 2) Reduced response time for other processes 3) A little modification can lead to system crash 4) Data loss 5) As public network,critical data may be probe to theft

Page 3

Appendix C: Issues List

1)Incompatibility with all features 2)System crash 3)Hardware interrupts 4)Delay

7.BIBILOGRAPHY:

Page 2

idt, etc. ADAPTIVE Communication Environment Technical Documentation [M]. 2002. http://www.cs.wustl.edu/~schmidt/ACE.html [2] D. C. Schmidt, T. H. Harrison, and E. Al-Shaer, Object-Oriented Components for High-speed Network Programming, in Proceedings of the 1st Conference on Object-Oriented Technologies and Systems, (Monterey, CA), USENIX, June 1995. [3] D. C. Schmidt, IPC SAP: An Object-Oriented Interface to Interprocess Communication Services, C++ Report, vol. 4, November/December 1992. [4] D. C. Schmidt, The Reactor: An Object-Oriented Interface for Event-Driven UNIX I/O Multiplexing (Part 1 of 2), C++ Report, vol. 5, February 1993. [5] D. C. Schmidt, The Object-Oriented Design and Implementation of the Reactor: A C++ Wrapper for UNIX I/O Multiplexing (Part 2 of 2), C++ Report, vol. 5, September 1993. [6] T. H. Harrison, D. C. Schmidt, and I. Pyarali, Asynchronous Completion Token: an Object Behavioral Pattern for Efficient Asynchronous Event Handling, in The 3rd Annual Conference on the Pattern Languagesof Programs (Washington University technical report#WUCS-97-07), (Monticello, Illinois), pp. 17, February 1997. [7] D. C. Schmidt, An OO Encapsulation of Lightweight OS Concurrency Mechanisms in the ACE Toolkit, Tech. Rep. WUCS-95-31, Washington University, St. Louis, September 1995. [8] D. C. Schmidt and C. D. Cranor, Half-Sync/Half-Async: an Architectural Pattern for Efficient and Well-structured Concurrent I/O, in Pattern Languages of Program Design (J. O. Coplien, J. Vlissides, and N. Kerth, eds.), Reading, MA: Addison-Wesley, 1996. [9] D. C. Schmidt and T. Harrison, Double-Checked Locking An Object Behavioral Pattern for Initializing and Accessing Thread-safe Objects Efficiently, in The 3rd Pattern Languages of Programming 1997. [10] D. C. Schmidt and T. Suda, An Object-Oriented Framework for Dynamically Configuring Extensible Distributed Communication Journal (Special Systems, IEE/BCS Distributed Systems Engineering Conference (Washington University technical report #WUCS-97-07), February

Page 2

Issue on Configurable Distributed Systems), vol. 2, pp. 280293, December 1994. [11] P. Jain and D. C. Schmidt, Service Configurator: APattern for Dynamic Configuration and Reconfiguration of Communication Services, in The 3rd Pattern Languagesof Programming Conference (Washington University technical report #WUCS-97- 07), February 1997. [12] R. Fielding,UC Irvine J. Gettys etc. Hypertext Transfer Protocol -- HTTP/1.1[M]. Network Working GroupRequest for Comments: 2616, 1999 [13] R.Rivest. RFC 1321 - The MD5 Message-Digest Algorithm[M]. MIT Computer Science and RSA Data Security Inc. April 1992 Laboratory for

ASSIGNMENT 1:
COMPLEXITY

Page 2

Consider a program of file operation in turbo c, for example take opening of file:The parameters/arguments of the fopen() function is different in different operating system. The syntax which is in windows is different from the syntax in Linux or MAC. If you have made the program in windows, and trying to run the same program in linux or MAC ,then it will give you some errors related to the fopen() function. The same program cannot run on all the operating systems. You have to make 3 different programs. Suppose there are N no. of operating systems so you have to make N no. of programs .

Windows Let there be N no of OS es

Linux

MAC

Program 1 program N

Program 2

Program 3

CALCULATING THE COMPLEXITY:NO. of programs =N

=N Complexity =N Hence the complexity comes out to be N which is large .The programs which we made earlier was not platform independent ,thats why they were not running on all the operating systems.

Page 2

What we can do to reduce the complexity? Make the program platform independent. This can be done by using intermediate software. ACE (adaptive communication environment) is a freely available, open-source object-oriented framework that implements many core design patterns for concurrent communication software. ACE provides reusable C++ wrappers, frameworks and real-time ORB available for most operating systems. It performs common communication software tasks across a range of operating system platforms. ACE is targeted for developers of high-performance and real-time communication services and applications.

Program program

ACE wrappers

Final

Windows N no. of OS

Linux

MAC

Final program which will run on all the OS NO. of programs =1 Complexity = 1 SEARCHING ALGORITHMS
Thus the complexity has reduced to 1. Therefore by using ACE the program has become platform independent. So there is no need to write the same code in different Operating Systems

Page 2

We have the final program which consists of the program coded in ace using the wrappers .When you will execute/run this program on different OS ,it will check for what type of OS is there and accordingly run. For this there will be a table in which arguments/parameters will be present of the respective OSes.

ASSIGNMENT 2: SEARCHING ALGORITHMS


If you are running a program in windows then it will search for the windows in the table. Here the searching algorithm will be used.

Page 1

TYPES OF SEARCHING ALGORITHM:1.) Linear 2.) Binary If linear search is used it will increase the complexity. For better complexity hashing technique should be used. Therefore entries in the table should be in hashing form. A hash function is any algorithm or subroutine that maps large data sets to smaller data sets, called keys. For example, a single integer can serve as an index to an array. The values returned by a hash function are called hash values, hash codes, hash sums, checksums or simply hashes. Hash functions are primarily used in hash tables, to quickly locate a data record given its search key (the headword). Specifically, the hash function is used to map the search key to the hash. The index gives the place where the corresponding record should be stored. Hash tables, in turn, are used to implement associative arrays only and dynamic sets. In general, a hashing function may map several different keys to the same index. Therefore, each slot of a hash table is associated with (implicitly or explicitly) a set of records, rather than a single record. For this reason, each slot of a hash table is often called a bucket, and hash values are also called bucket indices. Thus, the hash function only hints at the record's locationit tells where one should start looking for it. Still, in a half-full table, a good hash function will typically narrow the search down to only one or two entries. The hash function can use: 1)Multiplicative modular 2)Most frequent occuring

Page 1

Page 1

ASSIGNMENT 3: TRANSITION STATES:


1) Mastering ACE framework: The first step is to get used to ACE framework. It has lot of classes for the OS objects like threads, memory management, InterProcess Communications (semaphore, events, pipes), file handling etc.These classes implement various functions that support system calls.These call provide an abstraction from operating systems end. 2) Studying Existing System Then the next step is to study the VPN modules which are written in Windows. Then one needs to setup the development environment on windows for those modules.This will include: i)Analyzing error handling functions ii)Analyzing how to handle system calls

3) Getting into detail of each function Then we will take each function and understand its functionality. We will then write your own test program which will call that function with different parameters, and this program will record the output of the function on windows. 4) Testing on Windows: Next we will rewrite that function using ACE library and test it on windows using your test program that you created 5) Testing on Linux: Next step is to compile the same code on linux and make sure it works on linux.

6) Integration of all functions This way all the code will be converted by integrating all functions

Page 3

MASTERING ACE FRAMEWORK ,UNDERSTAND SYSTEM CALLS

STUDYING EXISTING SYTEM

GETTING INTO DETAIL OF FUNCTIONS

TESTING ON WINDOWS

TESTING ON LINUX

INTEGRATION OF ALL FUNCTIONS

CONVERSION OF DLL FILE:


A dynamic-link library (DLL) is a module that contains functions and data that can be used by another module (application or DLL).

Page 3

A DLL can define two kinds of functions: exported and internal. The exported functions are intended to be called by other modules, as well as from within the DLL where they are defined. Internal functions are typically intended to be called only from within the DLL where they are defined. Although a DLL can export data, its data is generally used only by its functions. However, there is nothing to prevent another module from reading or writing that address. DLLs provide a way to modularize applications so that their functionality can be updated and reused more easily. DLLs also help reduce memory overhead when several applications use the same functionality at the same time, because although each application receives its own copy of the DLL data, the applications share the DLL code. The Windows application programming interface (API) is implemented as a set of DLLs, so any process that uses the Windows API uses dynamic linking

DLL in Linux: Dynamic Linking in Linux: The ELF data structures:


As this is not an article specifically on the ELF format, only those data structures are discussed which are relevant. For dynamic linking, the ELF linker primarily uses two processor-specific tables, the Global Offset Table (GOT) and the Procedure Linkage Table (PLT).

Global offset Table (GOT)


ELF linkers support PIC Code through the GOT in each shared library. The GOT contains absolute addresses to all of the static data referenced in the program. The address of the GOT is normally stored in a register (EBX) which is a relative address from the code that references it.

Procedure Linkage Table (PLT)

Page 3

Both the executables that use the shared libraries and the shared library itself has a PLT. Similar to how the GOT redirects any position-independent address calculations to absolute locations, the PLT redirects position-independent function calls to absolute locations. Apart from these two tables, the linker also refers to .dynsym, which contains all of the file's imported and exported symbols, .dynstr, which contains name strings for the symbols, .hash which contains the hash table which the runtime linker can use to lookup symbols quickly, and .dynamic, which is a list of tagged values and pointers. In the .dynamic section, the important tag types are: DT_NEEDED: This element holds the string table offset of a null-terminated string, giving the name of a needed library. The offset is an index into the table recorded in the DT_STRTAB entry.

DT_HASH: This element holds the address of the symbol hash table which refers to the symbol table referenced by the DT_SYMTAB element. DT_STRTAB: This element holds the address of the string table. DT_SYMTAB: This element holds the address of the symbol table.

This DLL file contains: 1)Symbolic references 2)Definitions 3)Libraries that involve external references

Page 3

4)Various literal tables 5)Linking

Page 1

ASSIGNMENT 4: MATHEMATICAL MODEL:


1)No of users active at at a time=n; 2)No of users using connection=m; 3)No of programs by each users=t; 4)Complexity of given problem=O(t/m); 5)Probability of using VPN connection=m/n; 6)Since there is no need to redevelop it for another system, Complexity=O(t) Hence mathematically it can be shown that the new system has better performance than existing system

Page 1

ASSIGNMENT 5: FEASIBILITY ASSESSMENT:

P is the set of all decision problems solvable by deterministic algorithms in polynomial time.NP is the set of all decision problems solvable by non deterministic algorithms in polynomial time. The satisfiability theorem is to determine whether a formula is true for assignment of truth values to the variables. Satisfiability is in P if and only if P=NP. The definition implies that if we have a polynomial time algorithm for L2 then we can solve L1 in polynomial time.Since there exists a deterministic polynomial time for existing system we can conclude the problem statement can also be completed in P deterministic time as it is only a superset of the existing system. The halting problem is to determine for an arbitrary deterministic algorithm A and input I whether A ever terminates. This is undecidable for given problem statement.

You might also like