SlideShare a Scribd company logo
1 of 24
Download to read offline
Advanced Java
Contents
Introduction 3
Applets 4
Security Implications 5
Sandbox 8
Bytecode Verifier 9
Class Loader 13
Security Manager 15
Language Features 17
Security Through Obscurity 19
Security Through Openness 20
Signed JAR files21
Introduction
Write Once, Run Any Where
Capability.
Applets
 Web Applets are one of the most exciting
uses of the Java Platform.
 Applets are small pieces of executable code
which may be included in Web pages and
which run inside of the user’s browser.
 While traditional web pages have been
limited to simple text and graphics, applets
allow web publishers to include
sophisticated, interactive applications in
their pages.
 Example ?
Security Implications
In traditional environments, companies could protect
themselves by controlling physical and network access
to their computers by establishing policies for what
kinds of software can be used on their machines. These
steps include building a firewall between the Internet
and the company’s intranet, obtaining software only
from known and trusted sources, and using anti-virus
programs to check all new software.
Internet Firewall Intranet
Security Implications
An employee searching an external Web site for
information might inadvertently load and execute an
applet without being aware that the site contains
executable code. This automatic distribution of executable
makes it very likely that software will be obtained from
untrusted third parties. Since the applet is imported into
the user’s web browser and runs locally, this software
could potentially steal or damage information stored in the
user’s machine on a network file server. Also, since this
software is already behind the Company’s firewall, the
applet could attack other unprotected machines on a
corporate intranet. These attacks would not be stopped by
traditional security measures.
Security Implications
Solutions :
 Java protects its users from these dangers by placing strict
limits on applets. Applets cannot read from or write to the
local disk. These limits prevent malicious applets from
stealing information, spreading viruses, or acting as Trojan
horses
 Applets are also prohibited from making network
connections to other computers on the corporate intranet.
This prevents malicious applets from exploiting security
flaws that might exist behind the firewall or in the
underlying operating system.
Sandbox
 The sandbox is an insulation layer that implements a control
policy preventing unsafe access to hardware and operating
system resources.
 The sandbox model is to run untrusted code in a trusted
environment so that if a user accidentally imports a hostile
applet, that applet cannot damage the local machine.
 The applet’s actions are restricted to its sandbox an area of
the web browser dedicated to that applet. The applet may
do anything it wants within its sandbox, but cannot read or
alter any data outside of its sandbox.
Bytecode Verifier
Three components of the bytecode verifier
 Java is not compiled into machine code, but rather into an
intermediate format for a virtual machine.
 Hardware access is mediated by a set of API classes that
implement a suitable access control policy.
 Before execution, the bytecode is statically verified to ensure
that it does not bypass the two security measures.
Bytecode Verifier
 Before running a newly imported applet, the
class loader invokes the verifier. The verifier
checks that the applet conforms to the Java
language specification and that there are no
violations of the Java language rules or name
space restrictions.
 The verifier also checks for common violations of
memory management, like stack underflows o
overflows, and illegal data type casts, which
could allow a hostile applet to corrupt part of the
security mechanism or to replace part of the
system with its own code.
Bytecode Verifier
Correct types
◦ All bytecode instructions are provided with
arguments of the type they expect on operand
stack, registers, and heap.
No overflow and underflow
◦ No instruction tries to retrieve a value from an
empty stack, no instruction tries to put more
elements on the stack than statically specified
in the method, and no instruction accesses
more registers than statically specified in the
method.
Bytecode Verifier
Initialized objects
◦ Before fields or methods of an object
can be accessed, its constructor
must be called. Each constructor in
turn must first call the superclass
constructor before it accesses fields
and methods of the object.
Class Loader
Class loading is a feature of the JVM
that is interesting for bytecode
verification because the class loader is
part of the name space for class
resolving (together with the package
and class name).
When an applet is to be imported from
the network, the web browser calls the
applet class loader.
Class Loader and Bytecode
Verifier
By tricking the BV into believing that two
classes loaded by different class loaders are
equal, type safety could be broken.
The BV in this thesis takes the approach used
on the JavaCard platform and assumes that
all classes of the program have been
preloaded and that no dynamic class loading
at runtime is possible.
Security Manager
 The security manager enforces the boundaries
around the sandbox.
 Whenever an applet tries to perform an action
which could corrupt the local machine or access
information, the Java Virtual Machine first asks
the security manager if this action can be
performed safely. If the security manager
approves the action the virtual machine will then
perform the action. Otherwise, the virtual
machine raises a security exception and writes
an error to the Java console.
Security Manager
 The security manager will not allow an untrusted
