Package net.jini.core.constraint

Examples of net.jini.core.constraint.ClientMinPrincipal


      InvocationConstraints[] clientConstraintsArr =
    new InvocationConstraints[] {
        new InvocationConstraints(
      new InvocationConstraint[] {
          new ClientMinPrincipal(cps[1]),
          new ClientMaxPrincipal(
        new Principal[] {cps[0], cps[1], cps[2]})},
      null),
        new InvocationConstraints(
      new InvocationConstraint[] {
          new ClientMinPrincipal(cps[1]),
          new ClientMaxPrincipal(
        new Principal[] {cps[0], cps[1]}),
          Confidentiality.YES},
      null),
        new InvocationConstraints(
      new InvocationConstraint[] {
          new ClientMinPrincipal(cps[1]),
          new ClientMaxPrincipal(
        new Principal[] {cps[1], cps[2]}),
          Delegation.YES},
      null),
        new InvocationConstraints(
      new InvocationConstraint[] {
          new ClientMinPrincipal(cps[1]),
          new ClientMaxPrincipal(
        new Principal[] {cps[1], cps[2]}),
          Delegation.YES},
      new InvocationConstraint[] {Confidentiality.YES})
      };
View Full Code Here


    public Subject getSubject() {
        return Subject.getSubject(AccessController.getContext());
    }

    public ClientMinPrincipal getClientMinPrincipal() {
        return new ClientMinPrincipal(clientSubject.getPrincipals());
    }
View Full Code Here

        return new ClientMaxPrincipal(principals);
    }

    public ConstraintAlternatives getConstraintAlternatives1() {
        return new ConstraintAlternatives(new InvocationConstraint[] {
            new ClientMinPrincipal(clientSubject.getPrincipals()),
            new ClientMinPrincipal(new KerberosPrincipal("dummy"))
        });
    }
View Full Code Here

        });
    }

    public ConstraintAlternatives getConstraintAlternatives2() {
        return new ConstraintAlternatives(new InvocationConstraint[] {
            new ClientMinPrincipal(clientSubject.getPrincipals()),
            new ClientMinPrincipal(new KerberosPrincipal("dummy"))
        });
    }
View Full Code Here

                     ConstraintAlternatives alt)
     {
        if (subject != null) {
            Iterator itAlt = alt.elements().iterator();
            while (itAlt.hasNext()) {
                ClientMinPrincipal cminp = (ClientMinPrincipal) itAlt.next();
                int matchCount = cminp.elements().size();
                Iterator itCminp = cminp.elements().iterator();
                while (itCminp.hasNext()) {
                    Principal altP = (Principal) itCminp.next();
                    Iterator itSub = subject.getPrincipals().iterator();
                    while (itSub.hasNext()) {
                        Principal subP = (Principal)itSub.next();
View Full Code Here

         * Create ClientMinPrincipal object
         */
        set[2] = set[0];

        try {
            obj[2] = new ClientMinPrincipal(set[2]);
        } catch (Exception e) {
            throw new TestException("Exception has been thrown while creating"
                    + " ClientMinPrincipal object", e);
        }

View Full Code Here

            ServerAuthentication.NO,
            new ClientMaxPrincipalType(TestPrincipal.class),
            new ClientMinPrincipalType(TestPrincipal.class),
            new DelegationRelativeTime(1000, 2000, 3000, 4000),
            new DelegationAbsoluteTime(1000, 2000, 3000, 4000),
            new ClientMinPrincipal(new Principal[] { tp1, tp2 }),
            new ClientMaxPrincipal(new Principal[] { tp1, tp2 }),
            new ServerMinPrincipal(new Principal[] { tp1, tp2 }),
            new ClientMinPrincipal(new Principal[] { tp1, tp3, tp2 }),
            new ClientMaxPrincipal(new Principal[] { tp1, tp3, tp2 }),
            new ServerMinPrincipal(new Principal[] { tp1, tp3, tp2 }),
            new ConstraintAlternatives(new InvocationConstraint[] {
                Delegation.YES,
                Integrity.YES,
View Full Code Here

            if (       tc == CL_MAX_PR__PRINCIPAL
                    || tc == CL_MAX_PR__PRINCIPAL_NULL) {
                ic = new ClientMaxPrincipal((Principal) pr);
            } else if (tc == CL_MIN_PR__PRINCIPAL
                    || tc == CL_MIN_PR__PRINCIPAL_NULL) {
                ic = new ClientMinPrincipal((Principal) pr);
            } else if (tc == SRV_MIN_PR__PRINCIPAL
                    || tc == SRV_MIN_PR__PRINCIPAL_NULL) {
                ic = new ServerMinPrincipal((Principal) pr);
            }
View Full Code Here

                ic = new ClientMaxPrincipal((Principal[]) pr);
            } else if (tc == CL_MIN_PR__PRINCIPALS_ARRAY
                    || tc == CL_MIN_PR__PRINCIPALS_NULL_ARRAY
                    || tc == CL_MIN_PR__PRINCIPALS_ARRAY_NULL_EL
                    || tc == CL_MIN_PR__PRINCIPALS_EMPTY_ARRAY) {
                ic = new ClientMinPrincipal((Principal[]) pr);
            } else if (tc == SRV_MIN_PR__PRINCIPALS_ARRAY
                    || tc == SRV_MIN_PR__PRINCIPALS_NULL_ARRAY
                    || tc == SRV_MIN_PR__PRINCIPALS_ARRAY_NULL_EL
                    || tc == SRV_MIN_PR__PRINCIPALS_EMPTY_ARRAY) {
                ic = new ServerMinPrincipal((Principal[]) pr);
View Full Code Here

            } else if (tc == CL_MIN_PR__PRINCIPALS_COLL
                    || tc == CL_MIN_PR__PRINCIPALS_NULL_COLL
                    || tc == CL_MIN_PR__PRINCIPALS_COLL_NULL_EL
                    || tc == CL_MIN_PR__PRINCIPALS_EMPTY_COLL
                    || tc == CL_MIN_PR__PRINCIPALS_COLL_ILL_EL) {
                ic = new ClientMinPrincipal((Collection) pr);
            } else if (tc == SRV_MIN_PR__PRINCIPALS_COLL
                    || tc == SRV_MIN_PR__PRINCIPALS_NULL_COLL
                    || tc == SRV_MIN_PR__PRINCIPALS_COLL_NULL_EL
                    || tc == SRV_MIN_PR__PRINCIPALS_EMPTY_COLL
                    || tc == SRV_MIN_PR__PRINCIPALS_COLL_ILL_EL) {
View Full Code Here

TOP

Related Classes of net.jini.core.constraint.ClientMinPrincipal

Copyright © 2018 www.massapicom. 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.