SlideShare une entreprise Scribd logo
1  sur  58
Advanced Java Day
Security Architecture of the
Java Platform
МАРТИН TОШЕВ
Advanced Java Day
BG JUG mailing list:
https://groups.google.com/foru
m/#!forum/bg-jug
Advanced Java DayAdvanced Java Day
Agenda
• Evolution of the Java security model
• Outside the sandbox - APIs for secure
coding
• Designing and coding with security in mind
Advanced Java Day
Evolution of the Java security
model
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• Traditionally - companies protect they
assets using strict physical and network
access policies
• Tools such as anti-virus software, firewalls,
IPS/IDS systems facilitate this approach
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• With the introduction of various
technologies for loading and executing
code on the client machine from the
browser (such as Applets) - a new range
of concerns emerge related to client
security – this is when the Java security
sandbox starts to evolve …
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• The goal of the Java security sandbox is to
allow untrusted code from applets to be
executed in a trusted environment such as
the user's browser
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• JDK 1.0 (when it all started …) – the
original sandbox model was introduced
Applet
(untrusted)
System code
(trusted)
JVM
Browser
http://javaday.bg/demoapplet
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• Code executed by the JVM is divided in
two domains – trusted and untrusted
• Strict restriction are applied by default on
the security model of applets such as
denial to read/write data from disk,
connect to the network and so on
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• JDK 1.1 (gaining trust …) – applet signing
introduced
Applet
(untrusted)
System code
(trusted)
JVM
Browser
http://javaday.bg/demoapplet
Signed Applet
(trusted)
http://javaday.bg/trustedapplet
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• Trusted local code and untrusted
remote code from applets restricted to
a predefined set of operations OR
signed applet code that is trusted
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• Steps needed to sign and run an
applet:
– Compile the applet
– Create a JAR file for the applet
– Generate a pair of public/private keys
– Sign the applet JAR with the private key
– Export a certificate for the public key
– Import the Certificate as a Trusted Certificate
– Create the policy file
– Load and run the applet
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• JDK 1.2 (gaining more trust …) – fine-
grained access control
Applet
System code
JVM
Browser
http://javaday.bg/demoapplet
grant codeBase http://javaday.bg/demoapplet {
permission java.io.FilePermissions “C:Windows” “delete”
}
security.policy
SecurityManager.checkPermission(…)
AccessController.checkPermission(…)
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• Since the security model is code-centric -
additional access control decisions are
specified in a security policy
• No more notion of trusted and untrusted
code
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• The notion of protection domain
introduced – determined by the security
policy
• Two types of protection domains – system
and application
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• The protection domain is set during
classloading and contains the code
source and the list of permissions for the
class
applet.getClass().getProtectionDomain();
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• One permission can imply another
permission
java.io.FilePermissions “C:Windows” “delete”
implies
java.io.FilePermissions “C:Windowssystem32” “delete”
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• One code source can imply another code
source
codeBase http://javaday.bg/
implies
codeBase http://javaday.bg/demoapplet
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• Since an execution thread may pass through
classes loaded by different classloaders (and
hence – have different protection domains)
the following rule of thumb applies:
The permission set of an execution thread is considered
to be the intersection of the permissions of all protection
domains traversed by the execution thread
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• JDK 1.3, 1,4 (what about entities running
the code … ?) – JAAS
Applet
System code
JVM
Browser
http://javaday.bg/demoapplet
grant principal javax.security.auth.x500.X500Principal "cn=Tom"
{ permission java.io.FilePermissions “C:Windows” “delete” }
security.policy
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• JAAS (Java Authentication and
Authorization Service) extends the security
model with role-based permissions
• The protection domain of a class now may
contain not only the code source and the
permissions but a list of principals
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• The authentication component of JAAS is
independent of the security sandbox in
Java and hence is typically used in more
wider context (such as j2ee app servers)
• The authorization component is the one
that extends the Java security policy
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• Core classes of JAAS:
– javax.security.auth.Subject - an authenticated subject
– java.security.Principal - identifying characteristic of a subject
– javax.security.auth.spi.LoginModule - interface for
implementors of login (PAM) modules
– javax.security.auth.login.LoginContext - creates objects used
for authentication
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• Up to JDK 1.4 the following is a typical
flow for permission checking:
1) upon system startup a security policy is set and a
security manager is installed
Policy.setPolicy(…)
System.setSecurityManager(…)
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• Up to JDK 1.4 the following is a typical
flow for permission checking:
2) during classloading (e.g. of a remote applet)
bytecode verification is done and the protection
domain is set for the current classloader (along
with the code source, the set of permissions and
the set of JAAS principals)
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• Up to JDK 1.4 the following is a typical
flow for permission checking:
3) when system code is invoked from the remote
code the SecurityManager is used to check
against the intersection of protection domains
based on the chain of threads and their call stacks
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• Up to JDK 1.4 the following is a typical
flow for permission checking:
SocketPermission permission = new
SocketPermission("javaday.bg:8000-
9000","connect,accept");
SecurityManager sm = System.getSecurityManager();
if (sm != null) sm.checkPermission(permission);
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• Up to JDK 1.4 the following is a typical
flow for permission checking:
4) application code can also do permission checking
against remote code using a SecurityManager or
an AccessController
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• Up to JDK 1.4 the following is a typical
flow for permission checking:
SocketPermission permission = new
SocketPermission("javaday.bg:8000-9000",
"connect,accept");
AccessController.checkPermission(permission)
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• Up to JDK 1.4 the following is a typical
flow for permission checking:
5) application code can also do permission checking
with all permissions of the calling domain or a
particular JAAS subject
AccessController.doPrivileged(…)
Subject.doAs(…)
Subject.doAsPrivileged(…)
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• The security model defined by
java.lang.SecurityManager is
customizable
• For example: Oracle JVM uses a custom
SecurityManager with additional permission classes
where the code source is a database schema
(containing e.g. Java stored procedures)
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• JDK 1.5, 1.6 (enhancing the model …) –
new additions to the sandbox model (e.g.
LDAP support for JAAS)
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• JDK 1.7, 1.8 (further enhancing the model
…) – enhancements to the sandbox model
(e.g. AccessController.doPrivileged() for
checking against a subset of permissions)
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• JDK 1.9 and beyond … (applying the
model to modules …)
application module
system
module 1
JVM
Browser
http://javaday.bg/appmodule
security.policy
system
module 2
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• By modules we understand modules in
JDK as defined by project Jigsaw
• Modules must conform to the same security
model as applets – moreover each module is
loaded by a different classloader – hence
classes in different modules must have
different protection domains
Advanced Java DayAdvanced Java Day
Evolution of the
Java security model
• Modularization of the JDK system classes
allows further to define fine-grained
access control permissions for classes in
the system domain
• This is not currently allowed due to the
monolithic nature of the JDK
Advanced Java Day
Outside the sandbox - APIs for
secure coding
Advanced Java DayAdvanced Java Day
Outside the sandbox - APIs for
secure coding
• The security sandbox defines a strict
model for execution of remote code in the
JVM
• The other side of the coin are the security
APIs that provide utilities for implementing
the different aspects of application security
…
Advanced Java DayAdvanced Java Day
Outside the sandbox - APIs for
secure coding
• The additional set of APIs includes:
– JCA (Java Cryptography Architecture)
– PKI (Public Key Infrastructure) utilities
– JSSE (Java Secure Socket Extension)
– Java GSS API (Java Generic Security Services)
– Java SASL API (Java Simple Authentication and
Security Layer)
Advanced Java DayAdvanced Java Day
Outside the sandbox - APIs for
secure coding
• JCA provides utilities for:
– creating digital signatures
– creating message digests
– using cryptographic ciphers (symetric/asymetric,
block/stream)
– using different other types of cryptographic services
and algorithms
Advanced Java DayAdvanced Java Day
Outside the sandbox - APIs for
secure coding
• JCA has a pluggable architecture
• JCA is independent from particular
cryptographic algorithms
• JCA continues to evolve (especially by
providing stronger cryptographic algorithms)
Advanced Java DayAdvanced Java Day
Outside the sandbox - APIs for
secure coding
• PKI utilities provide means for working
with:
– certificates
– certificate revocation lists (CRL)
– OCSP (Online Certificate Status Protocol)
– key stores and trust stores (also based on the PKCS -
public-key cryptography standards)
Advanced Java DayAdvanced Java Day
Outside the sandbox - APIs for
secure coding
• PKI certificate revocation check (revision):
• PKI utilities continue to evolve (especially in
providing more support for managing
certificates and keys)
certificate
authorityrevocation
checking
OCSP
CRL
certificate
certificate
Advanced Java DayAdvanced Java Day
Outside the sandbox - APIs for
secure coding
• JSSE provides an implementation of the
TSL/SSL sockets for working with remote
communication
• JSSE continues to evolve (especially in
the support for additional features such as
Server Name Identication)
Advanced Java DayAdvanced Java Day
Outside the sandbox - APIs for
secure coding
• Java GSS API provides an alternative of
JSSE for secure communication
• Java GSS API is a framework for providing
token-based security services that is
independent of the underlying protocols
Advanced Java DayAdvanced Java Day
Outside the sandbox - APIs for
secure coding
• Java GSS API can be used along with
JAAS for authentication purposes
• Java GSS API continues to evolve
(especially in the support for Kerberos
authentication)
Advanced Java DayAdvanced Java Day
Outside the sandbox - APIs for
secure coding
• Java SASL defines a protocol for
exchange of authentication data
• Java SASL is a framework where external
providers give concrete semantics to the
authentication data being exchanged
Advanced Java DayAdvanced Java Day
Outside the sandbox - APIs for
secure coding
• Java SASL continues to evolve (especially
with support for additional and enhanced
properties for exchanging authentication
data)
Advanced Java Day
Designing and coding with
security in mind
Advanced Java DayAdvanced Java Day
Designing and coding
with security in mind
• First of all - follow programing guidelines
and best practices - most are not bound to
the Java programming language (input
validation, error handling, type safety,
access modifiers, resource cleanup,
prepared SQL queries and whatever you
can think of …)
Advanced Java DayAdvanced Java Day
Designing and coding
with security in mind
• Respect the SecurityManager -
designlibraries so that they work in
environments with installed
SecurityManager
• Example: GSON library does not respect the
SecurityManager and cannot be used without additional
reflective permissions in some scenarios
Advanced Java DayAdvanced Java Day
Designing and coding
with security in mind
• Grant minimal permissions to code that
requires them - the principle of "least
privilege"
• Copy-pasting, of course, increases the risk
of security flows (if the copied code is
flawed)
Advanced Java DayAdvanced Java Day
Designing and coding
with security in mind
• Sanitize exception messages from
sensitive information - often this results in
an unintended exposal of exploitable
information
• Let alone exception stacktraces … in many
cases they convey a wealth of information about
the system
Advanced Java Day
Thank you
Advanced Java DayAdvanced Java Day
References
• Java Security Overview (white paper)
http://www.oracle.com/technetwork/java/js-white-paper-
149932.pdf
• Java SE Platform Security Architecture Spec
http://docs.oracle.com/javase/7/docs/technotes/guides/sec
urity/spec/security-spec.doc.html
• Inside Java 2 Platform Security, 2nd edition
http://www.amazon.com/Inside-Java%C2%BF-Platform-
Security-Implementation/dp/0201787911
Advanced Java DayAdvanced Java Day
References
• Java Security, 2nd edition, Scott Oaks
http://shop.oreilly.com/product/9780596001575.do
• Securing Java, Gary McGraw, Ed Felden
http://www.securingjava.com
• Secure Coding Guidelines for Java SE
http://www.oracle.com/technetwork/java/seccodeguide
-139067.html#0
Advanced Java DayAdvanced Java Day
References
• Java 2 Network Security
http://www.amazon.com/JAVA-Network-Security-2nd-
Edition/dp/0130155926
• Java Security Documentation
http://docs.oracle.com/javase/8/docs/technotes/guides/
security/index.html
Advanced Java DayAdvanced Java Day
References
• Core Java Security: Class Loaders, Security
Managers and Encryption
http://www.informit.com/articles/article.aspx?p=118796
7
• Overview of Java Security Models
http://docs.oracle.com/cd/E12839_01/core.1111/e1004
3/introjps.htm#CHDCEJGH