applet to read or write to a file, delete a file, get any
information about a file, execute operating system
commands or native code, load a library, or establish a
network connection to any machine other than the
applet’s home server.
 An application or a web browser can only have one
security manager. This assures that all access checks
are made by a single security manager enforcing a
single security policy. The security manager is loaded
at start-up and cannot be extended, overridden or
replaced. For obvious reasons, applets can not create
their own security managers
Language Features
 Java has several language features which
protect the integrity of the security system
and which prevent several common attacks.
 For example, Java programs are not allowed
to define their own memory pointers or to
access physical memory directly.
 The Java language also has several other
checks for memory and pointer abuse which
could weaken the security system.
Language Features
Studies have shown that 40% to 50%
of all bugs are caused by errors in
memory management. By automating
memory management, Java eliminates
a large class of bugs. This results in
more stable and reliable code.
Security Through Obscurity
 In the past, many computer and network systems tried to
maintain security by hiding the inner works and policies
of the system. This practice, known as security through
obscurity.
 The existence of the CERT/CC and a number of well
publicized network attacks in recent years demonstrate
that this assumption is unfounded.
 This is especially true for commercially successful
systems. For such widely used systems, too many people
know the internal workings of the system for the details
to remain secret and the rewards for breaking into the
system are too great.
Security Through Openness
 Sun took the opposite approach, and published all the details of
Java security model when Java was first released.
 This approach, dubbed security through openness, was
intended to encourage security researchers to examine the Java
model and to report any security flaws found. The flaws could
be fixed before attacks based on those flaws could become
endemic on the Web.
 Security through openness also allows any organization to study
the Java security model.
 FAQ
http://java.sun.com/sfaq
Signed JAR files
All networked systems are potentially vulnerable to the
“Man-in-the-Middle” attack
In this attack, a client contacts a legitimate server on
the network and requests some action. The attacker,
or man in the middle, notices this request and waits for
the server to respond. The attacker then intercepts the
response and supplies a bogus reply to the client. The
client then acts on the bogus information, or possibly
runs the program supplied by the attacker, giving the
attacker access to the client machine.
Example ?
Signed JAR files
Signed Applets give us the same level of confidence in network distributed software. To sign an applet,
the producer first bundles all the Java code and related files into a single file called a Java Archive, or
JAR. The producer then creates. a string called a digital signature based on the contents of the JAR.
JAR files solve another problem. Currently, many Java applets take a very long time to download and
begin running. This can be annoying even for those users with a very high speed link to the Internet.
The problem is that current Internet protocols move web pages across the Internet one file at a time.
Since there is some overhead associated with each request for a file, web pages and Java applets which
are composed of many small files might spend more time requesting those files and waiting for replies
than they spend actually moving the information. Since a JAR file bundles all the information needed by
the applet and its web page into a single file, the entire page can be downloaded with a single request.
For many pages this will greatly reduce download times.
Signed JAR files
JARs and digital signatures can also be used for Java applications.
While Java applications are more trustworthy than applets because
they do not travel over the Internet and are subject to an
organizations traditional security policies, applications are subject to
several types of attack. For example, viruses spread by modifying
existing applications to include a copy of the virus. Since a virus
would not be able to produce a valid signature for the altered
program, the Java system could detect that a signed application has
been tampered with, and refuse to run it.
Thank You!
By:
Hossein Mobasher
Hamid Mozaffari

More Related Content

What's hot

Advance java Online Training in Hyderabad
Advance java Online Training in HyderabadAdvance java Online Training in Hyderabad
Advance java Online Training in HyderabadUgs8008
 
Web Tech Java Servlet Update1
Web Tech   Java Servlet Update1Web Tech   Java Servlet Update1
Web Tech Java Servlet Update1vikram singh
 
Servlet and JSP
Servlet and JSPServlet and JSP
Servlet and JSPGary Yeh
 
JAVA EE DEVELOPMENT (JSP and Servlets)
JAVA EE DEVELOPMENT (JSP and Servlets)JAVA EE DEVELOPMENT (JSP and Servlets)
JAVA EE DEVELOPMENT (JSP and Servlets)Talha Ocakçı
 
Core web application development
Core web application developmentCore web application development
Core web application developmentBahaa Farouk
 
