Package org.gridforum.jgss

Examples of org.gridforum.jgss.ExtendedGSSContext


    this.port = (url.getPort() == -1) ? PORT : url.getPort();

    GSSManager manager = ExtendedGSSManager.getInstance();

    ExtendedGSSContext context = null;

    try {
      context =
        (ExtendedGSSContext)manager.createContext(getExpectedName(),
            GSSConstants.MECH_OID,
            this.credentials,
            GSSContext.DEFAULT_LIFETIME);

      switch (this.delegationType) {

      case GSIConstants.DELEGATION_NONE:
        context.requestCredDeleg(false);
        break;
      case GSIConstants.DELEGATION_LIMITED:
        context.requestCredDeleg(true);
        context.setOption(GSSConstants.DELEGATION_TYPE,
            GSIConstants.DELEGATION_TYPE_LIMITED);
        break;
      case GSIConstants.DELEGATION_FULL:
        context.requestCredDeleg(true);
        context.setOption(GSSConstants.DELEGATION_TYPE,
            GSIConstants.DELEGATION_TYPE_FULL);
        break;
      default:
        context.requestCredDeleg(true);
      context.setOption(GSSConstants.DELEGATION_TYPE,
          new Integer(this.delegationType));

      }

      if (this.gssMode != null) {
        context.setOption(GSSConstants.GSS_MODE,
            gssMode);
      }

    } catch (GSSException e) {
      throw new ChainedIOException("Failed to init GSI context", e);
View Full Code Here

TOP

Related Classes of org.gridforum.jgss.ExtendedGSSContext

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.