Package org.apache.ftpserver.impl

Examples of org.apache.ftpserver.impl.FtpIoSession


    public synchronized Set<FtpIoSession> getActiveSessions() {
        Map<Long, IoSession> sessions = acceptor.getManagedSessions();

        Set<FtpIoSession> ftpSessions = new HashSet<FtpIoSession>();
        for (IoSession session : sessions.values()) {
            ftpSessions.add(new FtpIoSession(session, context));
        }
        return ftpSessions;
    }
View Full Code Here


        this.ftpHandler = ftpHandler;
    }

    public void exceptionCaught(IoSession session, Throwable cause)
            throws Exception {
        FtpIoSession ftpSession = new FtpIoSession(session, context);
        ftpHandler.exceptionCaught(ftpSession, cause);
    }
View Full Code Here

        ftpHandler.exceptionCaught(ftpSession, cause);
    }

    public void messageReceived(IoSession session, Object message)
            throws Exception {
        FtpIoSession ftpSession = new FtpIoSession(session, context);
        FtpRequest request = new DefaultFtpRequest(message.toString());

        ftpHandler.messageReceived(ftpSession, request);
    }
View Full Code Here

        ftpHandler.messageReceived(ftpSession, request);
    }

    public void messageSent(IoSession session, Object message) throws Exception {
        FtpIoSession ftpSession = new FtpIoSession(session, context);
        ftpHandler.messageSent(ftpSession, (FtpReply) message);
    }
View Full Code Here

        FtpIoSession ftpSession = new FtpIoSession(session, context);
        ftpHandler.messageSent(ftpSession, (FtpReply) message);
    }

    public void sessionClosed(IoSession session) throws Exception {
        FtpIoSession ftpSession = new FtpIoSession(session, context);
        ftpHandler.sessionClosed(ftpSession);
    }
View Full Code Here

        FtpIoSession ftpSession = new FtpIoSession(session, context);
        ftpHandler.sessionClosed(ftpSession);
    }

    public void sessionCreated(IoSession session) throws Exception {
        FtpIoSession ftpSession = new FtpIoSession(session, context);
        MdcInjectionFilter.setProperty(session, "session", ftpSession.getSessionId().toString());

        ftpHandler.sessionCreated(ftpSession);
       
    }
View Full Code Here

       
    }

    public void sessionIdle(IoSession session, IdleStatus status)
            throws Exception {
        FtpIoSession ftpSession = new FtpIoSession(session, context);
        ftpHandler.sessionIdle(ftpSession, status);
    }
View Full Code Here

        FtpIoSession ftpSession = new FtpIoSession(session, context);
        ftpHandler.sessionIdle(ftpSession, status);
    }

    public void sessionOpened(IoSession session) throws Exception {
        FtpIoSession ftpSession = new FtpIoSession(session, context);
        ftpHandler.sessionOpened(ftpSession);
    }
View Full Code Here

        assertTrue(client.login(ADMIN_USERNAME, ADMIN_PASSWORD));
        assertTrue(FTPReply.isPositiveCompletion(client.noop()));
    }

    public void testClientCertificates() throws Exception {
        FtpIoSession session = server.getListener("default")
                .getActiveSessions().iterator().next();
        assertEquals(1, session.getClientCertificates().length);

        X509Certificate cert = (X509Certificate) session
                .getClientCertificates()[0];

        assertTrue(cert.getSubjectDN().toString().contains("FtpClient"));
    }
View Full Code Here

    public synchronized Set<FtpIoSession> getActiveSessions() {
        Map<Long, IoSession> sessions = acceptor.getManagedSessions();

        Set<FtpIoSession> ftpSessions = new HashSet<FtpIoSession>();
        for (IoSession session : sessions.values()) {
            ftpSessions.add(new FtpIoSession(session, context));
        }
        return ftpSessions;
    }
View Full Code Here

TOP

Related Classes of org.apache.ftpserver.impl.FtpIoSession

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.