When Mobile Code and Smart Cards Meet: Java Card Security
When Mobile Code and Smart Cards Meet: Java Card Security
3
Mobile code is smart
4
Mobile code is dumb
5
IEEE IC, 2(6), Nov/Dec 1998
A brief history
• 1980s • 1995
– downloading arbitrary
binaries and executing – Java and Javascript
them is a BAD IDEA introduce widespread
– Archie and ftp mobile code
– risks include: – the concept virus
• Trojan Horses appears
• viruses
– checksumming to the • 1999
rescue? – Melissa
• 1992
– the Web arrives
• 2000
– Archie dies – The Love Bug
6
Mobile code and security
• JavaScript • ActiveX
– invasion of privacy – system modification
– denial of service attacks
– Web spoofing – stealing money
• Macro problems • Java security
– the concept virus – more power equals
– the Melissa virus more risk
– the Love Bug – attack applets in the
lab
7
The classic security tradeoff
8
Java’s answer
9
A question of trust
10
Untrusted code is restricted
There is some
overlap among these
classes, but they
make the risks easier
to understand
A chronology of attack applets
• A simple processor
embedded in a plastic
card
– Same size as a credit card
• New technology allows
multiple applications on
the same card
• Useful for hundreds of
applications
– Debit, credit, cash
– Identity, cryptography
20
How Java and smart cards mix
21
How can Java fit on a card?
22
Multi-application cards
23
Java Card security != Java security
Good Bad
• no dynamic class loading • applets added post
– type safety issues issuance (ARGH)
• only one active applet • no sandbox
• no threading – trusted code required
• objects include • native method calls
rudimentary access • no garbage collection
control • object sharing complexity
• out of band verification
24
Security risks in Java Card 2.1
25
Multi-application issues
27
The terminal problem
28
Protocol interaction risks
29
Security is harder than it sounds
30
What to do?
32
Where to learn more
• http://www.securingjava.com
– Chapter 8: Java Card Security
http://www.cigital.com
[email protected] 33