SlideShare uma empresa Scribd logo
1 de 80
Baixar para ler offline
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.1
Finally,
EE Security API JSR 375
Alex Kosowski
JSR 375 Specification Lead
WebLogic Server Security
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.3
Safe Harbor Statement
The following is intended to outline our general product direction. It is
intended for information purposes only, and may not be incorporated into
any contract. It is not a commitment to deliver any material, code, or
functionality, and should not be relied upon in making purchasing
decisions. The development, release, and timing of any features or
functionality described for Oracle’s products remains at the sole
discretion of Oracle.
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.4
Agenda
Â§ï‚§â€Ż Motivations
Â§ï‚§â€Ż A New JSR
Â§ï‚§â€Ż Ideas
Â§ï‚§â€Ż Get Involved
Â§ï‚§â€Ż Q & A
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.5
Agenda
Â§ï‚§â€Ż Motivations
Â§ï‚§â€Ż A New JSR
Â§ï‚§â€Ż Ideas
Â§ï‚§â€Ż Get Involved
Â§ï‚§â€Ż Q & A
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.6
Why a Java EE Security API JSR?
Â§ï‚§â€Ż EE 8 survey results
Â§ï‚§â€Ż 4500 total responses
Â§ï‚§â€Ż Priorities Pie Chart
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.7
What’s wrong with Java EE Security?
"The ultimate goal is to have basic security working without the need of
any kind of vendor specific configuration, deployment descriptors, or
whatever. ” – Arjan Tijms
“[The EE security] model is problematic in cloud/PaaS environments
where developers do not necessarily have easy access to non-standard
vendor runtime features and a self-contained application is much easier
to manage.” – Reza Rahman
The community says

Copyright © 2015, Oracle and/or its affiliates. All rights reserved.8
What’s wrong with Java EE Security?
Â§ï‚§â€Ż Java EE Security viewed as not portable, abstract/confusing,
antiquated
Â§ï‚§â€Ż Doesn’t fit cloud app developer paradigm: requires app server
configuration
Â§ï‚§â€Ż Losing value to non-standard 3rd Party Frameworks
less likely to
move back to Java EE when requirements increase
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.9
What to do?
Â§ï‚§â€Ż Plug the portability holes
Â§ï‚§â€Ż Modernize
–  Context Dependency Injection (CDI)
Â§ï‚§â€Ż Intercept at Access Enforcement Points: POJO methods
–  Expression Language (EL)
Â§ï‚§â€Ż Enable Access Enforcement Points with complex rules
Â§ï‚§â€Ż App Developer Friendly
–  Common security configurations not requiring server changes
–  Annotation defaults not requiring XML
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.10
Agenda
Â§ï‚§â€Ż Motivations
Â§ï‚§â€Ż A New JSR
Â§ï‚§â€Ż Ideas
Â§ï‚§â€Ż Get Involved
Â§ï‚§â€Ż Q & A
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.11
JSR 375 History
Â§ï‚§â€Ż August 2014: First proposed to Oracle Java EE Architects
Â§ï‚§â€Ż December 2014: Approved by JCP
Â§ï‚§â€Ż Expert Group nominations:
–  EE API veterans: many JSRs, many years struggling with Security API
–  3rd party security framework creators/developers
–  EE platform security implementers
Â§ï‚§â€Ż March 2015: Expert Group started discussions
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.12
JSR 375 – Expert Group
Name Representing
Adam Bien Individual
David Blevins Tomitribe
Rudy De Busscher Individual
Ivar Grimstad Individual
Les Hazlewood Stormpath, Inc.
Will Hopkins Oracle
Werner Keil Individual
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.13
JSR 375 – Expert Group
Name Representing
Matt Konda Jemurai
Alex Kosowski Oracle
Darran Lofthouse RedHat
Jean-Louis Monteiro Tomitribe
Ajay Reddy IBM
Pedro Igor Silva RedHat
Arjan Tijms ZEEF
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.14
JSR 375 History
Â§ï‚§â€Ż In first month, expert group had an EXPLOSION of activity
–  Lot of Brainstorming!
–  237 messages on EG mailing list
–  81 commits in Github playgrounds for examples and proposals
–  24 JIRA issues
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.15
Agenda
Â§ï‚§â€Ż Motivations
Â§ï‚§â€Ż A New JSR
Â§ï‚§â€Ż Ideas
Â§ï‚§â€Ż Get Involved
Â§ï‚§â€Ż Q & A
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.16
Ideas
Â§ï‚§â€Ż Terminology
Â§ï‚§â€Ż API for Authentication Mechanism
Â§ï‚§â€Ż API for Identity Store
Â§ï‚§â€Ż API for Password Aliasing
Â§ï‚§â€Ż API for Role/Permission Assignment
Â§ï‚§â€Ż API for Security Context
Â§ï‚§â€Ż API for Authorization Interceptors
To modernize, standardize, simplify
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.17
Ideas
To modernize, standardize, simplify
Identity Store
Authentication
Mechanism
Security Context
Authorization
Interceptors
Role/Permission
Assignment
Password Aliasing
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.18
Ideas
Â§ï‚§â€Ż Terminology
Â§ï‚§â€Ż API for Authentication Mechanism
Â§ï‚§â€Ż API for Identity Store
Â§ï‚§â€Ż API for Password Aliasing
Â§ï‚§â€Ż API for Role/Permission Assignment
Â§ï‚§â€Ż API for Security Context
Â§ï‚§â€Ż API for Authorization Interceptors
To modernize, standardize, simplify
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.19
Ideas - Terminology
Â§ï‚§â€Ż EG discussions revealed inconsistency in security API terms
Â§ï‚§â€Ż Different EE containers have different names for the same concepts
Â§ï‚§â€Ż When “something” gets authenticated, is that something a