An Introduction To Java Web Technology
An Introduction To Java Web TechnologyAn Introduction To Java Web Technology
An Introduction To Java Web Technologyvikram singh
 
Servletarchitecture,lifecycle,get,post
Servletarchitecture,lifecycle,get,postServletarchitecture,lifecycle,get,post
Servletarchitecture,lifecycle,get,postvamsi krishna
 
1 java servlets and jsp
1   java servlets and jsp1   java servlets and jsp
1 java servlets and jspAnkit Minocha
 
Servlet.ppt
Servlet.pptServlet.ppt
Servlet.pptVMahesh5
 
Chapter 3 servlet & jsp
Chapter 3 servlet & jspChapter 3 servlet & jsp
Chapter 3 servlet & jspJafar Nesargi
 
Java servlets
Java servletsJava servlets
Java servletslopjuan
 

What's hot (20)

Advance java Online Training in Hyderabad
Advance java Online Training in HyderabadAdvance java Online Training in Hyderabad
Advance java Online Training in Hyderabad
 
Java Servlets
Java ServletsJava Servlets
Java Servlets
 
Web Tech Java Servlet Update1
Web Tech   Java Servlet Update1Web Tech   Java Servlet Update1
Web Tech Java Servlet Update1
 
Java Servlets & JSP
Java Servlets & JSPJava Servlets & JSP
Java Servlets & JSP
 
Advance Java
Advance JavaAdvance Java
Advance Java
 
Servlet and JSP
Servlet and JSPServlet and JSP
Servlet and JSP
 
Jsp servlets
Jsp servletsJsp servlets
Jsp servlets
 
JDBC
JDBCJDBC
JDBC
 
JAVA EE DEVELOPMENT (JSP and Servlets)
JAVA EE DEVELOPMENT (JSP and Servlets)JAVA EE DEVELOPMENT (JSP and Servlets)
JAVA EE DEVELOPMENT (JSP and Servlets)
 
Java Servlet
Java Servlet Java Servlet
Java Servlet
 
Core web application development
Core web application developmentCore web application development
Core web application development
 
An Introduction To Java Web Technology
An Introduction To Java Web TechnologyAn Introduction To Java Web Technology
An Introduction To Java Web Technology
 
Java servlets
Java servletsJava servlets
Java servlets
 
Servletarchitecture,lifecycle,get,post
Servletarchitecture,lifecycle,get,postServletarchitecture,lifecycle,get,post
Servletarchitecture,lifecycle,get,post
 
1 java servlets and jsp
1   java servlets and jsp1   java servlets and jsp
1 java servlets and jsp
 
Servlet.ppt
Servlet.pptServlet.ppt
Servlet.ppt
 
Servlets
ServletsServlets
Servlets
 
Java Servlets
Java ServletsJava Servlets
Java Servlets
 
Chapter 3 servlet & jsp
Chapter 3 servlet & jspChapter 3 servlet & jsp
Chapter 3 servlet & jsp
 
Java servlets
Java servletsJava servlets
Java servlets
 

Viewers also liked

Viewers also liked (8)

Top 9 advanced java interview questions answers
Top 9 advanced java interview questions answersTop 9 advanced java interview questions answers
Top 9 advanced java interview questions answers
 
advanced java programming(java programming tutorials)
 advanced java programming(java programming tutorials) advanced java programming(java programming tutorials)
advanced java programming(java programming tutorials)
 
Core & advanced java classes in mumbai
Core & advanced java classes in mumbaiCore & advanced java classes in mumbai
Core & advanced java classes in mumbai
 
Advanced java online training
Advanced java online trainingAdvanced java online training
Advanced java online training
 
Introduction to the Java(TM) Advanced Imaging API
Introduction to the Java(TM) Advanced Imaging APIIntroduction to the Java(TM) Advanced Imaging API
Introduction to the Java(TM) Advanced Imaging API
 
Learn advanced java programming
Learn advanced java programmingLearn advanced java programming
Learn advanced java programming
 
Advanced JAVA
Advanced JAVAAdvanced JAVA
Advanced JAVA
 
Core java course syllabus
Core java course syllabusCore java course syllabus
Core java course syllabus
 

Similar to Advanced Java

Sandboxing (Distributed computing)
Sandboxing (Distributed computing)Sandboxing (Distributed computing)
Sandboxing (Distributed computing)Sri Prasanna
 
Java Application Development Vulnerabilities
Java Application Development VulnerabilitiesJava Application Development Vulnerabilities
Java Application Development VulnerabilitiesNarola Infotech
 