Contenu connexe

Tendances

Java Security Manager Reloaded - Devoxx 2014
Java Security Manager Reloaded - Devoxx 2014Java Security Manager Reloaded - Devoxx 2014
Java Security Manager Reloaded - Devoxx 2014Josef Cacek
 
Java Security Manager Reloaded - jOpenSpace Lightning Talk
Java Security Manager Reloaded - jOpenSpace Lightning TalkJava Security Manager Reloaded - jOpenSpace Lightning Talk
Java Security Manager Reloaded - jOpenSpace Lightning TalkJosef Cacek
 
Asec r01-resting-on-your-laurels-will-get-you-pwned
Asec r01-resting-on-your-laurels-will-get-you-pwnedAsec r01-resting-on-your-laurels-will-get-you-pwned
Asec r01-resting-on-your-laurels-will-get-you-pwnedDinis Cruz
 
Unsafe Deserialization Attacks In Java and A New Approach To Protect The JVM ...
Unsafe Deserialization Attacks In Java and A New Approach To Protect The JVM ...Unsafe Deserialization Attacks In Java and A New Approach To Protect The JVM ...
Unsafe Deserialization Attacks In Java and A New Approach To Protect The JVM ...Apostolos Giannakidis
 
MyFaces CODI and JBoss Seam3 become Apache DeltaSpike
MyFaces CODI and JBoss Seam3 become Apache DeltaSpikeMyFaces CODI and JBoss Seam3 become Apache DeltaSpike
MyFaces CODI and JBoss Seam3 become Apache DeltaSpikeos890
 