–  A User? (e.g. HttpServletRequest.getUserPrincipal)
–  A Caller? (e.g. EJBContext.getCallerPrincipal)
Â§ï‚§â€Ż What is a group?
–  A group of users?
–  A permission
–  Vs Role?
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.20
Ideas - Terminology
Â§ï‚§â€Ż What is that “something” where identities are stored?
–  security provider (WebLogic)
–  realm (Tomcat, some hints in Servlet spec)
–  (auth) repository
–  (auth) store
–  login module (JAAS)
–  identity manager (Undertow)
–  authenticator (Resin, OmniSecurity, Seam Security)
–  authentication provider (Spring Security)
–  identity provider
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.21
Ideas
Â§ï‚§â€Ż Terminology
Â§ï‚§â€Ż API for Authentication Mechanism
Â§ï‚§â€Ż API for Identity Store
Â§ï‚§â€Ż API for Password Aliasing
Â§ï‚§â€Ż API for Role/Permission Assignment
Â§ï‚§â€Ż API for Security Context
Â§ï‚§â€Ż API for Authorization Interceptors
To modernize, standardize, simplify
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.22
Use Case
Â§ï‚§â€Ż Application manages its own users and groups
Â§ï‚§â€Ż Application needs to authenticate users in order to assign Roles
Â§ï‚§â€Ż Application authenticates based on application-domain models
Â§ï‚§â€Ż Application needs to use an authentication method not supported on
the server, like OpenID Connect
Â§ï‚§â€Ż Developer wants to use portable EE Authentication standard
API for Authentication Mechanism
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.23
Current Solutions
Â§ï‚§â€Ż Proprietary server support
Â§ï‚§â€Ż 3rd party security frameworks provide authentication
Â§ï‚§â€Ż JASPIC: Java Authentication Service Provider Interface for Containers
API for Authentication Mechanism
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.24
JASPIC
Â§ï‚§â€Ż Java Authentication Service Provider Interface for Containers
Â§ï‚§â€Ż JSR 196, Maintenance Release 1.1, in 2013
Â§ï‚§â€Ż Standardized, portable, thin, low-level authentication framework
Â§ï‚§â€Ż Extensible from within an application
Â§ï‚§â€Ż Integrates with the container to build an authenticated Subject
Â§ï‚§â€Ż Implement any authentication method
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.25
JASPIC Server Auth Module
public interface ServerAuthModule {
public void initialize(MessagePolicy requestPolicy,
MessagePolicy responsePolicy, CallbackHandler handler,
Map options) throws AuthException;
public AuthStatus validateRequest(MessageInfo messageInfo,
Subject clientSubject, Subject serviceSubject);
public Class<?>[] getSupportedMessageTypes();
public AuthStatus secureResponse(MessageInfo messageInfo,
Subject serviceSubject);
public void cleanSubject(MessageInfo messageInfo, Subject subject);
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.26
JASPIC Per-Application Installation
ServletContextListener
AuthConfigFactory
AuthConfigProvider
ServerAuthConfig
ServerAuthContext
ServerAuthModule
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.27
Ideas – Simple ServerAuthModule Installation
ServletContextListener
AuthConfigFactory
AuthConfigProvider
ServerAuthConfig
ServerAuthContext
ServerAuthModule
ServletContextListener
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.28
Ideas – Simple ServerAuthModule Installation
@WebListener
public class SamRegistrationListener implements ServletContextListener {
@Override
public void contextInitialized(ServletContextEvent sce) {
Jaspic.registerServerAuthModule(new TokenAuthModule(),
sce.getServletContext());
}
@Override
public void contextDestroyed(ServletContextEvent sce) {
}
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.29
Ideas – Simple ServerAuthModule Installation
@Authenticator("org.acme.TokenAuthModule")
@WebServlet("/SimpleServlet")
@ServletSecurity(@HttpConstraint(rolesAllowed = {"manager"}))
public class SimpleServlet extends HttpServlet {
@Override
protected void doGet(HttpServletRequest request,
HttpServletResponse response)
throws ServletException, IOException {
response.getWriter().print("my GET");
}
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.30
Ideas – Profile Specific Helper Classes
public class BasicServerAuthModule implements ServerAuthModule {
public void initialize(
) throws AuthException { 
 }
public Class<?>[] getSupportedMessageTypes() { 
 }
public AuthStatus secureResponse(MessageInfo messageInfo,
Subject serviceSubject) throws AuthException { 
 }
public void cleanSubject(MessageInfo messageInfo, Subject subject)
throws AuthException { 
 }
public AuthStatus validateRequest(MessageInfo messageInfo,
Subject clientSubject, Subject serviceSubject) throws AuthException {
final HttpServletRequest request =
(HttpServletRequest) messageInfo.getRequestMessage();

 }
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.31
Ideas – Profile Specific Helper Classes
public class BasicServerAuthModule extends HttpServerAuthModule {
public AuthStatus validateHttpRequest(HttpServletRequest request,
HttpServletResponse response, HttpMessageContext httpMessageContext)
throws AuthException {


}
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.32
Ideas – Profile Specific Helper Classes
public class BasicServerAuthModule extends HttpServerAuthModule {
public AuthStatus validateHttpRequest(HttpServletRequest request,
HttpServletResponse response, HttpMessageContext httpMessageContext)
throws AuthException {
final String header = request.getHeader("Authorization");
final String[] credentials = parseCredentials(header);
final String username = credentials[0];
final String password = credentials[1];
if (!"snoopy".equals(username) || !"woodst0ck".equals(password)) {
return FAILURE;
} // No callbacks required!!!
return httpMessageContext.notifyContainerAboutLogin(
"snoopy",
// the groups/roles of the authenticated user
Arrays.asList("RedBaron", "JoeCool", "MansBestFriend"));
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.33
Ideas – Standardized Authenticators
@Authenticator("javax.security.authenticator.OpenIDConnect")
@WebServlet("/SimpleServlet")
@ServletSecurity(@HttpConstraint(rolesAllowed = {"manager"}))
public class SimpleServlet extends HttpServlet {
@Override
protected void doGet(HttpServletRequest request,
HttpServletResponse response)
throws ServletException, IOException {
response.getWriter().print("my GET");
}
}
Â§ï‚§â€Ż OpenID Connect ServerAuthModule
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.34
Ideas – Authentication Events
Â§ï‚§â€Ż Throw standardized CDI events at important moments
–  PreAuthenticate Event
–  PostAuthenticate Event
–  PreLogout Event
–  PostLogout Event
Â§ï‚§â€Ż Possible uses:
–  Tracking number of logged-in users
–  Tracking failed login attempts per account
–  Side effects, like creating a new local user after initial successful
authentication via a remote authentication provider
–  Loading application-specific user preferences
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.35
Ideas
Â§ï‚§â€Ż Terminology
Â§ï‚§â€Ż API for Authentication Mechanism
Â§ï‚§â€Ż API for Identity Store
Â§ï‚§â€Ż API for Password Aliasing
Â§ï‚§â€Ż API for Role/Permission Assignment
Â§ï‚§â€Ż API for Security Context
Â§ï‚§â€Ż API for Authorization Interceptors
To modernize, standardize, simplify
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.36
Use Case
Â§ï‚§â€Ż Application manages its own users and groups
Â§ï‚§â€Ż Need to access a repository of identities, like users
Â§ï‚§â€Ż Users may be stored in app-specified repository (e.g. LDAP)
Â§ï‚§â€Ż Users are managed without access to server configuration
API for Identity Store
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.37
Survey Results
API for Identity Store
'
Should we simplify authorization by introducing an EL-enabled authorization
annotation?
'
Should we standardize on requirements for simple security providers and their
configuration?
'
'
Approximately'58%'thought'we'should'add'support'for'password'aliases,'including'the'
ability'to'provision'credentials'along'with'the'application.'
'
70%'thought'that'we'should'standardize'group`to`role'mapping.'
'
53%'thought'we'should'simplify'JASPIC'authentication.'
'
67%'thought'that'we'should'simplify'authorization'and'make'it'more'flexible'by'
introducing'EL`based'authorization'annotations,'introducing'a'capability'more'general'
than'use'of'@RolesAllowed'and'simpler'than'use'of'interceptors'to'do'programmatic'
authorization.'
'
65%'thought'we'should'standardize'on'requirements'for'simple'security'providers'and'
their'configuration.'
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.38
Current Solutions
Â§ï‚§â€Ż No Java EE support
Â§ï‚§â€Ż Only proprietary server support
Â§ï‚§â€Ż 3rd party security frameworks provide user/group APIs
API for Identity Store
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.39
Ideas – Identity Store
public interface Identity {
String getUsername();
char[] getPassword();
boolean isAccountExpired();
boolean isAccountLocked();
boolean isPasswordExpired();
boolean isEnabled();
IdentityAttributeValue getAttribute(String name);
}
public interface IdentityAttributeValue {
String getValue();
String getMetaInfo(String name);
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.40
Ideas – Identity Store
public interface IdentityStore{
Identity loadIdentityByName(String name);
void changePassword(char[] oldPassword, char[] newPassword);
void createIdentity(Identity user);
void deleteIdentity(String name);
void updateIdentity(Identity identity);
boolean identityExists(String name);
void createGroup(String group);
void deleteGroup(String group);
void addIdentityToGroup(String name, String group);
void removeIdentityFromGroup(String name, String group);
boolean isIdentityInGroup(String name, String group);
List<String> getIdentityGroups(String name);
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.41
Ideas – Identity Store
IdentityStore
LDAP Server
Identity
DBFile
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.42
Ideas – Identity Store
@LdapIdentityStore(name=“java:app/prodIdentityStore”,
ldapUrl=“ldap://blah”, ldapUser=“ElDap”,ldapPassword=“welcome”)
public class MyAuthenticator {
@Resource(lookup=“java:app/prodIdentityStore”)
private IdentityStore identityStore;
private boolean isAccountEnabled(String username) {
return identityStore.loadUserByUsername(username).isEnabled();
} 

}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.43
Ideas – Identity Store
@EmbeddedIdentityStore(name=“java:app/devIdentityStore”,
{@Identity(username="ray", password="secret", groups="admin"),
@Identity(username="jo", password="secret", groups="user"),
@Identity(username="sam", password="secret", groups="user")})
@DatabaseIdentityStore(name=“java:app/testIdentityStore”,
lookup="somedatabase",
userQuery="SELECT password FROM principals WHERE username=?",
groupQuery="SELECT group FROM groups where username=?", ...)
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.44
Ideas
Â§ï‚§â€Ż Terminology
Â§ï‚§â€Ż API for Authentication Mechanism
Â§ï‚§â€Ż API for Identity Store
Â§ï‚§â€Ż API for Password Aliasing
Â§ï‚§â€Ż API for Role/Permission Assignment
Â§ï‚§â€Ż API for Security Context
Â§ï‚§â€Ż API for Authorization Interceptors
To modernize, standardize, simplify
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.45
Use Case
Â§ï‚§â€Ż Application uses passwords to access resources like LDAP and DB
Â§ï‚§â€Ż Passwords stored in annotations, deployment descriptors
Â§ï‚§â€Ż Best practices dictate that passwords are never stored in clear text
Â§ï‚§â€Ż Need a portable way to protect stored passwords
API for Password Aliasing
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.46
Survey Results
Â§ï‚§â€Ż Deferred from Java EE 7
API for Password Aliasing
Of'the'small'fraction'of'participants'who'added'comments,'most'of'these'strongly'urged'
for'improvements'in'logging'–'either'by'the'revision'of'java.util.logging,'or'replacement'
of'its'use'by'either'slf4j,''slf4j'with'LogBack,'or'log4j.'
'
'
'
Security'
'
Most'of'the'suggested'improvements'in'the'security'area'received'strong'support.'
'
Should we add support for password aliases (including the ability to provision
credentials along with the application)?
'
Should we standardize group-to-role mapping?
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.47
Current Solutions
Â§ï‚§â€Ż No Java EE support
Â§ï‚§â€Ż Proprietary server support, e.g. GlassFish
Â§ï‚§â€Ż 3rd party security framework support for embedded password
encryption, not aliasing
API for Password Aliasing
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.48
Ideas – Password Aliasing
Â§ï‚§â€Ż For annotations
@DataSourceDefinition(
name="java:app/jdbc/test",
user="root",
password="${ALIAS=password}",
)
Â§ï‚§â€Ż For deployment descriptors
<data-source>
<name>java:app/env/testDS</name>
<user>APP</user>
<password>${ALIAS=password}</password>


</data-source>
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.49
Ideas – Password Aliasing
${ALIAS=token} "mysecret"
Resolved
when used
Cleared
when done
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.50
Ideas – Password Aliasing
Password Alias
Archive
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.51
Ideas – Password Aliasing
Â§ï‚§â€Ż For configuration: Annotations, Deployment Descriptors
Â§ï‚§â€Ż Secure credentials archive for bundling the alias and actual password
values with applications
Â§ï‚§â€Ż Platform consumes the credentials archive upon deployment
Â§ï‚§â€Ż Standard tooling for CRUD operations on the credential archive, e.g.
keytool
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.52
Ideas
Â§ï‚§â€Ż Terminology
Â§ï‚§â€Ż API for Authentication Mechanism
Â§ï‚§â€Ż API for Identity Store
Â§ï‚§â€Ż API for Password Aliasing
Â§ï‚§â€Ż API for Role/Permission Assignment
Â§ï‚§â€Ż API for Security Context
Â§ï‚§â€Ż API for Authorization Interceptors
To modernize, standardize, simplify
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.53
Use Case
Â§ï‚§â€Ż Application manages its own users and groups
Â§ï‚§â€Ż Application needs to assign roles (i.e., authorities, permissions) to
users and groups, based on application-specific model
Â§ï‚§â€Ż Users may be stored in app-specified repository (e.g. LDAP)
Â§ï‚§â€Ż Users are managed without access to server configuration
API for Role/Permission Assignment
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.54
Survey Results
API for Role/Permission Assignment
Security'
'
Most'of'the'suggested'improvements'in'the'security'area'received'strong'support.'
'
Should we add support for password aliases (including the ability to provision
credentials along with the application)?
'
Should we standardize group-to-role mapping?
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.55
Current Solutions
Â§ï‚§â€Ż No Java EE support
Â§ï‚§â€Ż Only proprietary server support
Â§ï‚§â€Ż 3rd party security frameworks provide role/authority/permission APIs
API for Role/Permission Assignment
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.56
Ideas – Standardized Role Mapping
Â§ï‚§â€Ż Support in Deployment Descriptors, e.g. web.xml
<security-role-map>
<!-- Role name as set/returned by Authentication Module -->
<group>MANAGER</group>
<!-- Role name for mapping -->
<role-name>EDIT_ACCOUNTS</role-name>
</security-role-map>
<!– One-to-one group to role mapping -->
<security-role-map groupToRoleMapping="false" />
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.57
Ideas – Role Mapping Annotation
@EmbeddedRoleMapper(
users={
@RoleMap(user=“foo”,roles=“admin”),
@RoleMap(group=“admin”,roles={“admin”,”manager”})
}
)
public class MyServlet {
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.58
Ideas – Dynamic Role Mapping
public interface RoleMapper {
void grantRoleToUser(String username, String role);
void revokeRoleFromUser(String username, String role);
boolean hasRoleForUser(
String username, String role, boolean includeGroups);
List<String> getRolesForUser(
String username, boolean includeGroups);
List<String> getUsersWithRole(
String role, boolean includeGroups);
void grantRoleToGroup(String group, String role);
void revokeRoleFromGroup(String group, String role);
boolean hasRoleForGroup(String group, String role);
List<String> getRolesForGroup(String group);
List<String> getGroupsWithRole(String role);
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.59
Ideas – Dynamic Role Mapping
@Inject
RoleMapper roleMapper;
roleMapper.grantRoleToGroup("Manager", "EDIT_ACCOUNTS");
boolean has = roleMapper.hasRoleForGroup("Manager", "CLOSE_ACCT");
List<String> roles = roleMapper.getRolesForGroup("Manager");
List<String> groups = roleMapper.getGroupsWithRole("VIEW_ACCOUNTS");
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.60
Ideas
Â§ï‚§â€Ż Terminology
Â§ï‚§â€Ż API for Authentication Mechanism
Â§ï‚§â€Ż API for Identity Store
Â§ï‚§â€Ż API for Password Aliasing
Â§ï‚§â€Ż API for Role/Permission Assignment
Â§ï‚§â€Ż API for Security Context
Â§ï‚§â€Ż API for Authorization Interceptors
To modernize, standardize, simplify
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.61
Use Case
Â§ï‚§â€Ż Application needs to access the security API
–  To get the authenticated user
–  To check roles
–  To invoke runAs.
Â§ï‚§â€Ż Application needs the same API to access security context, regardless
of container
API for Security Context
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.62
Current Solutions
Â§ï‚§â€Ż No Java EE support
Â§ï‚§â€Ż 3rd party security frameworks provide a security context
API for Security Context
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.63
Current Solutions
@Singleton
public class MyEjb {
@Resource
private SessionContext sessionContext;
public String sayHello() {
if (sessionContext.isCallerInRole("admin")) {
return "Hello World!";
}
throw new SecurityException("User is unauthorized.");
}
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.64
Current Solutions
public class MyServlet extends HttpServlet {
@Override
protected void doGet(HttpServletRequest request,
HttpServletResponse resp) throws ServletException, IOException {
if (request.isUserInRole("admin")) {
// do something
}
throw new ServletException("User is unauthorized.");
}
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.65
Current Solutions
@RequestScoped
public class MyCdiBean {
// Oh snap! No SecurityContext class for CDI
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.66
Current Solutions
public class MyJaxRsService {
@GET
@Produces("text/plain;charset=UTF-8")
@Path("/hello")
public String sayHello(@Context SecurityContext sc) {
if (sc.isUserInRole("admin")) {
return "Hello World!";
}
throw new SecurityException("User is unauthorized.");
}
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.67
Ideas – Security Context
public interface SecurityContext {
String getUserPrincipal();
boolean isUserInRole(String role);
List<String> getAllUsersRoles();
boolean isAuthenticated();
boolean isUserInAnyRole(List<String> roles);
boolean isUserInAllRoles(List<String> roles);
void login(Object request, Object response);
void login(Map map);
void logout();
void runAs(String role);
boolean hasAccessToResource();
boolean hasAccessToBeanMethod();
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.68
Ideas – Security Context
Â§ï‚§â€Ż For all managed beans: CDI, Servlet, EJB, JAX-RS, etc
public class MyFutureCdiBean {
@Inject
private SecurityContext securityContext;
public String sayHello() {
if (securityContext.isUserInRole("admin")) {
return "Hello World!";
}
throw new SecurityException("User is unauthorized.");
}
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.69
Ideas
Â§ï‚§â€Ż Terminology
Â§ï‚§â€Ż API for Authentication Mechanism
Â§ï‚§â€Ż API for Identity Store
Â§ï‚§â€Ż API for Password Aliasing
Â§ï‚§â€Ż API for Role/Permission Assignment
Â§ï‚§â€Ż API for Security Context
Â§ï‚§â€Ż API for Authorization Interceptors
To modernize, standardize, simplify
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.70
Use Case
Â§ï‚§â€Ż Application needs to restrict specific methods to authorized users
Â§ï‚§â€Ż Application-model rules are used to make access decisions
Â§ï‚§â€Ż Role is insufficient
API for Authorization Interceptors
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.71
Survey Results
API for Authorization Interceptors
this'last'question.''Thymeleaf,'Freemarker,'and'Velocity'were'the'most'frequently'
mentioned'here.'
'
'
'
'
CDI'
'
The'next'four'questions'focused'on'continued'CDI'alignment.''This'was'one'of'the'focus'
areas'of'Java'EE'7.'
'
Should we consider adding Security Interceptors in Java EE 8?
Should we simplify JASPIC?
'
Should we simplify authorization by introducing an EL-enabled authorization
annotation?
'
Should we standardize on requirements for simple security providers and their
configuration?
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.72
Current Solutions
Â§ï‚§â€Ż EE authorization has no rule based authorization, only role based
Â§ï‚§â€Ż 3rd party security frameworks provide rule, role and permission based
APIs
API for Authorization Interceptors
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.73
Ideas – EL Authorization Rules
Â§ï‚§â€Ż Expression Language rule would have access to managed beans for
SecurityContext and InvocationContext
@ EvaluateSecured("security.hasRoles('MANAGER') &&
schedule.nowIsOfficeHrs")
void transferFunds() {..};
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.74
Ideas – EL Authorization Rules
Â§ï‚§â€Ż EL Authorization rules centrally managed in a repository
@LdapAuthorizationRules (
name="java:app/accountAuthRules",
ldapUrl="ldap://blah",
ldapUser="ElDap",
ldapPassword=“mysecret”
)
public class MyBean {
@ EvaluateSecured(
ruleSourceName="java:app/accountAuthRules", rule="transferFunds")
void transferFunds() {..};


}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.75
Ideas – AccessDecisionVoter
Â§ï‚§â€Ż A user-defined class for making access decisions
@Secured(AccountAccessDecisionVoter.class)
void transferFunds() {..};
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.76
Ideas – AccessDecisionVoter
public class AccountAccessDecisionVoter implements AccessDecisionVoter {
@Override
public void checkPermission(AccessDecisionVoterContext ctx,
Set<SecurityViolation> violations) {
// Check for violations
Method method = ctx.<InvocationContext>getSource().getMethod();


violations.add(new SecurityViolation("Sorry, not allowed"));
}
}
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.77
Agenda
Â§ï‚§â€Ż Motivations
Â§ï‚§â€Ż A New JSR
Â§ï‚§â€Ż Ideas
Â§ï‚§â€Ż Get Involved
Â§ï‚§â€Ż Q & A
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.78
Get Involved
Â§ï‚§â€Ż Project Page: The starting point to all resources
https://java.net/projects/javaee-security-spec
Â§ï‚§â€Ż Users List: Subscribe and contribute
users@javaee-security-spec.java.net
Â§ï‚§â€Ż Github Playground: Fork and Play!
https://github.com/javaee-security-spec/javaee-security-proposals
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.79
Q/A
Copyright © 2015, Oracle and/or its affiliates. All rights reserved.80

Mais conteĂșdo relacionado

Mais procurados

ïżŒEJB and CDI - Alignment and Strategy
ïżŒEJB and CDI - Alignment and StrategyïżŒEJB and CDI - Alignment and Strategy
ïżŒEJB and CDI - Alignment and StrategyDavid Delabassee
 
Have You Seen Java EE Lately?
Have You Seen Java EE Lately?Have You Seen Java EE Lately?
Have You Seen Java EE Lately?Reza Rahman
 
HTTP/2 comes to Java. What Servlet 4.0 means to you. DevNexus 2015
HTTP/2 comes to Java.  What Servlet 4.0 means to you. DevNexus 2015HTTP/2 comes to Java.  What Servlet 4.0 means to you. DevNexus 2015
HTTP/2 comes to Java. What Servlet 4.0 means to you. DevNexus 2015Edward Burns
 
Java EE 8 - An instant snapshot
Java EE 8 - An instant snapshot Java EE 8 - An instant snapshot
Java EE 8 - An instant snapshot David Delabassee
 
Java EE Revisits GoF Design Patterns
Java EE Revisits GoF Design PatternsJava EE Revisits GoF Design Patterns
Java EE Revisits GoF Design PatternsMurat Yener
 
JSR 375 - Have you seen Java EE Security API lately? - codemotion Tel Aviv 2015
JSR 375 - Have you seen Java EE Security API lately? - codemotion Tel Aviv 2015JSR 375 - Have you seen Java EE Security API lately? - codemotion Tel Aviv 2015
JSR 375 - Have you seen Java EE Security API lately? - codemotion Tel Aviv 2015Werner Keil
 
What's New in WebLogic 12.1.3 and Beyond
What's New in WebLogic 12.1.3 and BeyondWhat's New in WebLogic 12.1.3 and Beyond
What's New in WebLogic 12.1.3 and BeyondOracle
 
Java EE 6 Adoption in One of the World’s Largest Online Financial Systems
Java EE 6 Adoption in One of the World’s Largest Online Financial SystemsJava EE 6 Adoption in One of the World’s Largest Online Financial Systems
Java EE 6 Adoption in One of the World’s Largest Online Financial SystemsArshal Ameen
 
Move from J2EE to Java EE
Move from J2EE to Java EEMove from J2EE to Java EE
Move from J2EE to Java EEHirofumi Iwasaki
 
Best Way to Write SQL in Java
Best Way to Write SQL in JavaBest Way to Write SQL in Java
Best Way to Write SQL in JavaGerger
 
Modern web application development with java ee 7
Modern web application development with java ee 7Modern web application development with java ee 7
Modern web application development with java ee 7Shekhar Gulati
 
Java EE 8 Adopt a JSR : JSON-P 1.1 & MVC 1.0
Java EE 8 Adopt a JSR : JSON-P 1.1 & MVC 1.0Java EE 8 Adopt a JSR : JSON-P 1.1 & MVC 1.0
Java EE 8 Adopt a JSR : JSON-P 1.1 & MVC 1.0David Delabassee
 
Java on Azure
Java on AzureJava on Azure
Java on AzurePhilly JUG
 
Adopt-a-JSR for JSON Processing 1.1, JSR 374
Adopt-a-JSR for JSON Processing 1.1, JSR 374Adopt-a-JSR for JSON Processing 1.1, JSR 374
Adopt-a-JSR for JSON Processing 1.1, JSR 374Heather VanCura
 
JavaScript Frameworks and Java EE – A Great Match
JavaScript Frameworks and Java EE – A Great MatchJavaScript Frameworks and Java EE – A Great Match
JavaScript Frameworks and Java EE – A Great MatchReza Rahman
 
Servlet 4.0 at GeekOut 2015
Servlet 4.0 at GeekOut 2015Servlet 4.0 at GeekOut 2015
Servlet 4.0 at GeekOut 2015Edward Burns
 

Mais procurados (16)

ïżŒEJB and CDI - Alignment and Strategy
ïżŒEJB and CDI - Alignment and StrategyïżŒEJB and CDI - Alignment and Strategy
ïżŒEJB and CDI - Alignment and Strategy
 
Have You Seen Java EE Lately?
Have You Seen Java EE Lately?Have You Seen Java EE Lately?
Have You Seen Java EE Lately?
 
HTTP/2 comes to Java. What Servlet 4.0 means to you. DevNexus 2015
HTTP/2 comes to Java.  What Servlet 4.0 means to you. DevNexus 2015HTTP/2 comes to Java.  What Servlet 4.0 means to you. DevNexus 2015
HTTP/2 comes to Java. What Servlet 4.0 means to you. DevNexus 2015
 
Java EE 8 - An instant snapshot
Java EE 8 - An instant snapshot Java EE 8 - An instant snapshot
Java EE 8 - An instant snapshot
 
Java EE Revisits GoF Design Patterns
Java EE Revisits GoF Design PatternsJava EE Revisits GoF Design Patterns
Java EE Revisits GoF Design Patterns
 
JSR 375 - Have you seen Java EE Security API lately? - codemotion Tel Aviv 2015
JSR 375 - Have you seen Java EE Security API lately? - codemotion Tel Aviv 2015JSR 375 - Have you seen Java EE Security API lately? - codemotion Tel Aviv 2015
JSR 375 - Have you seen Java EE Security API lately? - codemotion Tel Aviv 2015
 
What's New in WebLogic 12.1.3 and Beyond
What's New in WebLogic 12.1.3 and BeyondWhat's New in WebLogic 12.1.3 and Beyond
What's New in WebLogic 12.1.3 and Beyond
 
Java EE 6 Adoption in One of the World’s Largest Online Financial Systems
Java EE 6 Adoption in One of the World’s Largest Online Financial SystemsJava EE 6 Adoption in One of the World’s Largest Online Financial Systems
Java EE 6 Adoption in One of the World’s Largest Online Financial Systems
 
Move from J2EE to Java EE
Move from J2EE to Java EEMove from J2EE to Java EE
Move from J2EE to Java EE
 
Best Way to Write SQL in Java
Best Way to Write SQL in JavaBest Way to Write SQL in Java
Best Way to Write SQL in Java
 
Modern web application development with java ee 7
Modern web application development with java ee 7Modern web application development with java ee 7
Modern web application development with java ee 7
 
Java EE 8 Adopt a JSR : JSON-P 1.1 & MVC 1.0
Java EE 8 Adopt a JSR : JSON-P 1.1 & MVC 1.0Java EE 8 Adopt a JSR : JSON-P 1.1 & MVC 1.0
Java EE 8 Adopt a JSR : JSON-P 1.1 & MVC 1.0
 
Java on Azure
Java on AzureJava on Azure
Java on Azure
 
Adopt-a-JSR for JSON Processing 1.1, JSR 374
Adopt-a-JSR for JSON Processing 1.1, JSR 374Adopt-a-JSR for JSON Processing 1.1, JSR 374
Adopt-a-JSR for JSON Processing 1.1, JSR 374
 
JavaScript Frameworks and Java EE – A Great Match
JavaScript Frameworks and Java EE – A Great MatchJavaScript Frameworks and Java EE – A Great Match
JavaScript Frameworks and Java EE – A Great Match
 
Servlet 4.0 at GeekOut 2015
Servlet 4.0 at GeekOut 2015Servlet 4.0 at GeekOut 2015
Servlet 4.0 at GeekOut 2015
 

Destaque

Java EE 8 - February 2017 update
Java EE 8 - February 2017 updateJava EE 8 - February 2017 update
Java EE 8 - February 2017 updateDavid Delabassee
 
HTTP/2 Comes to Java - What Servlet 4.0 Means to You
HTTP/2 Comes to Java - What Servlet 4.0 Means to YouHTTP/2 Comes to Java - What Servlet 4.0 Means to You
HTTP/2 Comes to Java - What Servlet 4.0 Means to YouDavid Delabassee
 
Java EE 8: What Servlet 4.0 and HTTP/2 mean to you
Java EE 8: What Servlet 4.0 and HTTP/2 mean to youJava EE 8: What Servlet 4.0 and HTTP/2 mean to you
Java EE 8: What Servlet 4.0 and HTTP/2 mean to youAlex Theedom
 
10 Tips for Java EE 7 with PrimeFaces - JavaOne 2013
10 Tips for Java EE 7 with PrimeFaces - JavaOne 201310 Tips for Java EE 7 with PrimeFaces - JavaOne 2013
10 Tips for Java EE 7 with PrimeFaces - JavaOne 2013Martin Fousek
 
What’s new in JSR 367 Java API for JSON Binding
What’s new in JSR 367 Java API for JSON BindingWhat’s new in JSR 367 Java API for JSON Binding
What’s new in JSR 367 Java API for JSON BindingDmitry Kornilov
 
2015 UJUG, Servlet 4.0 portion
2015 UJUG, Servlet 4.0 portion2015 UJUG, Servlet 4.0 portion
2015 UJUG, Servlet 4.0 portionmnriem
 
2015 JavaOne EJB/CDI Alignment
2015 JavaOne EJB/CDI Alignment2015 JavaOne EJB/CDI Alignment
2015 JavaOne EJB/CDI AlignmentDavid Blevins
 
JSR 375 Segurança em Java EE 8
JSR 375 Segurança em Java EE 8JSR 375 Segurança em Java EE 8
JSR 375 Segurança em Java EE 8Helder da Rocha
 
http2 æœ€é€ŸćźŸèŁ… v2
http2 æœ€é€ŸćźŸèŁ… v2 http2 æœ€é€ŸćźŸèŁ… v2
http2 æœ€é€ŸćźŸèŁ… v2 Yoshihiro Iwanaga
 
Servlet 4.0 Adopt-a-JSR 10 Minute Infodeck
Servlet 4.0 Adopt-a-JSR 10 Minute InfodeckServlet 4.0 Adopt-a-JSR 10 Minute Infodeck
Servlet 4.0 Adopt-a-JSR 10 Minute InfodeckEdward Burns
 
HTTP2 æœ€é€ŸćźŸèŁ… ă€œć…„é–€ç·šă€œ
HTTP2 æœ€é€ŸćźŸèŁ… ă€œć…„é–€ç·šă€œHTTP2 æœ€é€ŸćźŸèŁ… ă€œć…„é–€ç·šă€œ
HTTP2 æœ€é€ŸćźŸèŁ… ă€œć…„é–€ç·šă€œKaoru Maeda
 
Paul Johnston - What I Wish I'd Known Last Year
Paul Johnston - What I Wish I'd Known Last YearPaul Johnston - What I Wish I'd Known Last Year
Paul Johnston - What I Wish I'd Known Last YearServerlessConf
 
Java EE for the Cloud
Java EE for the CloudJava EE for the Cloud
Java EE for the CloudDmitry Kornilov
 
Introduction to CDI and DI in Java EE 6
Introduction to CDI and DI in Java EE 6Introduction to CDI and DI in Java EE 6
Introduction to CDI and DI in Java EE 6Ray Ploski
 
API Security from the DevOps and CSO Perspectives (Webcast)
API Security from the DevOps and CSO Perspectives (Webcast)API Security from the DevOps and CSO Perspectives (Webcast)
API Security from the DevOps and CSO Perspectives (Webcast)Apigee | Google Cloud
 
Javaど゙ぼバăƒȘăƒ†ă‚™ăƒŒă‚·ăƒ§ăƒł 〜Bean Validation篇〜
Javaど゙ぼバăƒȘăƒ†ă‚™ăƒŒă‚·ăƒ§ăƒł 〜Bean Validation篇〜Javaど゙ぼバăƒȘăƒ†ă‚™ăƒŒă‚·ăƒ§ăƒł 〜Bean Validation篇〜
Javaど゙ぼバăƒȘăƒ†ă‚™ăƒŒă‚·ăƒ§ăƒł 〜Bean Validation篇〜eiryu
 
Adopt-a-JSR session (JSON-B/P)
Adopt-a-JSR session (JSON-B/P)Adopt-a-JSR session (JSON-B/P)
Adopt-a-JSR session (JSON-B/P)Dmitry Kornilov
 
3ćčŽé–“ăźæƒ…ć ±æŒæŽ©äș‹ä»¶ă‹ă‚‰ăżă‚‹ăƒ‡ăƒŒă‚żäżè­·ćŻŸç­–ăźć‹˜æ‰€  ăƒ‡ăƒŒă‚żăƒ»ă‚»ă‚­ăƒ„ăƒȘăƒ†ă‚Łă€è€ƒăˆæ–čăšăăźä»•ç”„ăż
3ćčŽé–“ăźæƒ…ć ±æŒæŽ©äș‹ä»¶ă‹ă‚‰ăżă‚‹ăƒ‡ăƒŒă‚żäżè­·ćŻŸç­–ăźć‹˜æ‰€  ăƒ‡ăƒŒă‚żăƒ»ă‚»ă‚­ăƒ„ăƒȘăƒ†ă‚Łă€è€ƒăˆæ–čăšăăźä»•ç”„ăż3ćčŽé–“ăźæƒ…ć ±æŒæŽ©äș‹ä»¶ă‹ă‚‰ăżă‚‹ăƒ‡ăƒŒă‚żäżè­·ćŻŸç­–ăźć‹˜æ‰€  ăƒ‡ăƒŒă‚żăƒ»ă‚»ă‚­ăƒ„ăƒȘăƒ†ă‚Łă€è€ƒăˆæ–čăšăăźä»•ç”„ăż
3ćčŽé–“ăźæƒ…ć ±æŒæŽ©äș‹ä»¶ă‹ă‚‰ăżă‚‹ăƒ‡ăƒŒă‚żäżè­·ćŻŸç­–ăźć‹˜æ‰€  ăƒ‡ăƒŒă‚żăƒ»ă‚»ă‚­ăƒ„ăƒȘăƒ†ă‚Łă€è€ƒăˆæ–čăšăăźä»•ç”„ăżă‚Șăƒ©ă‚Żăƒ«ă‚šăƒłă‚žăƒ‹ă‚ąé€šäżĄ
 

Destaque (19)

Java EE 8 - February 2017 update
Java EE 8 - February 2017 updateJava EE 8 - February 2017 update
Java EE 8 - February 2017 update
 
Java EE Next
Java EE NextJava EE Next
Java EE Next
 
HTTP/2 Comes to Java - What Servlet 4.0 Means to You
HTTP/2 Comes to Java - What Servlet 4.0 Means to YouHTTP/2 Comes to Java - What Servlet 4.0 Means to You
HTTP/2 Comes to Java - What Servlet 4.0 Means to You
 
Java EE 8: What Servlet 4.0 and HTTP/2 mean to you
Java EE 8: What Servlet 4.0 and HTTP/2 mean to youJava EE 8: What Servlet 4.0 and HTTP/2 mean to you
Java EE 8: What Servlet 4.0 and HTTP/2 mean to you
 
10 Tips for Java EE 7 with PrimeFaces - JavaOne 2013
10 Tips for Java EE 7 with PrimeFaces - JavaOne 201310 Tips for Java EE 7 with PrimeFaces - JavaOne 2013
10 Tips for Java EE 7 with PrimeFaces - JavaOne 2013
 
What’s new in JSR 367 Java API for JSON Binding
What’s new in JSR 367 Java API for JSON BindingWhat’s new in JSR 367 Java API for JSON Binding
What’s new in JSR 367 Java API for JSON Binding
 
2015 UJUG, Servlet 4.0 portion
2015 UJUG, Servlet 4.0 portion2015 UJUG, Servlet 4.0 portion
2015 UJUG, Servlet 4.0 portion
 
2015 JavaOne EJB/CDI Alignment
2015 JavaOne EJB/CDI Alignment2015 JavaOne EJB/CDI Alignment
2015 JavaOne EJB/CDI Alignment
 
JSR 375 Segurança em Java EE 8
JSR 375 Segurança em Java EE 8JSR 375 Segurança em Java EE 8
JSR 375 Segurança em Java EE 8
 
http2 æœ€é€ŸćźŸèŁ… v2
http2 æœ€é€ŸćźŸèŁ… v2 http2 æœ€é€ŸćźŸèŁ… v2
http2 æœ€é€ŸćźŸèŁ… v2
 
Servlet 4.0 Adopt-a-JSR 10 Minute Infodeck
Servlet 4.0 Adopt-a-JSR 10 Minute InfodeckServlet 4.0 Adopt-a-JSR 10 Minute Infodeck
Servlet 4.0 Adopt-a-JSR 10 Minute Infodeck
 
HTTP2 æœ€é€ŸćźŸèŁ… ă€œć…„é–€ç·šă€œ
HTTP2 æœ€é€ŸćźŸèŁ… ă€œć…„é–€ç·šă€œHTTP2 æœ€é€ŸćźŸèŁ… ă€œć…„é–€ç·šă€œ
HTTP2 æœ€é€ŸćźŸèŁ… ă€œć…„é–€ç·šă€œ
 
Paul Johnston - What I Wish I'd Known Last Year
Paul Johnston - What I Wish I'd Known Last YearPaul Johnston - What I Wish I'd Known Last Year
Paul Johnston - What I Wish I'd Known Last Year
 
Java EE for the Cloud
Java EE for the CloudJava EE for the Cloud
Java EE for the Cloud
 
Introduction to CDI and DI in Java EE 6
Introduction to CDI and DI in Java EE 6Introduction to CDI and DI in Java EE 6
Introduction to CDI and DI in Java EE 6
 
API Security from the DevOps and CSO Perspectives (Webcast)
API Security from the DevOps and CSO Perspectives (Webcast)API Security from the DevOps and CSO Perspectives (Webcast)
API Security from the DevOps and CSO Perspectives (Webcast)
 
Javaど゙ぼバăƒȘăƒ†ă‚™ăƒŒă‚·ăƒ§ăƒł 〜Bean Validation篇〜
Javaど゙ぼバăƒȘăƒ†ă‚™ăƒŒă‚·ăƒ§ăƒł 〜Bean Validation篇〜Javaど゙ぼバăƒȘăƒ†ă‚™ăƒŒă‚·ăƒ§ăƒł 〜Bean Validation篇〜
Javaど゙ぼバăƒȘăƒ†ă‚™ăƒŒă‚·ăƒ§ăƒł 〜Bean Validation篇〜
 
Adopt-a-JSR session (JSON-B/P)
Adopt-a-JSR session (JSON-B/P)Adopt-a-JSR session (JSON-B/P)
Adopt-a-JSR session (JSON-B/P)
 
3ćčŽé–“ăźæƒ…ć ±æŒæŽ©äș‹ä»¶ă‹ă‚‰ăżă‚‹ăƒ‡ăƒŒă‚żäżè­·ćŻŸç­–ăźć‹˜æ‰€  ăƒ‡ăƒŒă‚żăƒ»ă‚»ă‚­ăƒ„ăƒȘăƒ†ă‚Łă€è€ƒăˆæ–čăšăăźä»•ç”„ăż
3ćčŽé–“ăźæƒ…ć ±æŒæŽ©äș‹ä»¶ă‹ă‚‰ăżă‚‹ăƒ‡ăƒŒă‚żäżè­·ćŻŸç­–ăźć‹˜æ‰€  ăƒ‡ăƒŒă‚żăƒ»ă‚»ă‚­ăƒ„ăƒȘăƒ†ă‚Łă€è€ƒăˆæ–čăšăăźä»•ç”„ăż3ćčŽé–“ăźæƒ…ć ±æŒæŽ©äș‹ä»¶ă‹ă‚‰ăżă‚‹ăƒ‡ăƒŒă‚żäżè­·ćŻŸç­–ăźć‹˜æ‰€  ăƒ‡ăƒŒă‚żăƒ»ă‚»ă‚­ăƒ„ăƒȘăƒ†ă‚Łă€è€ƒăˆæ–čăšăăźä»•ç”„ăż
3ćčŽé–“ăźæƒ…ć ±æŒæŽ©äș‹ä»¶ă‹ă‚‰ăżă‚‹ăƒ‡ăƒŒă‚żäżè­·ćŻŸç­–ăźć‹˜æ‰€  ăƒ‡ăƒŒă‚żăƒ»ă‚»ă‚­ăƒ„ăƒȘăƒ†ă‚Łă€è€ƒăˆæ–čăšăăźä»•ç”„ăż
 

Semelhante a Finally, EE Security API JSR 375

Java2Days - Security for JavaEE and the Cloud
Java2Days - Security for JavaEE and the CloudJava2Days - Security for JavaEE and the Cloud
Java2Days - Security for JavaEE and the CloudWerner Keil
 
Oracle JET overview
Oracle JET overviewOracle JET overview
Oracle JET overviewSteven Davelaar
 
Modern App Development with Oracle Cloud
Modern App Development with Oracle CloudModern App Development with Oracle Cloud
Modern App Development with Oracle CloudJuan Carlos Ruiz Rico
 
Oracle database 12c_and_DevOps
Oracle database 12c_and_DevOpsOracle database 12c_and_DevOps
Oracle database 12c_and_DevOpsMaria Colgan
 
REST API Doc Best Practices
REST API Doc Best PracticesREST API Doc Best Practices
REST API Doc Best PracticesMarta Rauch
 
Oracle REST Data Services
Oracle REST Data ServicesOracle REST Data Services
Oracle REST Data ServicesChris Muir
 
JavaOne2015ăƒ•ă‚ŁăƒŒăƒ‰ăƒăƒƒă‚Ż @ ćŻŒć±±ćˆćŒć‹‰ćŒ·äŒš
JavaOne2015ăƒ•ă‚ŁăƒŒăƒ‰ăƒăƒƒă‚Ż @ ćŻŒć±±ćˆćŒć‹‰ćŒ·äŒšJavaOne2015ăƒ•ă‚ŁăƒŒăƒ‰ăƒăƒƒă‚Ż @ ćŻŒć±±ćˆćŒć‹‰ćŒ·äŒš
JavaOne2015ăƒ•ă‚ŁăƒŒăƒ‰ăƒăƒƒă‚Ż @ ćŻŒć±±ćˆćŒć‹‰ćŒ·äŒšTakashi Ito
 
JavaOne Shanghai 2013 - Servlet 3.1 (JSR 340)
JavaOne Shanghai 2013 - Servlet 3.1 (JSR 340)JavaOne Shanghai 2013 - Servlet 3.1 (JSR 340)
JavaOne Shanghai 2013 - Servlet 3.1 (JSR 340)Shing Wai Chan
 
20160123 java one2015_feedback @ Osaka
20160123 java one2015_feedback @ Osaka20160123 java one2015_feedback @ Osaka
20160123 java one2015_feedback @ OsakaTakashi Ito
 
Boost Your Content Strategy for REST APIs
Boost Your Content Strategy for REST APIsBoost Your Content Strategy for REST APIs
Boost Your Content Strategy for REST APIsMarta Rauch
 
Java Web Application Security - Denver JUG 2013
Java Web Application Security - Denver JUG 2013Java Web Application Security - Denver JUG 2013
Java Web Application Security - Denver JUG 2013Matt Raible
 
How to Thrive on REST/WebSocket-Based Microservices
How to Thrive on REST/WebSocket-Based MicroservicesHow to Thrive on REST/WebSocket-Based Microservices
How to Thrive on REST/WebSocket-Based MicroservicesPavel Bucek
 
Oracle Coherence Strategy and Roadmap (OpenWorld, September 2014)
Oracle Coherence Strategy and Roadmap (OpenWorld, September 2014)Oracle Coherence Strategy and Roadmap (OpenWorld, September 2014)
Oracle Coherence Strategy and Roadmap (OpenWorld, September 2014)jeckels
 
Integrating Enterprise Controls with the Cloud
Integrating Enterprise Controls with the CloudIntegrating Enterprise Controls with the Cloud
Integrating Enterprise Controls with the CloudAtul Goyal
 
Interactive Java Support to your tool -- The JShell API and Architecture
Interactive Java Support to your tool -- The JShell API and ArchitectureInteractive Java Support to your tool -- The JShell API and Architecture
Interactive Java Support to your tool -- The JShell API and ArchitectureJavaDayUA
 
geecon 2016: "What's Oracle Doing with JavaScript?!"
geecon 2016: "What's Oracle Doing with JavaScript?!"geecon 2016: "What's Oracle Doing with JavaScript?!"
geecon 2016: "What's Oracle Doing with JavaScript?!"Geertjan Wielenga
 
What_to_expect_from_oracle_database_12c
What_to_expect_from_oracle_database_12cWhat_to_expect_from_oracle_database_12c
What_to_expect_from_oracle_database_12cMaria Colgan
 
10 RazÔes para Usar MySQL em Startups
10 RazÔes para Usar MySQL em Startups10 RazÔes para Usar MySQL em Startups
10 RazÔes para Usar MySQL em StartupsMySQL Brasil
 
Introduction to Java Micro Edition (ME) 8
Introduction to Java Micro Edition (ME) 8Introduction to Java Micro Edition (ME) 8
Introduction to Java Micro Edition (ME) 8terrencebarr
 

Semelhante a Finally, EE Security API JSR 375 (20)

Java2Days - Security for JavaEE and the Cloud
Java2Days - Security for JavaEE and the CloudJava2Days - Security for JavaEE and the Cloud
Java2Days - Security for JavaEE and the Cloud
 
Oracle JET overview
Oracle JET overviewOracle JET overview
Oracle JET overview
 
Modern App Development with Oracle Cloud
Modern App Development with Oracle CloudModern App Development with Oracle Cloud
Modern App Development with Oracle Cloud
 
Oracle database 12c_and_DevOps
Oracle database 12c_and_DevOpsOracle database 12c_and_DevOps
Oracle database 12c_and_DevOps
 
REST API Doc Best Practices
REST API Doc Best PracticesREST API Doc Best Practices
REST API Doc Best Practices
 
Oracle REST Data Services
Oracle REST Data ServicesOracle REST Data Services
Oracle REST Data Services
 
JavaOne2015ăƒ•ă‚ŁăƒŒăƒ‰ăƒăƒƒă‚Ż @ ćŻŒć±±ćˆćŒć‹‰ćŒ·äŒš
JavaOne2015ăƒ•ă‚ŁăƒŒăƒ‰ăƒăƒƒă‚Ż @ ćŻŒć±±ćˆćŒć‹‰ćŒ·äŒšJavaOne2015ăƒ•ă‚ŁăƒŒăƒ‰ăƒăƒƒă‚Ż @ ćŻŒć±±ćˆćŒć‹‰ćŒ·äŒš
JavaOne2015ăƒ•ă‚ŁăƒŒăƒ‰ăƒăƒƒă‚Ż @ ćŻŒć±±ćˆćŒć‹‰ćŒ·äŒš
 
JavaOne Shanghai 2013 - Servlet 3.1 (JSR 340)
JavaOne Shanghai 2013 - Servlet 3.1 (JSR 340)JavaOne Shanghai 2013 - Servlet 3.1 (JSR 340)
JavaOne Shanghai 2013 - Servlet 3.1 (JSR 340)
 
20160123 java one2015_feedback @ Osaka
20160123 java one2015_feedback @ Osaka20160123 java one2015_feedback @ Osaka
20160123 java one2015_feedback @ Osaka
 
Boost Your Content Strategy for REST APIs
Boost Your Content Strategy for REST APIsBoost Your Content Strategy for REST APIs
Boost Your Content Strategy for REST APIs
 
Java Web Application Security - Denver JUG 2013
Java Web Application Security - Denver JUG 2013Java Web Application Security - Denver JUG 2013
Java Web Application Security - Denver JUG 2013
 
How to Thrive on REST/WebSocket-Based Microservices
How to Thrive on REST/WebSocket-Based MicroservicesHow to Thrive on REST/WebSocket-Based Microservices
How to Thrive on REST/WebSocket-Based Microservices
 
Oracle Coherence Strategy and Roadmap (OpenWorld, September 2014)
Oracle Coherence Strategy and Roadmap (OpenWorld, September 2014)Oracle Coherence Strategy and Roadmap (OpenWorld, September 2014)
Oracle Coherence Strategy and Roadmap (OpenWorld, September 2014)
 
Integrating Enterprise Controls with the Cloud
Integrating Enterprise Controls with the CloudIntegrating Enterprise Controls with the Cloud
Integrating Enterprise Controls with the Cloud
 
Interactive Java Support to your tool -- The JShell API and Architecture
Interactive Java Support to your tool -- The JShell API and ArchitectureInteractive Java Support to your tool -- The JShell API and Architecture
Interactive Java Support to your tool -- The JShell API and Architecture
 
Oracle JET
Oracle JETOracle JET
Oracle JET
 
geecon 2016: "What's Oracle Doing with JavaScript?!"
geecon 2016: "What's Oracle Doing with JavaScript?!"geecon 2016: "What's Oracle Doing with JavaScript?!"
geecon 2016: "What's Oracle Doing with JavaScript?!"
 
What_to_expect_from_oracle_database_12c
What_to_expect_from_oracle_database_12cWhat_to_expect_from_oracle_database_12c
What_to_expect_from_oracle_database_12c
 
10 RazÔes para Usar MySQL em Startups
10 RazÔes para Usar MySQL em Startups10 RazÔes para Usar MySQL em Startups
10 RazÔes para Usar MySQL em Startups
 
Introduction to Java Micro Edition (ME) 8
Introduction to Java Micro Edition (ME) 8Introduction to Java Micro Edition (ME) 8
Introduction to Java Micro Edition (ME) 8
 

Último

The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...kalichargn70th171
 
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfintroduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfVishalKumarJha10
 
8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech studentsHimanshiGarg82
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsAndolasoft Inc
 
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...harshavardhanraghave
 
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerHow To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerThousandEyes
 
Exploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfExploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfproinshot.com
 
Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionSolGuruz
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdfPearlKirahMaeRagusta1
 
Microsoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdfMicrosoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdfWilly Marroquin (WillyDevNET)
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Modelsaagamshah0812
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...ICS
 
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdf
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdfAzure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdf
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdfryanfarris8
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfkalichargn70th171
 
AI & Machine Learning Presentation Template
AI & Machine Learning Presentation TemplateAI & Machine Learning Presentation Template
AI & Machine Learning Presentation TemplatePresentation.STUDIO
 
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...panagenda
 
call girls in Vaishali (Ghaziabad) 🔝 >àŒ’8448380779 🔝 genuine Escort Service đŸ”âœ”ïžâœ”ïž
call girls in Vaishali (Ghaziabad) 🔝 >àŒ’8448380779 🔝 genuine Escort Service đŸ”âœ”ïžâœ”ïžcall girls in Vaishali (Ghaziabad) 🔝 >àŒ’8448380779 🔝 genuine Escort Service đŸ”âœ”ïžâœ”ïž
call girls in Vaishali (Ghaziabad) 🔝 >àŒ’8448380779 🔝 genuine Escort Service đŸ”âœ”ïžâœ”ïžDelhi Call girls
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...Health
 

Último (20)

The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
The Guide to Integrating Generative AI into Unified Continuous Testing Platfo...
 
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfintroduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
 
8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.js
 
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
 
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerHow To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
 
Exploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfExploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdf
 
Diamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with PrecisionDiamond Application Development Crafting Solutions with Precision
Diamond Application Development Crafting Solutions with Precision
 
Define the academic and professional writing..pdf
Define the academic and professional writing..pdfDefine the academic and professional writing..pdf
Define the academic and professional writing..pdf
 
Microsoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdfMicrosoft AI Transformation Partner Playbook.pdf
Microsoft AI Transformation Partner Playbook.pdf
 
Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Models
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
 
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdf
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdfAzure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdf
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdf
 
Vip Call Girls Noida âžĄïž Delhi âžĄïž 9999965857 No Advance 24HRS Live
Vip Call Girls Noida âžĄïž Delhi âžĄïž 9999965857 No Advance 24HRS LiveVip Call Girls Noida âžĄïž Delhi âžĄïž 9999965857 No Advance 24HRS Live
Vip Call Girls Noida âžĄïž Delhi âžĄïž 9999965857 No Advance 24HRS Live
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
 
AI & Machine Learning Presentation Template
AI & Machine Learning Presentation TemplateAI & Machine Learning Presentation Template
AI & Machine Learning Presentation Template
 
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
 
call girls in Vaishali (Ghaziabad) 🔝 >àŒ’8448380779 🔝 genuine Escort Service đŸ”âœ”ïžâœ”ïž
call girls in Vaishali (Ghaziabad) 🔝 >àŒ’8448380779 🔝 genuine Escort Service đŸ”âœ”ïžâœ”ïžcall girls in Vaishali (Ghaziabad) 🔝 >àŒ’8448380779 🔝 genuine Escort Service đŸ”âœ”ïžâœ”ïž
call girls in Vaishali (Ghaziabad) 🔝 >àŒ’8448380779 🔝 genuine Escort Service đŸ”âœ”ïžâœ”ïž
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
 

Finally, EE Security API JSR 375

  • 1. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.1
  • 2. Finally, EE Security API JSR 375 Alex Kosowski JSR 375 Specification Lead WebLogic Server Security
  • 3. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.3 Safe Harbor Statement The following is intended to outline our general product direction. It is intended for information purposes only, and may not be incorporated into any contract. It is not a commitment to deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions. The development, release, and timing of any features or functionality described for Oracle’s products remains at the sole discretion of Oracle.
  • 4. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.4 Agenda Â§ï‚§â€Ż Motivations Â§ï‚§â€Ż A New JSR Â§ï‚§â€Ż Ideas Â§ï‚§â€Ż Get Involved Â§ï‚§â€Ż Q & A
  • 5. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.5 Agenda Â§ï‚§â€Ż Motivations Â§ï‚§â€Ż A New JSR Â§ï‚§â€Ż Ideas Â§ï‚§â€Ż Get Involved Â§ï‚§â€Ż Q & A
  • 6. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.6 Why a Java EE Security API JSR? Â§ï‚§â€Ż EE 8 survey results Â§ï‚§â€Ż 4500 total responses Â§ï‚§â€Ż Priorities Pie Chart
  • 7. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.7 What’s wrong with Java EE Security? "The ultimate goal is to have basic security working without the need of any kind of vendor specific configuration, deployment descriptors, or whatever. ” – Arjan Tijms “[The EE security] model is problematic in cloud/PaaS environments where developers do not necessarily have easy access to non-standard vendor runtime features and a self-contained application is much easier to manage.” – Reza Rahman The community says

  • 8. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.8 What’s wrong with Java EE Security? Â§ï‚§â€Ż Java EE Security viewed as not portable, abstract/confusing, antiquated Â§ï‚§â€Ż Doesn’t fit cloud app developer paradigm: requires app server configuration Â§ï‚§â€Ż Losing value to non-standard 3rd Party Frameworks
less likely to move back to Java EE when requirements increase
  • 9. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.9 What to do? Â§ï‚§â€Ż Plug the portability holes Â§ï‚§â€Ż Modernize –  Context Dependency Injection (CDI) Â§ï‚§â€Ż Intercept at Access Enforcement Points: POJO methods –  Expression Language (EL) Â§ï‚§â€Ż Enable Access Enforcement Points with complex rules Â§ï‚§â€Ż App Developer Friendly –  Common security configurations not requiring server changes –  Annotation defaults not requiring XML
  • 10. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.10 Agenda Â§ï‚§â€Ż Motivations Â§ï‚§â€Ż A New JSR Â§ï‚§â€Ż Ideas Â§ï‚§â€Ż Get Involved Â§ï‚§â€Ż Q & A
  • 11. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.11 JSR 375 History Â§ï‚§â€Ż August 2014: First proposed to Oracle Java EE Architects Â§ï‚§â€Ż December 2014: Approved by JCP Â§ï‚§â€Ż Expert Group nominations: –  EE API veterans: many JSRs, many years struggling with Security API –  3rd party security framework creators/developers –  EE platform security implementers Â§ï‚§â€Ż March 2015: Expert Group started discussions
  • 12. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.12 JSR 375 – Expert Group Name Representing Adam Bien Individual David Blevins Tomitribe Rudy De Busscher Individual Ivar Grimstad Individual Les Hazlewood Stormpath, Inc. Will Hopkins Oracle Werner Keil Individual
  • 13. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.13 JSR 375 – Expert Group Name Representing Matt Konda Jemurai Alex Kosowski Oracle Darran Lofthouse RedHat Jean-Louis Monteiro Tomitribe Ajay Reddy IBM Pedro Igor Silva RedHat Arjan Tijms ZEEF
  • 14. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.14 JSR 375 History Â§ï‚§â€Ż In first month, expert group had an EXPLOSION of activity –  Lot of Brainstorming! –  237 messages on EG mailing list –  81 commits in Github playgrounds for examples and proposals –  24 JIRA issues
  • 15. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.15 Agenda Â§ï‚§â€Ż Motivations Â§ï‚§â€Ż A New JSR Â§ï‚§â€Ż Ideas Â§ï‚§â€Ż Get Involved Â§ï‚§â€Ż Q & A
  • 16. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.16 Ideas Â§ï‚§â€Ż Terminology Â§ï‚§â€Ż API for Authentication Mechanism Â§ï‚§â€Ż API for Identity Store Â§ï‚§â€Ż API for Password Aliasing Â§ï‚§â€Ż API for Role/Permission Assignment Â§ï‚§â€Ż API for Security Context Â§ï‚§â€Ż API for Authorization Interceptors To modernize, standardize, simplify
  • 17. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.17 Ideas To modernize, standardize, simplify Identity Store Authentication Mechanism Security Context Authorization Interceptors Role/Permission Assignment Password Aliasing
  • 18. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.18 Ideas Â§ï‚§â€Ż Terminology Â§ï‚§â€Ż API for Authentication Mechanism Â§ï‚§â€Ż API for Identity Store Â§ï‚§â€Ż API for Password Aliasing Â§ï‚§â€Ż API for Role/Permission Assignment Â§ï‚§â€Ż API for Security Context Â§ï‚§â€Ż API for Authorization Interceptors To modernize, standardize, simplify
  • 19. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.19 Ideas - Terminology Â§ï‚§â€Ż EG discussions revealed inconsistency in security API terms Â§ï‚§â€Ż Different EE containers have different names for the same concepts Â§ï‚§â€Ż When “something” gets authenticated, is that something a
 –  A User? (e.g. HttpServletRequest.getUserPrincipal) –  A Caller? (e.g. EJBContext.getCallerPrincipal) Â§ï‚§â€Ż What is a group? –  A group of users? –  A permission –  Vs Role?
  • 20. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.20 Ideas - Terminology Â§ï‚§â€Ż What is that “something” where identities are stored? –  security provider (WebLogic) –  realm (Tomcat, some hints in Servlet spec) –  (auth) repository –  (auth) store –  login module (JAAS) –  identity manager (Undertow) –  authenticator (Resin, OmniSecurity, Seam Security) –  authentication provider (Spring Security) –  identity provider
  • 21. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.21 Ideas Â§ï‚§â€Ż Terminology Â§ï‚§â€Ż API for Authentication Mechanism Â§ï‚§â€Ż API for Identity Store Â§ï‚§â€Ż API for Password Aliasing Â§ï‚§â€Ż API for Role/Permission Assignment Â§ï‚§â€Ż API for Security Context Â§ï‚§â€Ż API for Authorization Interceptors To modernize, standardize, simplify
  • 22. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.22 Use Case Â§ï‚§â€Ż Application manages its own users and groups Â§ï‚§â€Ż Application needs to authenticate users in order to assign Roles Â§ï‚§â€Ż Application authenticates based on application-domain models Â§ï‚§â€Ż Application needs to use an authentication method not supported on the server, like OpenID Connect Â§ï‚§â€Ż Developer wants to use portable EE Authentication standard API for Authentication Mechanism
  • 23. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.23 Current Solutions Â§ï‚§â€Ż Proprietary server support Â§ï‚§â€Ż 3rd party security frameworks provide authentication Â§ï‚§â€Ż JASPIC: Java Authentication Service Provider Interface for Containers API for Authentication Mechanism
  • 24. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.24 JASPIC Â§ï‚§â€Ż Java Authentication Service Provider Interface for Containers Â§ï‚§â€Ż JSR 196, Maintenance Release 1.1, in 2013 Â§ï‚§â€Ż Standardized, portable, thin, low-level authentication framework Â§ï‚§â€Ż Extensible from within an application Â§ï‚§â€Ż Integrates with the container to build an authenticated Subject Â§ï‚§â€Ż Implement any authentication method
  • 25. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.25 JASPIC Server Auth Module public interface ServerAuthModule { public void initialize(MessagePolicy requestPolicy, MessagePolicy responsePolicy, CallbackHandler handler, Map options) throws AuthException; public AuthStatus validateRequest(MessageInfo messageInfo, Subject clientSubject, Subject serviceSubject); public Class<?>[] getSupportedMessageTypes(); public AuthStatus secureResponse(MessageInfo messageInfo, Subject serviceSubject); public void cleanSubject(MessageInfo messageInfo, Subject subject); }
  • 26. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.26 JASPIC Per-Application Installation ServletContextListener AuthConfigFactory AuthConfigProvider ServerAuthConfig ServerAuthContext ServerAuthModule
  • 27. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.27 Ideas – Simple ServerAuthModule Installation ServletContextListener AuthConfigFactory AuthConfigProvider ServerAuthConfig ServerAuthContext ServerAuthModule ServletContextListener
  • 28. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.28 Ideas – Simple ServerAuthModule Installation @WebListener public class SamRegistrationListener implements ServletContextListener { @Override public void contextInitialized(ServletContextEvent sce) { Jaspic.registerServerAuthModule(new TokenAuthModule(), sce.getServletContext()); } @Override public void contextDestroyed(ServletContextEvent sce) { } }
  • 29. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.29 Ideas – Simple ServerAuthModule Installation @Authenticator("org.acme.TokenAuthModule") @WebServlet("/SimpleServlet") @ServletSecurity(@HttpConstraint(rolesAllowed = {"manager"})) public class SimpleServlet extends HttpServlet { @Override protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { response.getWriter().print("my GET"); } }
  • 30. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.30 Ideas – Profile Specific Helper Classes public class BasicServerAuthModule implements ServerAuthModule { public void initialize(
) throws AuthException { 
 } public Class<?>[] getSupportedMessageTypes() { 
 } public AuthStatus secureResponse(MessageInfo messageInfo, Subject serviceSubject) throws AuthException { 
 } public void cleanSubject(MessageInfo messageInfo, Subject subject) throws AuthException { 
 } public AuthStatus validateRequest(MessageInfo messageInfo, Subject clientSubject, Subject serviceSubject) throws AuthException { final HttpServletRequest request = (HttpServletRequest) messageInfo.getRequestMessage(); 
 }
  • 31. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.31 Ideas – Profile Specific Helper Classes public class BasicServerAuthModule extends HttpServerAuthModule { public AuthStatus validateHttpRequest(HttpServletRequest request, HttpServletResponse response, HttpMessageContext httpMessageContext) throws AuthException { 
 } }
  • 32. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.32 Ideas – Profile Specific Helper Classes public class BasicServerAuthModule extends HttpServerAuthModule { public AuthStatus validateHttpRequest(HttpServletRequest request, HttpServletResponse response, HttpMessageContext httpMessageContext) throws AuthException { final String header = request.getHeader("Authorization"); final String[] credentials = parseCredentials(header); final String username = credentials[0]; final String password = credentials[1]; if (!"snoopy".equals(username) || !"woodst0ck".equals(password)) { return FAILURE; } // No callbacks required!!! return httpMessageContext.notifyContainerAboutLogin( "snoopy", // the groups/roles of the authenticated user Arrays.asList("RedBaron", "JoeCool", "MansBestFriend")); }
  • 33. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.33 Ideas – Standardized Authenticators @Authenticator("javax.security.authenticator.OpenIDConnect") @WebServlet("/SimpleServlet") @ServletSecurity(@HttpConstraint(rolesAllowed = {"manager"})) public class SimpleServlet extends HttpServlet { @Override protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { response.getWriter().print("my GET"); } } Â§ï‚§â€Ż OpenID Connect ServerAuthModule
  • 34. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.34 Ideas – Authentication Events Â§ï‚§â€Ż Throw standardized CDI events at important moments –  PreAuthenticate Event –  PostAuthenticate Event –  PreLogout Event –  PostLogout Event Â§ï‚§â€Ż Possible uses: –  Tracking number of logged-in users –  Tracking failed login attempts per account –  Side effects, like creating a new local user after initial successful authentication via a remote authentication provider –  Loading application-specific user preferences
  • 35. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.35 Ideas Â§ï‚§â€Ż Terminology Â§ï‚§â€Ż API for Authentication Mechanism Â§ï‚§â€Ż API for Identity Store Â§ï‚§â€Ż API for Password Aliasing Â§ï‚§â€Ż API for Role/Permission Assignment Â§ï‚§â€Ż API for Security Context Â§ï‚§â€Ż API for Authorization Interceptors To modernize, standardize, simplify
  • 36. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.36 Use Case Â§ï‚§â€Ż Application manages its own users and groups Â§ï‚§â€Ż Need to access a repository of identities, like users Â§ï‚§â€Ż Users may be stored in app-specified repository (e.g. LDAP) Â§ï‚§â€Ż Users are managed without access to server configuration API for Identity Store
  • 37. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.37 Survey Results API for Identity Store ' Should we simplify authorization by introducing an EL-enabled authorization annotation? ' Should we standardize on requirements for simple security providers and their configuration? ' ' Approximately'58%'thought'we'should'add'support'for'password'aliases,'including'the' ability'to'provision'credentials'along'with'the'application.' ' 70%'thought'that'we'should'standardize'group`to`role'mapping.' ' 53%'thought'we'should'simplify'JASPIC'authentication.' ' 67%'thought'that'we'should'simplify'authorization'and'make'it'more'flexible'by' introducing'EL`based'authorization'annotations,'introducing'a'capability'more'general' than'use'of'@RolesAllowed'and'simpler'than'use'of'interceptors'to'do'programmatic' authorization.' ' 65%'thought'we'should'standardize'on'requirements'for'simple'security'providers'and' their'configuration.'
  • 38. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.38 Current Solutions Â§ï‚§â€Ż No Java EE support Â§ï‚§â€Ż Only proprietary server support Â§ï‚§â€Ż 3rd party security frameworks provide user/group APIs API for Identity Store
  • 39. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.39 Ideas – Identity Store public interface Identity { String getUsername(); char[] getPassword(); boolean isAccountExpired(); boolean isAccountLocked(); boolean isPasswordExpired(); boolean isEnabled(); IdentityAttributeValue getAttribute(String name); } public interface IdentityAttributeValue { String getValue(); String getMetaInfo(String name); }
  • 40. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.40 Ideas – Identity Store public interface IdentityStore{ Identity loadIdentityByName(String name); void changePassword(char[] oldPassword, char[] newPassword); void createIdentity(Identity user); void deleteIdentity(String name); void updateIdentity(Identity identity); boolean identityExists(String name); void createGroup(String group); void deleteGroup(String group); void addIdentityToGroup(String name, String group); void removeIdentityFromGroup(String name, String group); boolean isIdentityInGroup(String name, String group); List<String> getIdentityGroups(String name); }
  • 41. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.41 Ideas – Identity Store IdentityStore LDAP Server Identity DBFile
  • 42. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.42 Ideas – Identity Store @LdapIdentityStore(name=“java:app/prodIdentityStore”, ldapUrl=“ldap://blah”, ldapUser=“ElDap”,ldapPassword=“welcome”) public class MyAuthenticator { @Resource(lookup=“java:app/prodIdentityStore”) private IdentityStore identityStore; private boolean isAccountEnabled(String username) { return identityStore.loadUserByUsername(username).isEnabled(); } 
 }
  • 43. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.43 Ideas – Identity Store @EmbeddedIdentityStore(name=“java:app/devIdentityStore”, {@Identity(username="ray", password="secret", groups="admin"), @Identity(username="jo", password="secret", groups="user"), @Identity(username="sam", password="secret", groups="user")}) @DatabaseIdentityStore(name=“java:app/testIdentityStore”, lookup="somedatabase", userQuery="SELECT password FROM principals WHERE username=?", groupQuery="SELECT group FROM groups where username=?", ...)
  • 44. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.44 Ideas Â§ï‚§â€Ż Terminology Â§ï‚§â€Ż API for Authentication Mechanism Â§ï‚§â€Ż API for Identity Store Â§ï‚§â€Ż API for Password Aliasing Â§ï‚§â€Ż API for Role/Permission Assignment Â§ï‚§â€Ż API for Security Context Â§ï‚§â€Ż API for Authorization Interceptors To modernize, standardize, simplify
  • 45. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.45 Use Case Â§ï‚§â€Ż Application uses passwords to access resources like LDAP and DB Â§ï‚§â€Ż Passwords stored in annotations, deployment descriptors Â§ï‚§â€Ż Best practices dictate that passwords are never stored in clear text Â§ï‚§â€Ż Need a portable way to protect stored passwords API for Password Aliasing
  • 46. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.46 Survey Results Â§ï‚§â€Ż Deferred from Java EE 7 API for Password Aliasing Of'the'small'fraction'of'participants'who'added'comments,'most'of'these'strongly'urged' for'improvements'in'logging'–'either'by'the'revision'of'java.util.logging,'or'replacement' of'its'use'by'either'slf4j,''slf4j'with'LogBack,'or'log4j.' ' ' ' Security' ' Most'of'the'suggested'improvements'in'the'security'area'received'strong'support.' ' Should we add support for password aliases (including the ability to provision credentials along with the application)? ' Should we standardize group-to-role mapping?
  • 47. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.47 Current Solutions Â§ï‚§â€Ż No Java EE support Â§ï‚§â€Ż Proprietary server support, e.g. GlassFish Â§ï‚§â€Ż 3rd party security framework support for embedded password encryption, not aliasing API for Password Aliasing
  • 48. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.48 Ideas – Password Aliasing Â§ï‚§â€Ż For annotations @DataSourceDefinition( name="java:app/jdbc/test", user="root", password="${ALIAS=password}",
) Â§ï‚§â€Ż For deployment descriptors <data-source> <name>java:app/env/testDS</name> <user>APP</user> <password>${ALIAS=password}</password> 
 </data-source>
  • 49. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.49 Ideas – Password Aliasing ${ALIAS=token} "mysecret" Resolved when used Cleared when done
  • 50. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.50 Ideas – Password Aliasing Password Alias Archive
  • 51. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.51 Ideas – Password Aliasing Â§ï‚§â€Ż For configuration: Annotations, Deployment Descriptors Â§ï‚§â€Ż Secure credentials archive for bundling the alias and actual password values with applications Â§ï‚§â€Ż Platform consumes the credentials archive upon deployment Â§ï‚§â€Ż Standard tooling for CRUD operations on the credential archive, e.g. keytool
  • 52. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.52 Ideas Â§ï‚§â€Ż Terminology Â§ï‚§â€Ż API for Authentication Mechanism Â§ï‚§â€Ż API for Identity Store Â§ï‚§â€Ż API for Password Aliasing Â§ï‚§â€Ż API for Role/Permission Assignment Â§ï‚§â€Ż API for Security Context Â§ï‚§â€Ż API for Authorization Interceptors To modernize, standardize, simplify
  • 53. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.53 Use Case Â§ï‚§â€Ż Application manages its own users and groups Â§ï‚§â€Ż Application needs to assign roles (i.e., authorities, permissions) to users and groups, based on application-specific model Â§ï‚§â€Ż Users may be stored in app-specified repository (e.g. LDAP) Â§ï‚§â€Ż Users are managed without access to server configuration API for Role/Permission Assignment
  • 54. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.54 Survey Results API for Role/Permission Assignment Security' ' Most'of'the'suggested'improvements'in'the'security'area'received'strong'support.' ' Should we add support for password aliases (including the ability to provision credentials along with the application)? ' Should we standardize group-to-role mapping?
  • 55. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.55 Current Solutions Â§ï‚§â€Ż No Java EE support Â§ï‚§â€Ż Only proprietary server support Â§ï‚§â€Ż 3rd party security frameworks provide role/authority/permission APIs API for Role/Permission Assignment
  • 56. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.56 Ideas – Standardized Role Mapping Â§ï‚§â€Ż Support in Deployment Descriptors, e.g. web.xml <security-role-map> <!-- Role name as set/returned by Authentication Module --> <group>MANAGER</group> <!-- Role name for mapping --> <role-name>EDIT_ACCOUNTS</role-name> </security-role-map> <!– One-to-one group to role mapping --> <security-role-map groupToRoleMapping="false" />
  • 57. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.57 Ideas – Role Mapping Annotation @EmbeddedRoleMapper( users={ @RoleMap(user=“foo”,roles=“admin”), @RoleMap(group=“admin”,roles={“admin”,”manager”}) } ) public class MyServlet { }
  • 58. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.58 Ideas – Dynamic Role Mapping public interface RoleMapper { void grantRoleToUser(String username, String role); void revokeRoleFromUser(String username, String role); boolean hasRoleForUser( String username, String role, boolean includeGroups); List<String> getRolesForUser( String username, boolean includeGroups); List<String> getUsersWithRole( String role, boolean includeGroups); void grantRoleToGroup(String group, String role); void revokeRoleFromGroup(String group, String role); boolean hasRoleForGroup(String group, String role); List<String> getRolesForGroup(String group); List<String> getGroupsWithRole(String role); }
  • 59. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.59 Ideas – Dynamic Role Mapping @Inject RoleMapper roleMapper; roleMapper.grantRoleToGroup("Manager", "EDIT_ACCOUNTS"); boolean has = roleMapper.hasRoleForGroup("Manager", "CLOSE_ACCT"); List<String> roles = roleMapper.getRolesForGroup("Manager"); List<String> groups = roleMapper.getGroupsWithRole("VIEW_ACCOUNTS");
  • 60. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.60 Ideas Â§ï‚§â€Ż Terminology Â§ï‚§â€Ż API for Authentication Mechanism Â§ï‚§â€Ż API for Identity Store Â§ï‚§â€Ż API for Password Aliasing Â§ï‚§â€Ż API for Role/Permission Assignment Â§ï‚§â€Ż API for Security Context Â§ï‚§â€Ż API for Authorization Interceptors To modernize, standardize, simplify
  • 61. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.61 Use Case Â§ï‚§â€Ż Application needs to access the security API –  To get the authenticated user –  To check roles –  To invoke runAs. Â§ï‚§â€Ż Application needs the same API to access security context, regardless of container API for Security Context
  • 62. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.62 Current Solutions Â§ï‚§â€Ż No Java EE support Â§ï‚§â€Ż 3rd party security frameworks provide a security context API for Security Context
  • 63. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.63 Current Solutions @Singleton public class MyEjb { @Resource private SessionContext sessionContext; public String sayHello() { if (sessionContext.isCallerInRole("admin")) { return "Hello World!"; } throw new SecurityException("User is unauthorized."); } }
  • 64. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.64 Current Solutions public class MyServlet extends HttpServlet { @Override protected void doGet(HttpServletRequest request, HttpServletResponse resp) throws ServletException, IOException { if (request.isUserInRole("admin")) { // do something } throw new ServletException("User is unauthorized."); } }
  • 65. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.65 Current Solutions @RequestScoped public class MyCdiBean { // Oh snap! No SecurityContext class for CDI }
  • 66. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.66 Current Solutions public class MyJaxRsService { @GET @Produces("text/plain;charset=UTF-8") @Path("/hello") public String sayHello(@Context SecurityContext sc) { if (sc.isUserInRole("admin")) { return "Hello World!"; } throw new SecurityException("User is unauthorized."); } }
  • 67. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.67 Ideas – Security Context public interface SecurityContext { String getUserPrincipal(); boolean isUserInRole(String role); List<String> getAllUsersRoles(); boolean isAuthenticated(); boolean isUserInAnyRole(List<String> roles); boolean isUserInAllRoles(List<String> roles); void login(Object request, Object response); void login(Map map); void logout(); void runAs(String role); boolean hasAccessToResource(); boolean hasAccessToBeanMethod(); }
  • 68. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.68 Ideas – Security Context Â§ï‚§â€Ż For all managed beans: CDI, Servlet, EJB, JAX-RS, etc public class MyFutureCdiBean { @Inject private SecurityContext securityContext; public String sayHello() { if (securityContext.isUserInRole("admin")) { return "Hello World!"; } throw new SecurityException("User is unauthorized."); } }
  • 69. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.69 Ideas Â§ï‚§â€Ż Terminology Â§ï‚§â€Ż API for Authentication Mechanism Â§ï‚§â€Ż API for Identity Store Â§ï‚§â€Ż API for Password Aliasing Â§ï‚§â€Ż API for Role/Permission Assignment Â§ï‚§â€Ż API for Security Context Â§ï‚§â€Ż API for Authorization Interceptors To modernize, standardize, simplify
  • 70. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.70 Use Case Â§ï‚§â€Ż Application needs to restrict specific methods to authorized users Â§ï‚§â€Ż Application-model rules are used to make access decisions Â§ï‚§â€Ż Role is insufficient API for Authorization Interceptors
  • 71. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.71 Survey Results API for Authorization Interceptors this'last'question.''Thymeleaf,'Freemarker,'and'Velocity'were'the'most'frequently' mentioned'here.' ' ' ' ' CDI' ' The'next'four'questions'focused'on'continued'CDI'alignment.''This'was'one'of'the'focus' areas'of'Java'EE'7.' ' Should we consider adding Security Interceptors in Java EE 8? Should we simplify JASPIC? ' Should we simplify authorization by introducing an EL-enabled authorization annotation? ' Should we standardize on requirements for simple security providers and their configuration?
  • 72. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.72 Current Solutions Â§ï‚§â€Ż EE authorization has no rule based authorization, only role based Â§ï‚§â€Ż 3rd party security frameworks provide rule, role and permission based APIs API for Authorization Interceptors
  • 73. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.73 Ideas – EL Authorization Rules Â§ï‚§â€Ż Expression Language rule would have access to managed beans for SecurityContext and InvocationContext @ EvaluateSecured("security.hasRoles('MANAGER') && schedule.nowIsOfficeHrs") void transferFunds() {..};
  • 74. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.74 Ideas – EL Authorization Rules Â§ï‚§â€Ż EL Authorization rules centrally managed in a repository @LdapAuthorizationRules ( name="java:app/accountAuthRules", ldapUrl="ldap://blah", ldapUser="ElDap", ldapPassword=“mysecret” ) public class MyBean { @ EvaluateSecured( ruleSourceName="java:app/accountAuthRules", rule="transferFunds") void transferFunds() {..}; 
 }
  • 75. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.75 Ideas – AccessDecisionVoter Â§ï‚§â€Ż A user-defined class for making access decisions @Secured(AccountAccessDecisionVoter.class) void transferFunds() {..};
  • 76. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.76 Ideas – AccessDecisionVoter public class AccountAccessDecisionVoter implements AccessDecisionVoter { @Override public void checkPermission(AccessDecisionVoterContext ctx, Set<SecurityViolation> violations) { // Check for violations Method method = ctx.<InvocationContext>getSource().getMethod(); 
 violations.add(new SecurityViolation("Sorry, not allowed")); } }
  • 77. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.77 Agenda Â§ï‚§â€Ż Motivations Â§ï‚§â€Ż A New JSR Â§ï‚§â€Ż Ideas Â§ï‚§â€Ż Get Involved Â§ï‚§â€Ż Q & A
  • 78. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.78 Get Involved Â§ï‚§â€Ż Project Page: The starting point to all resources https://java.net/projects/javaee-security-spec Â§ï‚§â€Ż Users List: Subscribe and contribute users@javaee-security-spec.java.net Â§ï‚§â€Ż Github Playground: Fork and Play! https://github.com/javaee-security-spec/javaee-security-proposals
  • 79. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.79 Q/A
  • 80. Copyright © 2015, Oracle and/or its affiliates. All rights reserved.80