Mobile agents

21
Mobile Agents

Transcript of Mobile agents

Page 1: Mobile agents

Mobile Agents

Page 2: Mobile agents

2

Mobile (transportable) agents

An agent is “an independent software program, which runs on behalf of a network user”.

A mobile agent is a program that, once it is launched by a user, can travel from node to node autonomously, and can continue to function even if the user is disconnected from the network.

Page 3: Mobile agents

3

Agent ServerAgentServer

Agent server

File server

...

A mobile agent performs workon behalf of a user as it travels to multiple locationson the network.

user

Database server

Page 4: Mobile agents

What is mobile agent ?

-Program that can migrate : where and how ?

-Performs some processing at each host

-Agent decides when and where to move next

-How it Move : on just three steps

*Save state

*Transport

*Resume

Page 5: Mobile agents

A Mobile Agent Dissected

Attributes State Code

Program in Program in a suitable a suitable Language Language to define to define The The behavior of behavior of Agent Agent

-Set the -Set the internal internal variables variables -Resume -Resume its activity its activity after after moving to moving to another another host host

-info -info describing describing the agent the agent -Its origin, -Its origin, ownerowner-Movement -Movement history history --AuthenticatAuthentication key ion key

Page 6: Mobile agents

6

Advantages of Mobile Agents

They allow efficient and economical use of communication channels that may have low bandwidth, high latency, and may be error-prone.They enable the use of portable, low-cost, personal communications devices to perform complex tasks even when the device is disconnected from the network.They allow asynchronous operations and true decentralization

Page 7: Mobile agents

7

Mobile Agent Paradigm vs. Client-Server Paradigm

...

The c l i e nt-s e r ve r par adi g m

The m o bi l e ag e nt par adi g m

c l i e nt ho s t s e r ve r ho s t

ho s t A

ho s tB

c o m m u n ic a tio nd a ta

ag en ttr an s p o r ta t io n

Page 8: Mobile agents

8

Basic Architecture

An agent server process runs on each participating host.Participating hosts are networked through links that can be low-bandwidth and unreliable.An agent is a serializable object whose execution state can be frozen for transportation and reconstituted upon arrival at a remote site.

Page 9: Mobile agents

9

Basic Architecture

ag en ts erv er

ag en t s erv erh o s t

m o b ile ag en t

Page 10: Mobile agents

10

What’s in the Agent?

An agent is an object, hence it contains state data and methods.

Among the instance data is an itinerary of the sites to be visited, which may be dynamically constructed or adjusted.

Other data may include an agent ID or other authentication data.

The agent’s behavior at each stop can be pre-programmed and dynamically adjusted.

Page 11: Mobile agents
Page 12: Mobile agents

Events in Mobile Agent

12

Creation: a brand new agent is born and its state is initialized.

Cloning: a twin agent is born and the current state of the original is duplicated in the clone.

Dispatch: an agent travels to a new host.

Deactivation: an agent is put to sleep and its state is saved in persistent storage.

Activation: a deactivated agent is brought back to life and its state is restored from persistent storage.

Page 13: Mobile agents

13

Retraction: an agent is brought back from a remote host along with its state to the home machine.

Disposal: an agent is terminated and its state is lost forever.

Communication: Notifies the agent to handle messages incoming from other agents , which is the primary means of inter-agent correspondence.

Page 14: Mobile agents

Why mobile agent ?

-They reduce the network load

-they overcome network latency

-they encapsulate protocols

-they adapt dynamically

-they execute asynchronously and autonomously

-they are natural heterogeneous

-they are fault tolerance

Page 15: Mobile agents

15

Mobile-agent applications

Information retrieval

Monitoring

Virtual market-place/ meeting room

Shareware

Page 16: Mobile agents

Mobile Agents in Java

A mobile agent in Java is called an “Aglet”– Light weight agent

Why use Java– Platform independence!– Create once, go anywhere– Price ….. FREE TOOLKITS ( ASDK )– Hosts can provide an environment for the

aglet to execute within

Page 17: Mobile agents

Levels of mobility

Weak -when moving a mobile agent Carrier (Code + DateState)

-global or instance variables

-on moving , execution starts from the beginning

Strong -when moving a mobile agent Carrier (Code + DateState + Execution State)

-global or instance variables

- Execution State :local variables and threads

-on moving : execution can be continued from the point it is stopped previously

Page 18: Mobile agents

18

Security in Mobile Agent Systems

• Security concern is the primary deterrent of deploying the mobile-agent technology.

• There are concerns for both the agent hosts and the mobile agents.– Agent host concerns:

Malicious/unauthorized agents can misuse/destroy system resources (e.g., worms).

– Agent concerns:Malicious hosts can destroy or alter an agent’s logic, ( e.g., Mobile agent’s route can be altered.)

Page 19: Mobile agents

19

Security in Mobile Agent Systems

Measures:Authentication – an agent must authenticate itself to the host, and an agent server must authenticate itself to the agent.Encryption – an agent encrypts its sensitive data.Resource access – a host enforces strict access control to its resources.

Page 20: Mobile agents

Current Areas of Work

mobile agent theories: Pi-calculus extensions, Mobile Ambients, Agent Itinerariesmobile agent model: some component-based, AI-basedmobile agent infrastructure: environment supporting mobile agents - security, naming, domain crossing, etcmobile agent programming: languages, toolkits, abstractions mobile agent applications: mobile agent standards: OMG’s MASIF, FIPA

Page 21: Mobile agents

Research Issues

Security: protect host from agents, protect agents from agents, protect agents from hostPerformance: if Java or Python, performance penalties with interpretation (esp. for performance critical applications), but not for long?Strong mobility: move full execution state (stacks etc), stacks not accessible with current Java?MA management: – how control and manage deployed agents– issues: fault tolerance (e.g., agent fails, host

fails), recalling agents, tracking agents, servicing agents (esp. longer living agents)