Apache DeltaSpike
Apache DeltaSpikeApache DeltaSpike
Apache DeltaSpikeos890
 
Surviving the Java Deserialization Apocalypse // OWASP AppSecEU 2016
Surviving the Java Deserialization Apocalypse // OWASP AppSecEU 2016Surviving the Java Deserialization Apocalypse // OWASP AppSecEU 2016
Surviving the Java Deserialization Apocalypse // OWASP AppSecEU 2016Christian Schneider
 
MyFaces CODI Conversations
MyFaces CODI ConversationsMyFaces CODI Conversations
MyFaces CODI Conversationsos890
 
Maven basics (Android & IntelliJ)
Maven basics (Android & IntelliJ)Maven basics (Android & IntelliJ)
Maven basics (Android & IntelliJ)Hussain Mansoor
 
Make JSF more type-safe with CDI and MyFaces CODI
Make JSF more type-safe with CDI and MyFaces CODIMake JSF more type-safe with CDI and MyFaces CODI
Make JSF more type-safe with CDI and MyFaces CODIos890
 
MyFaces Universe at ApacheCon
MyFaces Universe at ApacheConMyFaces Universe at ApacheCon
MyFaces Universe at ApacheConos890
 
Introduction tomaven
Introduction tomavenIntroduction tomaven
Introduction tomavenManav Prasad
 
Java build tool_comparison
Java build tool_comparisonJava build tool_comparison
Java build tool_comparisonManav Prasad
 
Spring Framework - Spring Security
Spring Framework - Spring SecuritySpring Framework - Spring Security
Spring Framework - Spring SecurityDzmitry Naskou
 
Spring security 2017
Spring security 2017Spring security 2017
Spring security 2017Vortexbird
 
OpenWebBeans and DeltaSpike at ApacheCon
OpenWebBeans and DeltaSpike at ApacheConOpenWebBeans and DeltaSpike at ApacheCon
OpenWebBeans and DeltaSpike at ApacheConos890
 
State of Solr Security 2016: Presented by Ishan Chattopadhyaya, Lucidworks
State of Solr Security 2016: Presented by Ishan Chattopadhyaya, LucidworksState of Solr Security 2016: Presented by Ishan Chattopadhyaya, Lucidworks
State of Solr Security 2016: Presented by Ishan Chattopadhyaya, LucidworksLucidworks
 