Benefits of web application firewalls
Benefits of web application firewallsBenefits of web application firewalls
Benefits of web application firewallsEnclaveSecurity
 
Injecting Security into Web apps at Runtime Whitepaper
Injecting Security into Web apps at Runtime WhitepaperInjecting Security into Web apps at Runtime Whitepaper
Injecting Security into Web apps at Runtime WhitepaperAjin Abraham
 
Web application penetration testing lab setup guide
Web application penetration testing lab setup guideWeb application penetration testing lab setup guide
Web application penetration testing lab setup guideSudhanshu Chauhan
 
Secure programming with php
Secure programming with phpSecure programming with php
Secure programming with phpMohmad Feroz
 
Become fully aware of the potential dangers of ActiveX attacks
Become fully aware of the potential dangers of ActiveX attacksBecome fully aware of the potential dangers of ActiveX attacks
Become fully aware of the potential dangers of ActiveX attacksHigh-Tech Bridge SA (HTBridge)
 
Secure Computing With Java
Secure Computing With JavaSecure Computing With Java
Secure Computing With Javawhite paper
 
JAVA INTRODUCTION
JAVA INTRODUCTIONJAVA INTRODUCTION
JAVA INTRODUCTIONProf Ansari
 
JAVA INTRODUCTION
JAVA INTRODUCTIONJAVA INTRODUCTION
JAVA INTRODUCTIONProf Ansari
 
Sandboxing - Malware detection.pptx
Sandboxing - Malware detection.pptxSandboxing - Malware detection.pptx
Sandboxing - Malware detection.pptxArshadFarhad4
 
Cq3210191021
Cq3210191021Cq3210191021
Cq3210191021IJMER
 
Java Card Security
Java Card SecurityJava Card Security
Java Card SecurityRiscure
 
2009: Securing Applications With Web Application Firewalls and Vulnerability ...
2009: Securing Applications With Web Application Firewalls and Vulnerability ...2009: Securing Applications With Web Application Firewalls and Vulnerability ...
2009: Securing Applications With Web Application Firewalls and Vulnerability ...Neil Matatall
 
Advanced security - Seccom Global
Advanced security - Seccom Global Advanced security - Seccom Global
Advanced security - Seccom Global Kim Tu
 
Bank One App Sec Training
Bank One App Sec TrainingBank One App Sec Training
Bank One App Sec TrainingMike Spaulding
 

Similar to Advanced Java (20)

Sandboxing (Distributed computing)
Sandboxing (Distributed computing)Sandboxing (Distributed computing)
Sandboxing (Distributed computing)
 
Cyber ppt
Cyber pptCyber ppt
Cyber ppt
 
Java Application Development Vulnerabilities
Java Application Development VulnerabilitiesJava Application Development Vulnerabilities
Java Application Development Vulnerabilities
 
Benefits of web application firewalls
Benefits of web application firewallsBenefits of web application firewalls
Benefits of web application firewalls
 
Security in Java
Security in JavaSecurity in Java
Security in Java
 
Injecting Security into Web apps at Runtime Whitepaper
Injecting Security into Web apps at Runtime WhitepaperInjecting Security into Web apps at Runtime Whitepaper
Injecting Security into Web apps at Runtime Whitepaper
 
Vm Penetration Test
Vm Penetration TestVm Penetration Test
Vm Penetration Test
 
Web application penetration testing lab setup guide
Web application penetration testing lab setup guideWeb application penetration testing lab setup guide
Web application penetration testing lab setup guide
 
Secure programming with php
Secure programming with phpSecure programming with php
Secure programming with php
 
E farming
E farmingE farming
E farming
 
Become fully aware of the potential dangers of ActiveX attacks
Become fully aware of the potential dangers of ActiveX attacksBecome fully aware of the potential dangers of ActiveX attacks
Become fully aware of the potential dangers of ActiveX attacks
 
Secure Computing With Java
Secure Computing With JavaSecure Computing With Java
Secure Computing With Java
 
JAVA INTRODUCTION
JAVA INTRODUCTIONJAVA INTRODUCTION
JAVA INTRODUCTION
 
JAVA INTRODUCTION
JAVA INTRODUCTIONJAVA INTRODUCTION
JAVA INTRODUCTION
 
Sandboxing - Malware detection.pptx
Sandboxing - Malware detection.pptxSandboxing - Malware detection.pptx
Sandboxing - Malware detection.pptx
 
