Examples of EJBRoleRefPermission


Examples of javax.security.jacc.EJBRoleRefPermission

        // process the security-role-ref.
        Map<String, Collection<String>> securityRoles = ejbComponentDescription.getSecurityRoleLinks();
        for (Map.Entry<String, Collection<String>> entry : securityRoles.entrySet()) {
            String roleName = entry.getKey();
            for (String roleLink : entry.getValue()) {
                EJBRoleRefPermission p = new EJBRoleRefPermission(ejbComponentDescription.getEJBName(), roleName);
                ejbJaccConfig.addRole(roleLink, p);
            }
        }

        // special handling of stateful session bean getEJBObject due how the stateful session handles acquire the
View Full Code Here

Examples of javax.security.jacc.EJBRoleRefPermission

        String EJBName = deploymentInfo.getEjbName();
        if (EJBName == null) throw new IllegalArgumentException("EJBName must not be null");
        try {
            AccessControlContext context = ContextManager.getCurrentContext();
            context.checkPermission(new EJBRoleRefPermission(EJBName, role));
        } catch (AccessControlException e) {
            return false;
        }
        return true;
    }
View Full Code Here

Examples of javax.security.jacc.EJBRoleRefPermission

        String EJBName = deploymentInfo.getEjbName();
        if (EJBName == null) throw new IllegalArgumentException("EJBName must not be null");
        try {
            AccessControlContext context = ContextManager.getCurrentContext();
            context.checkPermission(new EJBRoleRefPermission(EJBName, role));
        } catch (AccessControlException e) {
            return false;
        }
        return true;
    }
View Full Code Here

Examples of javax.security.jacc.EJBRoleRefPermission

            Context context = (Context) subjectContexts.get(currentCaller.get());

            assert context != null : "No registered context";

            context.context.checkPermission(new EJBRoleRefPermission(EJBName, role));
        } catch (AccessControlException e) {
            return false;
        }
        return true;
    }
View Full Code Here

Examples of javax.security.jacc.EJBRoleRefPermission

                if (roleLinks == null) {
                    roleLinks = new Permissions();
                    rolePermissions.put(roleLink, roleLinks);

                }
                roleLinks.add(new EJBRoleRefPermission(ejbName, securityRoleRef.getRoleName()));
            }
        }

        /**
         * EJB v2.1 section 21.3.2
View Full Code Here

Examples of javax.security.jacc.EJBRoleRefPermission

        SecurityContext securityContext = threadContext.get(SecurityContext.class);

        try {
            CoreDeploymentInfo deployment = threadContext.getDeploymentInfo();

            securityContext.acc.checkPermission(new EJBRoleRefPermission(deployment.getEjbName(), role));
        } catch (AccessControlException e) {
            return false;
        }
        return true;
    }
View Full Code Here

Examples of javax.security.jacc.EJBRoleRefPermission

                    // Process the security-role-ref
                    Map<String, Collection<String>> securityRoles = component.getSecurityRoleLinks();
                    for (Entry<String, Collection<String>> entry : securityRoles.entrySet()) {
                        String roleName = entry.getKey();
                        for (String roleLink : entry.getValue()) {
                            EJBRoleRefPermission p = new EJBRoleRefPermission(ejbName, roleName);
                            policyConfiguration.addToRole(roleLink, p);
                        }
                    }

                    /*
 
View Full Code Here

Examples of javax.security.jacc.EJBRoleRefPermission

            if (roleLinks == null) {
                roleLinks = new Permissions();
                rolePermissions.put(roleLink, roleLinks);

            }
            roleLinks.add(new EJBRoleRefPermission(ejbName, securityRoleRef.roleName));
        }

        /**
         * EJB v2.1 section 21.3.2
         * <p/>
 
View Full Code Here

Examples of javax.security.jacc.EJBRoleRefPermission

            Context context = subjectContexts.get(currentSubject);

            assert context != null : "No registered context";

            context.context.checkPermission(new EJBRoleRefPermission(EJBName, role));
        } catch (AccessControlException e) {
            return false;
        }
        return true;
    }
View Full Code Here

Examples of javax.security.jacc.EJBRoleRefPermission

            if (roleLinks == null) {
                roleLinks = new Permissions();
                rolePermissions.put(roleLink, roleLinks);

            }
            roleLinks.add(new EJBRoleRefPermission(ejbName, securityRoleRef.roleName));
        }

        /**
         * EJB v2.1 section 21.3.2
         * <p/>
 
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.