[Wroclaw #2] Web Application Security Headers
[Wroclaw #2] Web Application Security Headers[Wroclaw #2] Web Application Security Headers
[Wroclaw #2] Web Application Security HeadersOWASP
 
Java Deserialization Vulnerabilities - The Forgotten Bug Class (DeepSec Edition)
Java Deserialization Vulnerabilities - The Forgotten Bug Class (DeepSec Edition)Java Deserialization Vulnerabilities - The Forgotten Bug Class (DeepSec Edition)
Java Deserialization Vulnerabilities - The Forgotten Bug Class (DeepSec Edition)CODE WHITE GmbH
 

Tendances (20)

Java Security Manager Reloaded - Devoxx 2014
Java Security Manager Reloaded - Devoxx 2014Java Security Manager Reloaded - Devoxx 2014
Java Security Manager Reloaded - Devoxx 2014
 
Java Security Manager Reloaded - jOpenSpace Lightning Talk
Java Security Manager Reloaded - jOpenSpace Lightning TalkJava Security Manager Reloaded - jOpenSpace Lightning Talk
Java Security Manager Reloaded - jOpenSpace Lightning Talk
 
Asec r01-resting-on-your-laurels-will-get-you-pwned
Asec r01-resting-on-your-laurels-will-get-you-pwnedAsec r01-resting-on-your-laurels-will-get-you-pwned
Asec r01-resting-on-your-laurels-will-get-you-pwned
 
Unsafe Deserialization Attacks In Java and A New Approach To Protect The JVM ...
Unsafe Deserialization Attacks In Java and A New Approach To Protect The JVM ...Unsafe Deserialization Attacks In Java and A New Approach To Protect The JVM ...
Unsafe Deserialization Attacks In Java and A New Approach To Protect The JVM ...
 
MyFaces CODI and JBoss Seam3 become Apache DeltaSpike
MyFaces CODI and JBoss Seam3 become Apache DeltaSpikeMyFaces CODI and JBoss Seam3 become Apache DeltaSpike
MyFaces CODI and JBoss Seam3 become Apache DeltaSpike
 
Apache DeltaSpike
Apache DeltaSpikeApache DeltaSpike
Apache DeltaSpike
 
Surviving the Java Deserialization Apocalypse // OWASP AppSecEU 2016
Surviving the Java Deserialization Apocalypse // OWASP AppSecEU 2016Surviving the Java Deserialization Apocalypse // OWASP AppSecEU 2016
Surviving the Java Deserialization Apocalypse // OWASP AppSecEU 2016
 
MyFaces CODI Conversations
MyFaces CODI ConversationsMyFaces CODI Conversations
MyFaces CODI Conversations
 
Maven basics (Android & IntelliJ)
Maven basics (Android & IntelliJ)Maven basics (Android & IntelliJ)
Maven basics (Android & IntelliJ)
 
Make JSF more type-safe with CDI and MyFaces CODI
Make JSF more type-safe with CDI and MyFaces CODIMake JSF more type-safe with CDI and MyFaces CODI
Make JSF more type-safe with CDI and MyFaces CODI
 
MyFaces Universe at ApacheCon
MyFaces Universe at ApacheConMyFaces Universe at ApacheCon
MyFaces Universe at ApacheCon
 
Introduction tomaven
Introduction tomavenIntroduction tomaven
Introduction tomaven
 
Java build tool_comparison
Java build tool_comparisonJava build tool_comparison
Java build tool_comparison
 
Spring Framework - Spring Security
Spring Framework - Spring SecuritySpring Framework - Spring Security
Spring Framework - Spring Security
 
Spring security 2017
Spring security 2017Spring security 2017
Spring security 2017
 
OpenWebBeans and DeltaSpike at ApacheCon
OpenWebBeans and DeltaSpike at ApacheConOpenWebBeans and DeltaSpike at ApacheCon
OpenWebBeans and DeltaSpike at ApacheCon
 
State of Solr Security 2016: Presented by Ishan Chattopadhyaya, Lucidworks
State of Solr Security 2016: Presented by Ishan Chattopadhyaya, LucidworksState of Solr Security 2016: Presented by Ishan Chattopadhyaya, Lucidworks
State of Solr Security 2016: Presented by Ishan Chattopadhyaya, Lucidworks
 
[Wroclaw #2] Web Application Security Headers
[Wroclaw #2] Web Application Security Headers[Wroclaw #2] Web Application Security Headers
[Wroclaw #2] Web Application Security Headers
 
Java Deserialization Vulnerabilities - The Forgotten Bug Class (DeepSec Edition)
Java Deserialization Vulnerabilities - The Forgotten Bug Class (DeepSec Edition)Java Deserialization Vulnerabilities - The Forgotten Bug Class (DeepSec Edition)
Java Deserialization Vulnerabilities - The Forgotten Bug Class (DeepSec Edition)
 
Drupal Security Hardening
Drupal Security HardeningDrupal Security Hardening
Drupal Security Hardening
 

En vedette

Lecture from javaday.bg by Nayden Gochev/ Ivan Ivanov and Mitia Alexandrov
Lecture from javaday.bg by Nayden Gochev/ Ivan Ivanov and Mitia Alexandrov Lecture from javaday.bg by Nayden Gochev/ Ivan Ivanov and Mitia Alexandrov
Lecture from javaday.bg by Nayden Gochev/ Ivan Ivanov and Mitia Alexandrov Nayden Gochev
 
JBoss Negotiation in AS7
JBoss Negotiation in AS7JBoss Negotiation in AS7
JBoss Negotiation in AS7Josef Cacek
 
Chapter 01 Introduction to Java by Tushar B Kute
Chapter 01 Introduction to Java by Tushar B KuteChapter 01 Introduction to Java by Tushar B Kute
Chapter 01 Introduction to Java by Tushar B KuteTushar B Kute
 
OWASP Secure Coding
OWASP Secure CodingOWASP Secure Coding
OWASP Secure Codingbilcorry
 
CIS14: Best Practices You Must Apply to Secure Your APIs
CIS14: Best Practices You Must Apply to Secure Your APIsCIS14: Best Practices You Must Apply to Secure Your APIs
CIS14: Best Practices You Must Apply to Secure Your APIsCloudIDSummit
 
Secure coding practices
Secure coding practicesSecure coding practices
Secure coding practicesScott Hurrey
 
Architecture diagram of jvm
Architecture diagram of jvmArchitecture diagram of jvm
Architecture diagram of jvmhome
 
JVM- Java Virtual Machine
JVM- Java Virtual MachineJVM- Java Virtual Machine
JVM- Java Virtual MachineManasvi Mehta
 
Introduction to airline reservation systems
Introduction to airline reservation systemsIntroduction to airline reservation systems
Introduction to airline reservation systemsJava and .NET Architect
 
Java essentials for hadoop
Java essentials for hadoopJava essentials for hadoop
Java essentials for hadoopSeo Gyansha
 

En vedette (15)

Lecture from javaday.bg by Nayden Gochev/ Ivan Ivanov and Mitia Alexandrov
Lecture from javaday.bg by Nayden Gochev/ Ivan Ivanov and Mitia Alexandrov Lecture from javaday.bg by Nayden Gochev/ Ivan Ivanov and Mitia Alexandrov
Lecture from javaday.bg by Nayden Gochev/ Ivan Ivanov and Mitia Alexandrov
 
JBoss Negotiation in AS7
JBoss Negotiation in AS7JBoss Negotiation in AS7
JBoss Negotiation in AS7
 
Jar signing
Jar signingJar signing
Jar signing
 
Chapter 01 Introduction to Java by Tushar B Kute
Chapter 01 Introduction to Java by Tushar B KuteChapter 01 Introduction to Java by Tushar B Kute
Chapter 01 Introduction to Java by Tushar B Kute
 
OWASP Secure Coding
OWASP Secure CodingOWASP Secure Coding
OWASP Secure Coding
 
CIS14: Best Practices You Must Apply to Secure Your APIs
CIS14: Best Practices You Must Apply to Secure Your APIsCIS14: Best Practices You Must Apply to Secure Your APIs
CIS14: Best Practices You Must Apply to Secure Your APIs
 
Secure coding practices
Secure coding practicesSecure coding practices
Secure coding practices
 
Javantura v4 - Security architecture of the Java platform - Martin Toshev
Javantura v4 - Security architecture of the Java platform - Martin ToshevJavantura v4 - Security architecture of the Java platform - Martin Toshev
Javantura v4 - Security architecture of the Java platform - Martin Toshev
 
Architecture diagram of jvm
Architecture diagram of jvmArchitecture diagram of jvm
Architecture diagram of jvm
 
JVM- Java Virtual Machine
JVM- Java Virtual MachineJVM- Java Virtual Machine
JVM- Java Virtual Machine
 
JVM
JVMJVM
JVM
 
Java-java virtual machine
Java-java virtual machineJava-java virtual machine
Java-java virtual machine
 
Java rmi
Java rmiJava rmi
Java rmi
 
Introduction to airline reservation systems
Introduction to airline reservation systemsIntroduction to airline reservation systems
Introduction to airline reservation systems
 
Java essentials for hadoop
Java essentials for hadoopJava essentials for hadoop
Java essentials for hadoop
 

Similaire à Security Architecture of the Java Platform (http://www.javaday.bg event - 14.06.2014, Sofia, Bulgaria)

Java Platform Security Architecture
Java Platform Security ArchitectureJava Platform Security Architecture
Java Platform Security ArchitectureRamesh Nagappan
 
Chapter three Java_security.ppt
Chapter three Java_security.pptChapter three Java_security.ppt
Chapter three Java_security.pptHaymanotTadese
 
Tollas Ferenc - Java security
Tollas Ferenc - Java securityTollas Ferenc - Java security
Tollas Ferenc - Java securityveszpremimeetup
 
java2days 2014: Attacking JavaEE Application Servers
java2days 2014: Attacking JavaEE Application Serversjava2days 2014: Attacking JavaEE Application Servers
java2days 2014: Attacking JavaEE Application ServersMartin Toshev
 
ADDRESSING TOMORROW'S SECURITY REQUIREMENTS IN ENTERPRISE APPLICATIONS
ADDRESSING TOMORROW'S SECURITY REQUIREMENTS IN ENTERPRISE APPLICATIONSADDRESSING TOMORROW'S SECURITY REQUIREMENTS IN ENTERPRISE APPLICATIONS
ADDRESSING TOMORROW'S SECURITY REQUIREMENTS IN ENTERPRISE APPLICATIONSelliando dias
 
Windows azuretomcat mysql
Windows azuretomcat mysqlWindows azuretomcat mysql
Windows azuretomcat mysqlGuada Casuso
 
Tomcat and MySQL in Windows Azure
Tomcat and MySQL in Windows Azure Tomcat and MySQL in Windows Azure
Tomcat and MySQL in Windows Azure Guada Casuso
 
Building Secure OSGi Applications
Building Secure OSGi ApplicationsBuilding Secure OSGi Applications
Building Secure OSGi ApplicationsMarcel Offermans
 
From java to android a security analysis
From java to android  a security analysisFrom java to android  a security analysis
From java to android a security analysisPragati Rai
 
Introduction to java
Introduction to java Introduction to java
Introduction to java Java Lover
 
Byte code manipulation and instrumentalization in Java
Byte code manipulation and instrumentalization in JavaByte code manipulation and instrumentalization in Java
Byte code manipulation and instrumentalization in JavaAlex Moskvin
 
Weblogic Cluster Security
Weblogic Cluster SecurityWeblogic Cluster Security
Weblogic Cluster SecurityAditya Bhuyan
 
1 java programming- introduction
1  java programming- introduction1  java programming- introduction
1 java programming- introductionjyoti_lakhani
 
Sandboxing (Distributed computing)
Sandboxing (Distributed computing)Sandboxing (Distributed computing)
Sandboxing (Distributed computing)Sri Prasanna
 

Similaire à Security Architecture of the Java Platform (http://www.javaday.bg event - 14.06.2014, Sofia, Bulgaria) (20)

Java Platform Security Architecture
Java Platform Security ArchitectureJava Platform Security Architecture
Java Platform Security Architecture
 
Chapter three Java_security.ppt
Chapter three Java_security.pptChapter three Java_security.ppt
Chapter three Java_security.ppt
 
Tollas Ferenc - Java security
Tollas Ferenc - Java securityTollas Ferenc - Java security
Tollas Ferenc - Java security
 
java2days 2014: Attacking JavaEE Application Servers
java2days 2014: Attacking JavaEE Application Serversjava2days 2014: Attacking JavaEE Application Servers
java2days 2014: Attacking JavaEE Application Servers
 
ADDRESSING TOMORROW'S SECURITY REQUIREMENTS IN ENTERPRISE APPLICATIONS
ADDRESSING TOMORROW'S SECURITY REQUIREMENTS IN ENTERPRISE APPLICATIONSADDRESSING TOMORROW'S SECURITY REQUIREMENTS IN ENTERPRISE APPLICATIONS
ADDRESSING TOMORROW'S SECURITY REQUIREMENTS IN ENTERPRISE APPLICATIONS
 
Windows azuretomcat mysql
Windows azuretomcat mysqlWindows azuretomcat mysql
Windows azuretomcat mysql
 
Tomcat and MySQL in Windows Azure
Tomcat and MySQL in Windows Azure Tomcat and MySQL in Windows Azure
Tomcat and MySQL in Windows Azure
 
Building Secure OSGi Applications
Building Secure OSGi ApplicationsBuilding Secure OSGi Applications
Building Secure OSGi Applications
 
From java to android a security analysis
From java to android  a security analysisFrom java to android  a security analysis
From java to android a security analysis
 
Security in Java
Security in JavaSecurity in Java
Security in Java
 
Introduction to java
Introduction to java Introduction to java
Introduction to java
 
Java programming and security
Java programming and securityJava programming and security
Java programming and security
 
Class loaders
Class loadersClass loaders
Class loaders
 
Byte code manipulation and instrumentalization in Java
Byte code manipulation and instrumentalization in JavaByte code manipulation and instrumentalization in Java
Byte code manipulation and instrumentalization in Java
 
Weblogic security
Weblogic securityWeblogic security
Weblogic security
 
Weblogic Cluster Security
Weblogic Cluster SecurityWeblogic Cluster Security
Weblogic Cluster Security
 
1 java programming- introduction
1  java programming- introduction1  java programming- introduction
1 java programming- introduction
 
Java Security
Java SecurityJava Security
Java Security
 
Sandboxing (Distributed computing)
Sandboxing (Distributed computing)Sandboxing (Distributed computing)
Sandboxing (Distributed computing)
 
CS8392 OOP
CS8392 OOPCS8392 OOP
CS8392 OOP
 

Plus de Martin Toshev

Building highly scalable data pipelines with Apache Spark
Building highly scalable data pipelines with Apache SparkBuilding highly scalable data pipelines with Apache Spark
Building highly scalable data pipelines with Apache SparkMartin Toshev
 
Big data processing with Apache Spark and Oracle Database
Big data processing with Apache Spark and Oracle DatabaseBig data processing with Apache Spark and Oracle Database
Big data processing with Apache Spark and Oracle DatabaseMartin Toshev
 
Semantic Technology In Oracle Database 12c
Semantic Technology In Oracle Database 12cSemantic Technology In Oracle Database 12c
Semantic Technology In Oracle Database 12cMartin Toshev
 
Practical security In a modular world
Practical security In a modular worldPractical security In a modular world
Practical security In a modular worldMartin Toshev
 
Java 9 Security Enhancements in Practice
Java 9 Security Enhancements in PracticeJava 9 Security Enhancements in Practice
Java 9 Security Enhancements in PracticeMartin Toshev
 
Writing Stored Procedures in Oracle RDBMS
Writing Stored Procedures in Oracle RDBMSWriting Stored Procedures in Oracle RDBMS
Writing Stored Procedures in Oracle RDBMSMartin Toshev
 
RxJS vs RxJava: Intro
RxJS vs RxJava: IntroRxJS vs RxJava: Intro
RxJS vs RxJava: IntroMartin Toshev
 
Writing Stored Procedures with Oracle Database 12c
Writing Stored Procedures with Oracle Database 12cWriting Stored Procedures with Oracle Database 12c
Writing Stored Procedures with Oracle Database 12cMartin Toshev
 
Concurrency Utilities in Java 8
Concurrency Utilities in Java 8Concurrency Utilities in Java 8
Concurrency Utilities in Java 8Martin Toshev
 
The RabbitMQ Message Broker
The RabbitMQ Message BrokerThe RabbitMQ Message Broker
The RabbitMQ Message BrokerMartin Toshev
 
Modularity of The Java Platform Javaday (http://javaday.org.ua/)
Modularity of The Java Platform Javaday (http://javaday.org.ua/)Modularity of The Java Platform Javaday (http://javaday.org.ua/)
Modularity of The Java Platform Javaday (http://javaday.org.ua/)Martin Toshev
 
Writing Java Stored Procedures in Oracle 12c
Writing Java Stored Procedures in Oracle 12cWriting Java Stored Procedures in Oracle 12c
Writing Java Stored Procedures in Oracle 12cMartin Toshev
 
KDB database (EPAM tech talks, Sofia, April, 2015)
KDB database (EPAM tech talks, Sofia, April, 2015)KDB database (EPAM tech talks, Sofia, April, 2015)
KDB database (EPAM tech talks, Sofia, April, 2015)Martin Toshev
 
Eclipse plug in development
Eclipse plug in developmentEclipse plug in development
Eclipse plug in developmentMartin Toshev
 

Plus de Martin Toshev (20)

Building highly scalable data pipelines with Apache Spark
Building highly scalable data pipelines with Apache SparkBuilding highly scalable data pipelines with Apache Spark
Building highly scalable data pipelines with Apache Spark
 
Big data processing with Apache Spark and Oracle Database
Big data processing with Apache Spark and Oracle DatabaseBig data processing with Apache Spark and Oracle Database
Big data processing with Apache Spark and Oracle Database
 
Jdk 10 sneak peek
Jdk 10 sneak peekJdk 10 sneak peek
Jdk 10 sneak peek
 
Semantic Technology In Oracle Database 12c
Semantic Technology In Oracle Database 12cSemantic Technology In Oracle Database 12c
Semantic Technology In Oracle Database 12c
 
Practical security In a modular world
Practical security In a modular worldPractical security In a modular world
Practical security In a modular world
 
Java 9 Security Enhancements in Practice
Java 9 Security Enhancements in PracticeJava 9 Security Enhancements in Practice
Java 9 Security Enhancements in Practice
 
Java 9 sneak peek
Java 9 sneak peekJava 9 sneak peek
Java 9 sneak peek
 
Writing Stored Procedures in Oracle RDBMS
Writing Stored Procedures in Oracle RDBMSWriting Stored Procedures in Oracle RDBMS
Writing Stored Procedures in Oracle RDBMS
 
Spring RabbitMQ
Spring RabbitMQSpring RabbitMQ
Spring RabbitMQ
 
JVM++: The Graal VM
JVM++: The Graal VMJVM++: The Graal VM
JVM++: The Graal VM
 
RxJS vs RxJava: Intro
RxJS vs RxJava: IntroRxJS vs RxJava: Intro
RxJS vs RxJava: Intro
 
Spring RabbitMQ
Spring RabbitMQSpring RabbitMQ
Spring RabbitMQ
 
Writing Stored Procedures with Oracle Database 12c
Writing Stored Procedures with Oracle Database 12cWriting Stored Procedures with Oracle Database 12c
Writing Stored Procedures with Oracle Database 12c
 
Concurrency Utilities in Java 8
Concurrency Utilities in Java 8Concurrency Utilities in Java 8
Concurrency Utilities in Java 8
 
The RabbitMQ Message Broker
The RabbitMQ Message BrokerThe RabbitMQ Message Broker
The RabbitMQ Message Broker
 
Modularity of The Java Platform Javaday (http://javaday.org.ua/)
Modularity of The Java Platform Javaday (http://javaday.org.ua/)Modularity of The Java Platform Javaday (http://javaday.org.ua/)
Modularity of The Java Platform Javaday (http://javaday.org.ua/)
 
Writing Java Stored Procedures in Oracle 12c
Writing Java Stored Procedures in Oracle 12cWriting Java Stored Procedures in Oracle 12c
Writing Java Stored Procedures in Oracle 12c
 
KDB database (EPAM tech talks, Sofia, April, 2015)
KDB database (EPAM tech talks, Sofia, April, 2015)KDB database (EPAM tech talks, Sofia, April, 2015)
KDB database (EPAM tech talks, Sofia, April, 2015)
 
Eclipse plug in development
Eclipse plug in developmentEclipse plug in development
Eclipse plug in development
 
Modular Java
Modular JavaModular Java
Modular Java
 

Dernier

Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?Igalia
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 

Dernier (20)

Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 

Security Architecture of the Java Platform (http://www.javaday.bg event - 14.06.2014, Sofia, Bulgaria)

  • 1. Advanced Java Day Security Architecture of the Java Platform МАРТИН TОШЕВ
  • 2. Advanced Java Day BG JUG mailing list: https://groups.google.com/foru m/#!forum/bg-jug
  • 3. Advanced Java DayAdvanced Java Day Agenda • Evolution of the Java security model • Outside the sandbox - APIs for secure coding • Designing and coding with security in mind
  • 4. Advanced Java Day Evolution of the Java security model
  • 5. Advanced Java DayAdvanced Java Day Evolution of the Java security model • Traditionally - companies protect they assets using strict physical and network access policies • Tools such as anti-virus software, firewalls, IPS/IDS systems facilitate this approach
  • 6. Advanced Java DayAdvanced Java Day Evolution of the Java security model • With the introduction of various technologies for loading and executing code on the client machine from the browser (such as Applets) - a new range of concerns emerge related to client security – this is when the Java security sandbox starts to evolve …
  • 7. Advanced Java DayAdvanced Java Day Evolution of the Java security model • The goal of the Java security sandbox is to allow untrusted code from applets to be executed in a trusted environment such as the user's browser
  • 8. Advanced Java DayAdvanced Java Day Evolution of the Java security model • JDK 1.0 (when it all started …) – the original sandbox model was introduced Applet (untrusted) System code (trusted) JVM Browser http://javaday.bg/demoapplet
  • 9. Advanced Java DayAdvanced Java Day Evolution of the Java security model • Code executed by the JVM is divided in two domains – trusted and untrusted • Strict restriction are applied by default on the security model of applets such as denial to read/write data from disk, connect to the network and so on
  • 10. Advanced Java DayAdvanced Java Day Evolution of the Java security model • JDK 1.1 (gaining trust …) – applet signing introduced Applet (untrusted) System code (trusted) JVM Browser http://javaday.bg/demoapplet Signed Applet (trusted) http://javaday.bg/trustedapplet
  • 11. Advanced Java DayAdvanced Java Day Evolution of the Java security model • Trusted local code and untrusted remote code from applets restricted to a predefined set of operations OR signed applet code that is trusted
  • 12. Advanced Java DayAdvanced Java Day Evolution of the Java security model • Steps needed to sign and run an applet: – Compile the applet – Create a JAR file for the applet – Generate a pair of public/private keys – Sign the applet JAR with the private key – Export a certificate for the public key – Import the Certificate as a Trusted Certificate – Create the policy file – Load and run the applet
  • 13. Advanced Java DayAdvanced Java Day Evolution of the Java security model • JDK 1.2 (gaining more trust …) – fine- grained access control Applet System code JVM Browser http://javaday.bg/demoapplet grant codeBase http://javaday.bg/demoapplet { permission java.io.FilePermissions “C:Windows” “delete” } security.policy SecurityManager.checkPermission(…) AccessController.checkPermission(…)
  • 14. Advanced Java DayAdvanced Java Day Evolution of the Java security model • Since the security model is code-centric - additional access control decisions are specified in a security policy • No more notion of trusted and untrusted code
  • 15. Advanced Java DayAdvanced Java Day Evolution of the Java security model • The notion of protection domain introduced – determined by the security policy • Two types of protection domains – system and application
  • 16. Advanced Java DayAdvanced Java Day Evolution of the Java security model • The protection domain is set during classloading and contains the code source and the list of permissions for the class applet.getClass().getProtectionDomain();
  • 17. Advanced Java DayAdvanced Java Day Evolution of the Java security model • One permission can imply another permission java.io.FilePermissions “C:Windows” “delete” implies java.io.FilePermissions “C:Windowssystem32” “delete”
  • 18. Advanced Java DayAdvanced Java Day Evolution of the Java security model • One code source can imply another code source codeBase http://javaday.bg/ implies codeBase http://javaday.bg/demoapplet
  • 19. Advanced Java DayAdvanced Java Day Evolution of the Java security model • Since an execution thread may pass through classes loaded by different classloaders (and hence – have different protection domains) the following rule of thumb applies: The permission set of an execution thread is considered to be the intersection of the permissions of all protection domains traversed by the execution thread
  • 20. Advanced Java DayAdvanced Java Day Evolution of the Java security model • JDK 1.3, 1,4 (what about entities running the code … ?) – JAAS Applet System code JVM Browser http://javaday.bg/demoapplet grant principal javax.security.auth.x500.X500Principal "cn=Tom" { permission java.io.FilePermissions “C:Windows” “delete” } security.policy
  • 21. Advanced Java DayAdvanced Java Day Evolution of the Java security model • JAAS (Java Authentication and Authorization Service) extends the security model with role-based permissions • The protection domain of a class now may contain not only the code source and the permissions but a list of principals
  • 22. Advanced Java DayAdvanced Java Day Evolution of the Java security model • The authentication component of JAAS is independent of the security sandbox in Java and hence is typically used in more wider context (such as j2ee app servers) • The authorization component is the one that extends the Java security policy
  • 23. Advanced Java DayAdvanced Java Day Evolution of the Java security model • Core classes of JAAS: – javax.security.auth.Subject - an authenticated subject – java.security.Principal - identifying characteristic of a subject – javax.security.auth.spi.LoginModule - interface for implementors of login (PAM) modules – javax.security.auth.login.LoginContext - creates objects used for authentication
  • 24. Advanced Java DayAdvanced Java Day Evolution of the Java security model • Up to JDK 1.4 the following is a typical flow for permission checking: 1) upon system startup a security policy is set and a security manager is installed Policy.setPolicy(…) System.setSecurityManager(…)
  • 25. Advanced Java DayAdvanced Java Day Evolution of the Java security model • Up to JDK 1.4 the following is a typical flow for permission checking: 2) during classloading (e.g. of a remote applet) bytecode verification is done and the protection domain is set for the current classloader (along with the code source, the set of permissions and the set of JAAS principals)
  • 26. Advanced Java DayAdvanced Java Day Evolution of the Java security model • Up to JDK 1.4 the following is a typical flow for permission checking: 3) when system code is invoked from the remote code the SecurityManager is used to check against the intersection of protection domains based on the chain of threads and their call stacks
  • 27. Advanced Java DayAdvanced Java Day Evolution of the Java security model • Up to JDK 1.4 the following is a typical flow for permission checking: SocketPermission permission = new SocketPermission("javaday.bg:8000- 9000","connect,accept"); SecurityManager sm = System.getSecurityManager(); if (sm != null) sm.checkPermission(permission);
  • 28. Advanced Java DayAdvanced Java Day Evolution of the Java security model • Up to JDK 1.4 the following is a typical flow for permission checking: 4) application code can also do permission checking against remote code using a SecurityManager or an AccessController
  • 29. Advanced Java DayAdvanced Java Day Evolution of the Java security model • Up to JDK 1.4 the following is a typical flow for permission checking: SocketPermission permission = new SocketPermission("javaday.bg:8000-9000", "connect,accept"); AccessController.checkPermission(permission)
  • 30. Advanced Java DayAdvanced Java Day Evolution of the Java security model • Up to JDK 1.4 the following is a typical flow for permission checking: 5) application code can also do permission checking with all permissions of the calling domain or a particular JAAS subject AccessController.doPrivileged(…) Subject.doAs(…) Subject.doAsPrivileged(…)
  • 31. Advanced Java DayAdvanced Java Day Evolution of the Java security model • The security model defined by java.lang.SecurityManager is customizable • For example: Oracle JVM uses a custom SecurityManager with additional permission classes where the code source is a database schema (containing e.g. Java stored procedures)
  • 32. Advanced Java DayAdvanced Java Day Evolution of the Java security model • JDK 1.5, 1.6 (enhancing the model …) – new additions to the sandbox model (e.g. LDAP support for JAAS)
  • 33. Advanced Java DayAdvanced Java Day Evolution of the Java security model • JDK 1.7, 1.8 (further enhancing the model …) – enhancements to the sandbox model (e.g. AccessController.doPrivileged() for checking against a subset of permissions)
  • 34. Advanced Java DayAdvanced Java Day Evolution of the Java security model • JDK 1.9 and beyond … (applying the model to modules …) application module system module 1 JVM Browser http://javaday.bg/appmodule security.policy system module 2
  • 35. Advanced Java DayAdvanced Java Day Evolution of the Java security model • By modules we understand modules in JDK as defined by project Jigsaw • Modules must conform to the same security model as applets – moreover each module is loaded by a different classloader – hence classes in different modules must have different protection domains
  • 36. Advanced Java DayAdvanced Java Day Evolution of the Java security model • Modularization of the JDK system classes allows further to define fine-grained access control permissions for classes in the system domain • This is not currently allowed due to the monolithic nature of the JDK
  • 37. Advanced Java Day Outside the sandbox - APIs for secure coding
  • 38. Advanced Java DayAdvanced Java Day Outside the sandbox - APIs for secure coding • The security sandbox defines a strict model for execution of remote code in the JVM • The other side of the coin are the security APIs that provide utilities for implementing the different aspects of application security …
  • 39. Advanced Java DayAdvanced Java Day Outside the sandbox - APIs for secure coding • The additional set of APIs includes: – JCA (Java Cryptography Architecture) – PKI (Public Key Infrastructure) utilities – JSSE (Java Secure Socket Extension) – Java GSS API (Java Generic Security Services) – Java SASL API (Java Simple Authentication and Security Layer)
  • 40. Advanced Java DayAdvanced Java Day Outside the sandbox - APIs for secure coding • JCA provides utilities for: – creating digital signatures – creating message digests – using cryptographic ciphers (symetric/asymetric, block/stream) – using different other types of cryptographic services and algorithms
  • 41. Advanced Java DayAdvanced Java Day Outside the sandbox - APIs for secure coding • JCA has a pluggable architecture • JCA is independent from particular cryptographic algorithms • JCA continues to evolve (especially by providing stronger cryptographic algorithms)
  • 42. Advanced Java DayAdvanced Java Day Outside the sandbox - APIs for secure coding • PKI utilities provide means for working with: – certificates – certificate revocation lists (CRL) – OCSP (Online Certificate Status Protocol) – key stores and trust stores (also based on the PKCS - public-key cryptography standards)
  • 43. Advanced Java DayAdvanced Java Day Outside the sandbox - APIs for secure coding • PKI certificate revocation check (revision): • PKI utilities continue to evolve (especially in providing more support for managing certificates and keys) certificate authorityrevocation checking OCSP CRL certificate certificate
  • 44. Advanced Java DayAdvanced Java Day Outside the sandbox - APIs for secure coding • JSSE provides an implementation of the TSL/SSL sockets for working with remote communication • JSSE continues to evolve (especially in the support for additional features such as Server Name Identication)
  • 45. Advanced Java DayAdvanced Java Day Outside the sandbox - APIs for secure coding • Java GSS API provides an alternative of JSSE for secure communication • Java GSS API is a framework for providing token-based security services that is independent of the underlying protocols
  • 46. Advanced Java DayAdvanced Java Day Outside the sandbox - APIs for secure coding • Java GSS API can be used along with JAAS for authentication purposes • Java GSS API continues to evolve (especially in the support for Kerberos authentication)
  • 47. Advanced Java DayAdvanced Java Day Outside the sandbox - APIs for secure coding • Java SASL defines a protocol for exchange of authentication data • Java SASL is a framework where external providers give concrete semantics to the authentication data being exchanged
  • 48. Advanced Java DayAdvanced Java Day Outside the sandbox - APIs for secure coding • Java SASL continues to evolve (especially with support for additional and enhanced properties for exchanging authentication data)
  • 49. Advanced Java Day Designing and coding with security in mind
  • 50. Advanced Java DayAdvanced Java Day Designing and coding with security in mind • First of all - follow programing guidelines and best practices - most are not bound to the Java programming language (input validation, error handling, type safety, access modifiers, resource cleanup, prepared SQL queries and whatever you can think of …)
  • 51. Advanced Java DayAdvanced Java Day Designing and coding with security in mind • Respect the SecurityManager - designlibraries so that they work in environments with installed SecurityManager • Example: GSON library does not respect the SecurityManager and cannot be used without additional reflective permissions in some scenarios
  • 52. Advanced Java DayAdvanced Java Day Designing and coding with security in mind • Grant minimal permissions to code that requires them - the principle of "least privilege" • Copy-pasting, of course, increases the risk of security flows (if the copied code is flawed)
  • 53. Advanced Java DayAdvanced Java Day Designing and coding with security in mind • Sanitize exception messages from sensitive information - often this results in an unintended exposal of exploitable information • Let alone exception stacktraces … in many cases they convey a wealth of information about the system
  • 55. Advanced Java DayAdvanced Java Day References • Java Security Overview (white paper) http://www.oracle.com/technetwork/java/js-white-paper- 149932.pdf • Java SE Platform Security Architecture Spec http://docs.oracle.com/javase/7/docs/technotes/guides/sec urity/spec/security-spec.doc.html • Inside Java 2 Platform Security, 2nd edition http://www.amazon.com/Inside-Java%C2%BF-Platform- Security-Implementation/dp/0201787911
  • 56. Advanced Java DayAdvanced Java Day References • Java Security, 2nd edition, Scott Oaks http://shop.oreilly.com/product/9780596001575.do • Securing Java, Gary McGraw, Ed Felden http://www.securingjava.com • Secure Coding Guidelines for Java SE http://www.oracle.com/technetwork/java/seccodeguide -139067.html#0
  • 57. Advanced Java DayAdvanced Java Day References • Java 2 Network Security http://www.amazon.com/JAVA-Network-Security-2nd- Edition/dp/0130155926 • Java Security Documentation http://docs.oracle.com/javase/8/docs/technotes/guides/ security/index.html
  • 58. Advanced Java DayAdvanced Java Day References • Core Java Security: Class Loaders, Security Managers and Encryption http://www.informit.com/articles/article.aspx?p=118796 7 • Overview of Java Security Models http://docs.oracle.com/cd/E12839_01/core.1111/e1004 3/introjps.htm#CHDCEJGH

Notes de l'éditeur

  1. The code source on the other hand contains the URL location, the list of signers and the list of certificates
  2. The code source on the other hand contains the URL location, the list of signers and the list of certificates
  3. The code source on the other hand contains the URL location, the list of signers and the list of certificates
  4. The code source on the other hand contains the URL location, the list of signers and the list of certificates
  5. The code source on the other hand contains the URL location, the list of signers and the list of certificates
  6. A typical scenario – in a single multiuser operating system we may have multiple users accessing the same applet from the browser – we may want to define permissions based on the currently logged-in user by providing integration with e.g. Kerberos (in case of a Windows OS)
  7. An AccessControlContext keeps the list of protection domains for the current thread
  8. An AccessControlContext keeps the list of protection domains for the current thread
  9. There are two main differences in using a SecurityManager and an AccessController: The SecurityManager needs to be installed while AccessController only provides static methods The SecurityManager can be customized while AccessController provides additional algorithms that can be used over the default security model
  10. There are two main differences in using a SecurityManager and an AccessController: The SecurityManager needs to be installed while AccessController only provides static methods The SecurityManager can be customized while AccessController provides additional algorithms that can be used over the default security model
  11. Calling code with a different JAAS subject is similar to the Unix setuid utility