Cq3210191021
Cq3210191021Cq3210191021
Cq3210191021
 
Java Card Security
Java Card SecurityJava Card Security
Java Card Security
 
2009: Securing Applications With Web Application Firewalls and Vulnerability ...
2009: Securing Applications With Web Application Firewalls and Vulnerability ...2009: Securing Applications With Web Application Firewalls and Vulnerability ...
2009: Securing Applications With Web Application Firewalls and Vulnerability ...
 
Advanced security - Seccom Global
Advanced security - Seccom Global Advanced security - Seccom Global
Advanced security - Seccom Global
 
Bank One App Sec Training
Bank One App Sec TrainingBank One App Sec Training
Bank One App Sec Training
 

More from Hossein Mobasher

More from Hossein Mobasher (7)

Shive
ShiveShive
Shive
 
CodeIgniter
CodeIgniterCodeIgniter
CodeIgniter
 
ISR
ISRISR
ISR
 
Database
DatabaseDatabase
Database
 
Association Rule Mining in Social Network Data
Association Rule Mining in Social Network DataAssociation Rule Mining in Social Network Data
Association Rule Mining in Social Network Data
 
Live API Documentation
Live API Documentation Live API Documentation
Live API Documentation
 
Presentation
PresentationPresentation
Presentation
 

