Package org.apache.ftpserver.ftplet

Examples of org.apache.ftpserver.ftplet.UserManager.save()


        BaseUser user = new BaseUser();
        user.setName("myNewUser");
        user.setPassword("secret");
        user.setHomeDirectory("ftproot");
       
        um.save(user);
    }
}
View Full Code Here


    BaseUser user = new BaseUser();
        user.setName("activemq");
        user.setPassword("activemq");
        user.setHomeDirectory(ftpHomeDirFile.getParent());
       
        userManager.save(user);

    serverFactory.setUserManager(userManager);
    factory.setPort(0);
    serverFactory.addListener(ftpServerListenerName, factory
        .createListener());
View Full Code Here

            user.setAuthorities( authorities );

            user.setHomeDirectory( ftpHomeDir.getAbsolutePath() );


            um.save(user);

            serverFactory.setUserManager( um );

            server = serverFactory.createServer();
View Full Code Here

            user.setAuthorities( authorities );

            user.setHomeDirectory( ftpHomeDir.getAbsolutePath() );


            um.save(user);

            serverFactory.setUserManager( um );

            server = serverFactory.createServer();
View Full Code Here

    BaseUser user = new BaseUser();
        user.setName("activemq");
        user.setPassword("activemq");
        user.setHomeDirectory(ftpHomeDirFile.getParent());
       
        userManager.save(user);

        serverFactory.setUserManager(userManager);
        factory.setPort(0);
        serverFactory.addListener(ftpServerListenerName, factory
                .createListener());
View Full Code Here

        BaseUser user = new BaseUser();
        user.setName("activemq");
        user.setPassword("activemq");
        user.setHomeDirectory(ftpHomeDirFile.getParent());

        userManager.save(user);

        serverFactory.setUserManager(userManager);
        factory.setPort(0);
        serverFactory.addListener(ftpServerListenerName, factory
                .createListener());
View Full Code Here

      adminUser.setAuthorities(new Authority[] { new WritePermission() });

      Path adminUserHome = new Path(ftpServerRoot, "user/admin");
      adminUser.setHomeDirectory(adminUserHome.toUri().getPath());
      adminUser.setMaxIdleTime(0);
      userManager.save(adminUser);

      // Initialize the server and start.
      server = new FtpServer(context);
      server.start();
View Full Code Here

      adminUser.setAuthorities(new Authority[] { new WritePermission() });

      Path adminUserHome = new Path(ftpServerRoot, "user/admin");
      adminUser.setHomeDirectory(adminUserHome.toUri().getPath());
      adminUser.setMaxIdleTime(0);
      userManager.save(adminUser);

      // Initialize the server and start.
      server = new FtpServer(context);
      server.start();
View Full Code Here

            adminUser.setAuthorities(ADMIN_AUTHORITIES);

            adminUser.setHomeDirectory("./res/home");
            adminUser.setMaxIdleTime(0);
            userManager.save(adminUser);
        }

        // create anonymous user
        if (!userManager.doesExist("anonymous")) {
            LOG.info("Creating user : anonymous");
View Full Code Here

            anonUser.setEnabled(true);

            anonUser.setHomeDirectory("./res/home");
            anonUser.setMaxIdleTime(300);
            userManager.save(anonUser);
        }
    }

    /**
     * Get user manager.
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.