This essay has been submitted by a student. This is not an example of the work written by our professional essay writers.
Security is very important in data transmission between two devices communicating on a computer network. Encryption is used to secure data as it moves between the two communicating devices. The performance of encryption has been well documented for client-server applications but very little information is available for the mobile agent paradigm. This research work employs two mobile agent systems, Aglets and JADE, in encrypting, transferring and decrypting files from one host to another. Quantitative results comparing the performance of the two mobile agent systems in encrypted file transfer and retrieval is presented. The two mobile agent systems are closely related in performance with JADE giving a slightly better performance. Integrity checks were conducted on the files after transmission with both mobile agent systems retaining the same file sizes after transfer.
Mobile agent systems provide the execution environment for mobile agents (Chess et al, 1997). Several mobile agent systems have been developed in the course of research and these can be found at Gulyas et al (2000) and Gray et al (2001). According to Versteeg (1997) any language can be used to implement mobile agents provided the language is supported by an execution environment on the host. There are also many general purpose languages extended with a special library that can be used to write mobile agents such as Tcl, C, C++, Perl 5 and Python. Java, though not specifically designed for writing mobile agents, has been adopted because of its high portability and valuable characteristics. It has been used to implement mobile agent systems such as Aglets and JADE.
A mobile agent has the unique ability to transport or migrate itself from one system in a network to another in the same network. This ability allows it to move to a system containing an object with which it wants to interact and then to take advantage of being in the same host or network as the object (Lange and Oshima, 1998). Mobile agents are programs that migrate in a network in order to optimize their consumption of resources, such as network bandwidth.
Mobile agents offer many benefits that have been supported by quantitative and qualitative assessments. These benefits according to Chess et al (1997) are based on the capability of mobile agents to solve the client-server network bandwidth problem, reduce program design risk and solve problems created by intermittent or unreliable network connections. The identified benefits of mobile agents according to Lange and Oshima (1999) include network load reduction by processing data locally, they overcome network latency, they execute asynchronously and autonomously, they adapt dynamically, and they are robust and fault-tolerant. Mobile agents' ability to react dynamically to unfavorable situations and events makes it easier to build robust and fault-tolerant distributed systems. For this research work, mobile agents using the Aglet and JADE mobile agent system will be evaluated.
The Aglet Software Development Kit (ASDK) was developed by IBM's Tokyo Research Labs, and was one of the first and most publicized Java based mobile agent frameworks released (Lange & Oshima, 1998). An aglet is a mobile agent, consisting of two parts, the core and proxy. The core contains all of the aglet's internal data and logic. It has interfaces through which the aglet communicates with its environment. The proxy acts as a shield against any attempt to directly access any of the aglet's internal data or logic. A context is a stationary workplace that provides a uniform execution environment where the host system is secured against malicious aglets.
The Aglet Application Programming Interface (API) is used to create and operate aglets. It contains methods for initializing an aglet, message handling and dispatching, retracting, deactivating/activating, cloning and disposing of the aglet. The Aglet class is the key class in the Aglet API. This is the abstract class that the aglet developer uses as a base class to create customized aglets. The aglet class defines methods for controlling its own life cycle, namely, methods for cloning, dispatching, deactivating and disposing itself. It also defines methods that are supposed to be overridden in its subclasses by the aglet programmer and provides the necessary "hooks" to customize the behaviour of the aglet.
JADE is the middleware developed for the development of distributed multi-agent applications based on the peer-to-peer communication architecture (Bellifemine et al, 2001). JADE is an acronym for Java Agent DEvelopment Framework. JADE is fully developed in Java and is based on the following principles: interoperability, uniformity and portability, easy to use and the pay-as-you-go philosophy.
JADE includes both the libraries i.e. the Java classes, required to develop application agents and the run-time environment that provides the basic services and that must be active on the device before agents can be executed. Each instance of the JADE run-time is called container since it "contains" agents. The set of all containers is called platform and provides a homogeneous layer that hides the complexity and the diversity of the underlying layers of hardware, operating systems, types of network and Java Virtual Machine (JVM). JADE is extremely versatile and therefore, not only does it fit the constraints of environments with limited resources, but it has already been integrated into complex architectures such as .NET or J2EE where JADE becomes a service to execute multi-party proactive applications (Bellifemine et al, 2003).
JADE provides the basic services necessary for distributed peer-to- peer applications in the fixed and mobile environment (Bellifemine et al, 2003). JADE provides a set of skeletons of typical interaction patterns to perform specific tasks, such as negotiations, auctions and task delegation. By using these skeletons implemented as Java abstract classes, programmers can get rid of the burden of dealing with synchronization issues, timeouts, error conditions and aspects that are not strictly related to the application logic (Bellifemine et al, 2003).
Cryptography is necessary when communicating over any untrusted medium, which includes just about any network, particularly the Internet. Within the context of any application-to-application communication, there are some specific security requirements, including: Authentication, Privacy/confidentiality, Integrity, and Non-repudiation. There are, in general, three types of cryptographic schemes typically used to accomplish these goals: secret key (or symmetric) cryptography, public-key (or asymmetric) cryptography, and hash functions. In all cases, the plaintext is encrypted into cipher text, which will in turn be decrypted into usable plaintext (Kessler, 1998). In secret key or symmetric encryption a single key for both encryption and decryption is used. In public-key cryptography, two keys, public key for encryption and private key for decryption are used. Hash functions, use no key, instead a fixed-length hash value is computed based upon the plaintext that makes it impossible for either the contents or length of the plaintext to be recovered. In this work, a secret key is used.
This paper simulates and evaluates the performance of two mobile agents systems, Aglets and JADE, during encrypted file transfer and retrieval from hosts using encryption and decryption time, time to send and file integrity as parameters.
DEVELOPMENT OF PERFORMANCE EVALUATION ENVIRONMENT
This section presents the Java package for the mobile agent based file retrieval program. A package contains a collection of commonly related classes offering specific functions. The components of the package, classes, are shown in Figure1. The classes in the package with their respective methods that perform the functions of the classes are:
HostContainer: A container "contains" agents. This is the main class that hosts the mobile agent for Aglet and JADE with different containers for each mobile agent system. The methods in this class are:
private void initComponents
public void windowClosed
public void windowClosing
public void keyPressed
public void keyReleased
private void closeSocket
private void changeIP
private void configIPDialog
SelectFile: This class handles encryption and the search for the file through JADE. It also attaches and exports the file via the agent. The methods are:
public File locatefile
public void encryptAndProcessStream
public File getDirectory
AgletClient: This class handles encryption including exporting the key and file transfer through Aglet. The methods include:
public void exportKey
public void run
public void exportFile
SearchAglet: This class handles the file search for Aglets. The methods are:
public void onCreation
public boolean handleMessage
public void testFile
public void report
public String getIdentity
RecieverAgent: This class handles the receipt of the agent on the target system.
DecrypterAgent: This class handles the decryption of the file after transfer.
ResultsTableControls: This class handles results. Properties such as whether or not the values can be edited and data type of the values are set here. The methods in this class are:
public boolean isCellEditable
public Class getColumnClass
Figure 1: Class Diagram of the Package
A user friendly interface designed for the mobile agent systems has two major classes, ServerPlatform and ClientAgent. Figure 2 illustrates the relationships.
Contents Tab &
Figure 2: Interface design
ServerPlatform: This class handles the interface on the server side of the application. The ResultsTableRep handles the two tabs (Contents Tab and Results Tab) on the server interface. The contents Tab shows where the decrypted file was stored on the server system while the Results Tab show the amount of time it takes to encrypt, decrypt and transfer the file. This class also synchronizes time on both platforms
ClientAgent: This class loads a new Client panel form. This interface also handles the connection settings. That is, entering the IP address and Port number of the server system. It also has additional functions such as initialization of encryption engine and creating the test files. The methods below perform the functions:
private void createTestFiles
private void selectSearchDirectory
private void connectServer
private void InitEncryptEngine
private void EncryptStream
The application was run on a peer to peer network. The agents are migrated from the client with necessary cryptographic key to the system that runs the server. The cryptographic key was generated randomly and transferred to the execution environment. Both parties in communication had to be aware of the existence of this key in order to successfully encrypt and decrypt data. The encryption standard used was 64-bit DES. Ten dummy files, ranging from 100KB to 1MB, were created to test the application on the client system. A unique port number, 2007, was chosen for the loading of classes and mobility of agents because numbers below 1024 might already be running system programs.
The versions of Aglets and JADE used are 2.0.2 and 3.4.1 respectively. Developing a platform to accurately to test two different agent platforms was challenging hence the a hybrid agent platform was developed that successfully allows the code and classes of both JADE and Aglets to run while giving real time performance data about both agent systems. The graphical user interface (GUI) of the application was designed using Java Swing architecture.
RESULTS AND DISCUSSION
The implementation starts by running the ServerPlatform on a host from where all necessary agents are migrated as shown in Figure 3.
Figure 3: Port configuration of ServerPlatform
Figure 4: Connection Settings on ClientSide
Figure 4 shows the connection settings on client Side where the host IP address is entered. If properly configured, the ServerPlatform will indicate that it has accepted connection on the port.
Figure 5: Connection Settings on ClientSide
On the client side the file name (case sensitive) and extension is entered in the textbox as seen in Figure 5 and processed by clicking the "Process File" button. The results can be viewed on the server on the Results TAB and are shown in Fig 6. The Results TAB displays a comparison between Aglets and JADE. All values are in milliseconds and the file size is measured in bytes.
Observations from the results indicate that JADE generally gives better performance than Aglets in all test cases although the results were very close and that as the file size increases, the time taken to encrypt, decrypt and transfer the file increases.
The results can be viewed on the server through the Results tab. The Results tab displays a comparison between Aglets and JADE. Figure 6 below shows that there is a time difference of about 5ms between Aglets and JADE when encrypting the file with the latter giving a shorter turnaround time. In terms of decryption, the time gap is also about 5 ms with JADE still giving a better performance. From Figure 6, it can be observed that the time to send (TTS) also has a difference of 5ms with JADE delivering before Aglets.
Figure 6: Result for 100KB of file transfer
The results from running several tests were collated into three different tables. Table 1 is a comparison of Aglet and JADE in terms of the time it takes to encrypt each file from 100KB - 1MB.
Table 1: Time comparison between Aglet and JADE during encryption
ENCRYPTION TIME (ms)
Table 2: Comparison between Aglet and JADE during decryption
DECRYPTION TIME (ms)
Table 3: Comparison between Aglet and JADE during file transmission
TIME TO SEND (ms)
File Integrity and Usability
To evaluate the mobile agent systems in terms of file integrity, files containing pictures and video were used. The file sizes after transfer were checked and compared with the file size before transmission. The file sizes remained the same and were usable. A major issue however, was that the application used to open the file had to be selected. This means that the individual on the server side has to know what type of file has been transferred and what application to use. This was applicable to files sent on both mobile agent systems.
This work evaluates the performance of two mobile agent systems, Aglet and JADE, for encrypted file transfer in a computer network. The mobile agent systems were simulated using Java classes and the performance parameters selected were encryption time, decryption time and transfer time. The results showed that the two systems are closely related in performance when it comes to file transfer, encryption and decryption; hence there is no significant difference in terms of the selected parameters.
The slight difference in time could however be attributed to the following: all messages sent through JADE are carried out within an envelope. This allows the encryption of the message content separate from the envelope, which invariably reduces encryption time; all messages exchanged by JADE comply with FIPA specification and hence include only the information required by the transport layer unlike the Aglet that exchanges all data; JADE supports Skeletons that are implemented as abstract classes that rid programmers the burden of dealing with synchronization issues, timeouts and error conditions; and Aglet uses ATP for agent transfer and RMI for message exchange. This is not inline with FIPA regulations, which JADE uses.
These findings may not be unconnected with the fact that Aglets is one the first Java agent platforms and the main development ended in 1998 with the latest version 2.0.2 released in 2004 while on the contrary, JADE is actively maintained and supported with the latest version 3.4.1 in November 2006. Future work could test the mobile agent systems across a wider base of parameters such as memory utilization and fault tolerance