Package org.glyptodon.guacamole.net.auth

Examples of org.glyptodon.guacamole.net.auth.ConnectionGroup


        // For each entry, write corresponding connection element
        for (String identifier : identifiers) {

            // Write each group
            ConnectionGroup group = directory.get(identifier);
            writeConnectionGroup(self, xml, group);

        }

        // End connections
View Full Code Here


       
        // Set encoding
        response.setCharacterEncoding("UTF-8");

        // Get root group
        ConnectionGroup root = context.getRootConnectionGroup();

        // Write actual XML
        try {

            // Get self
View Full Code Here

        // For each entry, write corresponding connection element
        for (String identifier : identifiers) {

            // Write each group
            ConnectionGroup group = directory.get(identifier);
            writeConnectionGroup(self, xml, group);

        }

        // End connections
View Full Code Here

       
        // Set encoding
        response.setCharacterEncoding("UTF-8");

        // Get root group
        ConnectionGroup root = context.getRootConnectionGroup();

        // Write actual XML
        try {

            // Get self
View Full Code Here

     */
    static Directory<String, Connection> findConnectionDirectory(
            UserContext context, String parentID) throws GuacamoleException {
       
        // Find the correct connection directory
        ConnectionGroup rootGroup = context.getRootConnectionGroup();
        Directory<String, Connection> directory;
       
        Directory<String, ConnectionGroup> connectionGroupDirectory =
            rootGroup.getConnectionGroupDirectory();

        ConnectionGroup parentGroup = connectionGroupDirectory.get(parentID);

        if(parentGroup == null)
            return null;

        directory = parentGroup.getConnectionDirectory();
       
        return directory;
    }
View Full Code Here

                // Get connection group directory
                Directory<String, ConnectionGroup> directory =
                    context.getRootConnectionGroup().getConnectionGroupDirectory();

                // Get authorized connection group
                ConnectionGroup group = directory.get(id);
                if (group == null) {
                    logger.info("Connection group \"{}\" does not exist for user \"{}\".", id, context.self().getUsername());
                    throw new GuacamoleSecurityException("Requested connection group is not authorized.");
                }

                // Connect socket
                socket = group.connect(info);
                logger.info("User \"{}\" successfully connected to group \"{}\".", context.self().getUsername(), id);
                break;
            }

            // Fail if unsupported type
View Full Code Here

       
        if(directory == null)
            throw new GuacamoleException("Connection group directory not found.");

        // Create connection skeleton
        ConnectionGroup connectionGroup = new DummyConnectionGroup();
        connectionGroup.setName(name);
       
        if("balancing".equals(type))
            connectionGroup.setType(ConnectionGroup.Type.BALANCING);
        else if("organizational".equals(type))
            connectionGroup.setType(ConnectionGroup.Type.ORGANIZATIONAL);

        // Add connection
        directory.add(connectionGroup);

    }
View Full Code Here

        // Attempt to get connection group directory
        Directory<String, ConnectionGroup> directory =
                context.getRootConnectionGroup().getConnectionGroupDirectory();

        // Create connection group skeleton
        ConnectionGroup connectionGroup = directory.get(identifier);
        connectionGroup.setName(name);
       
        if("balancing".equals(type))
            connectionGroup.setType(ConnectionGroup.Type.BALANCING);
        else if("organizational".equals(type))
            connectionGroup.setType(ConnectionGroup.Type.ORGANIZATIONAL);

        // Update connection group
        directory.update(connectionGroup);

    }
View Full Code Here

     */
    static Directory<String, ConnectionGroup> findConnectionGroupDirectory(
            UserContext context, String parentID) throws GuacamoleException {
       
        // Find the correct connection group directory
        ConnectionGroup rootGroup = context.getRootConnectionGroup();
        Directory<String, ConnectionGroup> directory;
       
        Directory<String, ConnectionGroup> connectionGroupDirectory =
            rootGroup.getConnectionGroupDirectory();

        ConnectionGroup parentGroup = connectionGroupDirectory.get(parentID);

        if(parentGroup == null)
            return null;

        directory = parentGroup.getConnectionGroupDirectory();
       
        return directory;
    }
View Full Code Here

TOP

Related Classes of org.glyptodon.guacamole.net.auth.ConnectionGroup

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.