Package org.apache.ftpserver.ftplet

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


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


           
            authorities.add(new TransferRatePermission(downloadRate, uploadRate));
           
            user.setAuthorities(authorities);
           
            um.save(user);
           
            if(um instanceof PropertiesUserManager) {
                File file = ((PropertiesUserManager) um).getFile();
               
                if(file != null) {
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.setPassword("secret");
                user.setHomeDirectory(Vars.Mater_Lector);
                user.setAuthorities(auths);


                um.save(user);
            }

            FtpServerFactory serverFactory = new FtpServerFactory();
            Vars.server = serverFactory.createServer();
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

      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

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

           
            authorities.add(new TransferRatePermission(downloadRate, uploadRate));
           
            user.setAuthorities(authorities);
           
            um.save(user);
           
            if(um instanceof PropertiesUserManager) {
                File file = ((PropertiesUserManager) um).getFile();
               
                if(file != null) {
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.