Advanced Java

  • 2. Contents Introduction 3 Applets 4 Security Implications 5 Sandbox 8 Bytecode Verifier 9 Class Loader 13 Security Manager 15 Language Features 17 Security Through Obscurity 19 Security Through Openness 20 Signed JAR files21
  • 3. Introduction Write Once, Run Any Where Capability.
  • 4. Applets  Web Applets are one of the most exciting uses of the Java Platform.  Applets are small pieces of executable code which may be included in Web pages and which run inside of the user’s browser.  While traditional web pages have been limited to simple text and graphics, applets allow web publishers to include sophisticated, interactive applications in their pages.  Example ?
  • 5. Security Implications In traditional environments, companies could protect themselves by controlling physical and network access to their computers by establishing policies for what kinds of software can be used on their machines. These steps include building a firewall between the Internet and the company’s intranet, obtaining software only from known and trusted sources, and using anti-virus programs to check all new software. Internet Firewall Intranet
  • 6. Security Implications An employee searching an external Web site for information might inadvertently load and execute an applet without being aware that the site contains executable code. This automatic distribution of executable makes it very likely that software will be obtained from untrusted third parties. Since the applet is imported into the user’s web browser and runs locally, this software could potentially steal or damage information stored in the user’s machine on a network file server. Also, since this software is already behind the Company’s firewall, the applet could attack other unprotected machines on a corporate intranet. These attacks would not be stopped by traditional security measures.
  • 7. Security Implications Solutions :  Java protects its users from these dangers by placing strict limits on applets. Applets cannot read from or write to the local disk. These limits prevent malicious applets from stealing information, spreading viruses, or acting as Trojan horses  Applets are also prohibited from making network connections to other computers on the corporate intranet. This prevents malicious applets from exploiting security flaws that might exist behind the firewall or in the underlying operating system.
  • 8. Sandbox  The sandbox is an insulation layer that implements a control policy preventing unsafe access to hardware and operating system resources.  The sandbox model is to run untrusted code in a trusted environment so that if a user accidentally imports a hostile applet, that applet cannot damage the local machine.  The applet’s actions are restricted to its sandbox an area of the web browser dedicated to that applet. The applet may do anything it wants within its sandbox, but cannot read or alter any data outside of its sandbox.
  • 9. Bytecode Verifier Three components of the bytecode verifier  Java is not compiled into machine code, but rather into an intermediate format for a virtual machine.  Hardware access is mediated by a set of API classes that implement a suitable access control policy.  Before execution, the bytecode is statically verified to ensure that it does not bypass the two security measures.
  • 10. Bytecode Verifier  Before running a newly imported applet, the class loader invokes the verifier. The verifier checks that the applet conforms to the Java language specification and that there are no violations of the Java language rules or name space restrictions.  The verifier also checks for common violations of memory management, like stack underflows o overflows, and illegal data type casts, which could allow a hostile applet to corrupt part of the security mechanism or to replace part of the system with its own code.
  • 11. Bytecode Verifier Correct types ◦ All bytecode instructions are provided with arguments of the type they expect on operand stack, registers, and heap. No overflow and underflow ◦ No instruction tries to retrieve a value from an empty stack, no instruction tries to put more elements on the stack than statically specified in the method, and no instruction accesses more registers than statically specified in the method.
  • 12. Bytecode Verifier Initialized objects ◦ Before fields or methods of an object can be accessed, its constructor must be called. Each constructor in turn must first call the superclass constructor before it accesses fields and methods of the object.
  • 13. Class Loader Class loading is a feature of the JVM that is interesting for bytecode verification because the class loader is part of the name space for class resolving (together with the package and class name). When an applet is to be imported from the network, the web browser calls the applet class loader.
  • 14. Class Loader and Bytecode Verifier By tricking the BV into believing that two classes loaded by different class loaders are equal, type safety could be broken. The BV in this thesis takes the approach used on the JavaCard platform and assumes that all classes of the program have been preloaded and that no dynamic class loading at runtime is possible.
  • 15. Security Manager  The security manager enforces the boundaries around the sandbox.  Whenever an applet tries to perform an action which could corrupt the local machine or access information, the Java Virtual Machine first asks the security manager if this action can be performed safely. If the security manager approves the action the virtual machine will then perform the action. Otherwise, the virtual machine raises a security exception and writes an error to the Java console.
  • 16. Security Manager  The security manager will not allow an untrusted applet to read or write to a file, delete a file, get any information about a file, execute operating system commands or native code, load a library, or establish a network connection to any machine other than the applet’s home server.  An application or a web browser can only have one security manager. This assures that all access checks are made by a single security manager enforcing a single security policy. The security manager is loaded at start-up and cannot be extended, overridden or replaced. For obvious reasons, applets can not create their own security managers
  • 17. Language Features  Java has several language features which protect the integrity of the security system and which prevent several common attacks.  For example, Java programs are not allowed to define their own memory pointers or to access physical memory directly.  The Java language also has several other checks for memory and pointer abuse which could weaken the security system.
  • 18. Language Features Studies have shown that 40% to 50% of all bugs are caused by errors in memory management. By automating memory management, Java eliminates a large class of bugs. This results in more stable and reliable code.
  • 19. Security Through Obscurity  In the past, many computer and network systems tried to maintain security by hiding the inner works and policies of the system. This practice, known as security through obscurity.  The existence of the CERT/CC and a number of well publicized network attacks in recent years demonstrate that this assumption is unfounded.  This is especially true for commercially successful systems. For such widely used systems, too many people know the internal workings of the system for the details to remain secret and the rewards for breaking into the system are too great.
  • 20. Security Through Openness  Sun took the opposite approach, and published all the details of Java security model when Java was first released.  This approach, dubbed security through openness, was intended to encourage security researchers to examine the Java model and to report any security flaws found. The flaws could be fixed before attacks based on those flaws could become endemic on the Web.  Security through openness also allows any organization to study the Java security model.  FAQ http://java.sun.com/sfaq
  • 21. Signed JAR files All networked systems are potentially vulnerable to the “Man-in-the-Middle” attack In this attack, a client contacts a legitimate server on the network and requests some action. The attacker, or man in the middle, notices this request and waits for the server to respond. The attacker then intercepts the response and supplies a bogus reply to the client. The client then acts on the bogus information, or possibly runs the program supplied by the attacker, giving the attacker access to the client machine. Example ?
  • 22. Signed JAR files Signed Applets give us the same level of confidence in network distributed software. To sign an applet, the producer first bundles all the Java code and related files into a single file called a Java Archive, or JAR. The producer then creates. a string called a digital signature based on the contents of the JAR. JAR files solve another problem. Currently, many Java applets take a very long time to download and begin running. This can be annoying even for those users with a very high speed link to the Internet. The problem is that current Internet protocols move web pages across the Internet one file at a time. Since there is some overhead associated with each request for a file, web pages and Java applets which are composed of many small files might spend more time requesting those files and waiting for replies than they spend actually moving the information. Since a JAR file bundles all the information needed by the applet and its web page into a single file, the entire page can be downloaded with a single request. For many pages this will greatly reduce download times.
  • 23. Signed JAR files JARs and digital signatures can also be used for Java applications. While Java applications are more trustworthy than applets because they do not travel over the Internet and are subject to an organizations traditional security policies, applications are subject to several types of attack. For example, viruses spread by modifying existing applications to include a copy of the virus. Since a virus would not be able to produce a valid signature for the altered program, the Java system could detect that a signed application has been tampered with, and refuse to run it.